5702

Control the blinker lights of a Tesla model 3 Highland with gestures

When Tesla decided to remove the blinker control stalk from the model 3 Highland it made driving the car actually less safe. Specially in Europe where roundabouts are very common. Hands are moved on the wheel while driving and it takes attention to find and control the blinker lights. In stead of placing some expensive after marked stalks I thought how to make it better ... Removing stalk controls does fit in the minimalist design of Tesla and this is something to keep but also the driving experience should come first. One shouldn't fiddle/search with touch buttons just to drive safe. Therefore I came up with a gesture control solution. The VL53L7CX Time of flight sensor has a grid of 8 x 8 tof zones. This sensor is connected to a Nucleo STM32F401RE board. This board is programmed using the STM32 cube ide development environment. When a up/down gesture is detected the board controls a Testars button that is configured for the blinker lights.

How gesture detection works: The Vl53L7CX sensor is connected via I2C and interrupt to the STM32F401 board. When a threshold is reached in a zone the sensor send interrupt signals and the detection algorithm can start. The STM32F401 starts to receive measurements of the tof zones. When 2 horizontal virtual zones are crossed this detects an upward/downward movement. For this detection to happen fast enough the sensor zones has to be scanned at 30 Hz. The software is setup a state machine:

    GESTURE_STATE_WAIT_ENTRY ==> waiting for the threshold to be reached
    GESTURE_STATE_TRACK ==> Tracking the movement

This tracking can result in:

  GESTURE_NONE
  GESTURE_UP
  GESTURE_DOWN

Entering the detection threshold and performing the gesture can happen in a very subtle way that is in line with how a Tesla should feel and drive.
I have added some demo movies that illustrate this.
https://github.com/user-attachments/assets/3f844df6-d86f-4fa8-8943-76a7297d0469
https://github.com/user-attachments/assets/6f33676a-7c70-4880-a525-950e92ba5b38
https://github.com/user-attachments/assets/bca40b13-84a1-4f48-908f-f1100396e0e3

The source code of the project is on Github:  https://github.com/ginodecock/TeslaBlinker

When driving by enhanced autopilot the blinker controls not just control the blinker lights but also your lane changing. When blinker control is done with this project you actually are driving by gestures. I can say, driving to work this morning made driving a new fun experience