1. A device, comprising:an accelerometer, which, in operation, generates accelerometer data; and
digital signal processing circuitry communicatively coupled to the accelerometer, wherein the digital signal processing circuitry, in operation:
generates, based on the generated accelerometer data, a value indicative of a cosine of an angle between an acceleration vector associated with current accelerometer data and a reference acceleration vector, wherein the generating the value indicative of the cosine of the angle between the acceleration vector associated with current accelerometer data and the reference acceleration vector includes:
generating a value indicative of a scalar product of the vector associated with current accelerometer data and the reference acceleration vector; and
dividing the value indicative of the scalar product by a value indicative of a magnitude of the vector associated with current accelerometer data multiplied by a value indicative of a magnitude of the reference acceleration vector;
compares the generated value indicative of the cosine of the angle between the acceleration vector associated with current accelerometer data and the reference acceleration vector with one or more thresholds; and
generates a signal indicative of a tilt based on the comparison of the generated value indicative of the cosine of the angle between the acceleration vector associated with current accelerometer data and the reference acceleration vector with the one or more thresholds, wherein, in response to the signal indicative of a tilt indicating detection of a tilt event, the device processes accelerometer data associated with the tilt event using an exercise program.