A controller for a lock mechanism of an engine valve that readily performs unlocking.
A VVT changes the rotational phase of a camshaft relative to a pulley in accordance
with the difference between the hydraulic pressure of an advance pressure chamber
and the hydraulic pressure of a delay pressure chamber to vary the valve timing.
The hydraulic pressure difference is set by a variable command value. A lock mechanism
engages a lock pin with a lock hole when the rotational phase of the camshaft matches
a lock phase. The VVT enters the most easily unlocking hydraulic pressure state
when the command value is set at an unlocking command value. An ECU gradually increases
the command value from a lower limit value to the unlocking command value and then
to the upper limit value to unlock relative rotation of the camshaft.