I don't know where you have the idea that yaw dampers on A340's have any other function or way of working than any other airplane.
btw it's wrong to believe that yaw damping is there to reduce "excursions in yaw". Yaw dampers are - in any jet with swept wings - there to reduce the risk of dutch roll.
Dani