Control Loops
There are 3 methods of controlling the TI2 depending on the device state. Normal Operation, Bypass Operation, and Silent Operation.
Normal Operation
EPS torque sensor 5v supply pulls MCU MCLRs (active low reset). All Interrupts are enabled.
EPS sends a request pulse to MCU. External interrupt detects pulse. The external interrupt is disabled. MCU sends a request pulse to the torque sensor.
The torque sensor responds with reading. Sensor reading is buffered. The external interrupt is re-enabled.
During this time the main loop reads the LKAS command and uses a copy of the buffered torque sensor reading, applies limits and offsets the LKAS command based on the CPU ID and calculates the new steering torque.
EPS sends the next request pulse to MCU. External interrupt detects pulse. The external interrupt is disabled.
MCU sends the steering torque. MCU sends a request pulse to the torque sensor.
Steps 3 to 6 are constantly repeated in the DRIVE state. If the MCU exits the DRIVE state, it will immediately revert to using the buffered sensor readings and enter bypass operation.
Bypass Operation
EPS torque sensor 5v supply pulls MCU MCLRs (active low reset). All Interrupts are enabled.
EPS sends a request pulse to MCU. External interrupt detects pulse. The external interrupt is disabled. MCU sends a request pulse to the torque sensor.
The torque sensor responds with reading. Sensor reading is buffered. The external interrupt is re-enabled.
EPS sends the next request pulse to MCU. External interrupt detects pulse. The external interrupt is disabled.
MCU sends buffered sensor readings. MCU sends a request pulse to the torque sensor.
Steps 3 to 5 are constantly repeated in the ERROR state. If the MCU enters the CRITICAL_ERROR state, the MCU will not respond to the EPS request pulses.
Silent Operation
EPS sends a request pulse to MCU. External interrupt detects pulse. The external interrupt is disabled.
The main loop flashes the status LED and clears the watchdog timer.
Step 2 is constantly repeated until reset.
Last updated