In order to understand how automation in Ardour works, it is necessary to understand the four modes of automation. They are: Manual, Play, Write, and Touch.
Manual mode is basically analogous to a processor's bypass switch. Whenever an automation lane is in this mode, it is inactive and any level that is manually set for controlling the lane's parameter will persist during playback like normal.
In Ardour, every track and processor parameter is initially set to Manual mode.
Play mode tells Ardour to use the automation curve in the automation lane to control the level of the parameter controlled by the lane during playback. The control that normally sets the parameter will be unresponsive to manual input and will move automatically in accord with the lane's automation curve during playback.
Write mode allows continuous, dynamic setting of a control during playback; all such settings are written to the lane the control is in. This defines the lane's automation curve in the interval being played, and overwrites any existing automation curve in the lane being manipulated.
Touch mode is similar to Write mode, except it only overwrites sections of a lane's automation curve when the control is changed in some way. This allows for changing only the parts of an automation curve that are desired to be changed, while leaving the rest unchanged.