Skip to content
pcacePublic

About

opensource e-Bike controller replacement for ampler bikes (generation 1)

Resources

Stars

7 stars

Watchers

3 watching

Forks

Latest commit

 

History

14 Commits

Folders and files

Repository files navigation

Tailwind

ESP32 firmware for the VESC conversion of a 2018 Ampler Curt. Tailwind reads the original pedal sensors, controls motor assistance over UART, and serves a ride dashboard over Wi-Fi.

Build and connect

Check the wiring, hardware constants, and assist settings. Build with PlatformIO.

pio run -e esp32doit-devkit-v1
pio run -e esp32doit-devkit-v1 -t upload
pio device monitor -b 115200

Keep the pedals unloaded at startup so the ESP32 can calibrate the torque zero. Join Wi-Fi Tailwind with password tailwind and open the dashboard.

How to upgrade firmware

The old single-slot layout needs one USB upload from the build instructions above. After that, use Wi-Fi for upgrades.

  1. Run pio run -e esp32doit-devkit-v1 to build .pio/build/esp32doit-devkit-v1/firmware.bin.
  2. Stop the bicycle and leave the pedals unloaded. Join Tailwind, open the dashboard, and select Aus.
  3. Under Firmware-Update, choose firmware.bin, enter the device's update key, and start the upload.
  4. Keep the ESP32 powered until it restarts. Rejoin Tailwind if needed and check that Standard is active.

For this bike, the update key is saved locally as .git/tailwind-ota-key.txt. In a linked worktree, find the shared Git directory with git rev-parse --git-common-dir. To recover the key over USB or troubleshoot an update, see firmware diagnostics.

Ride modes

Standard is active when the controller starts. One full backward crank revolution cycles through Standard → Turbo → Aus. The GPIO4 LED blinks once, twice, or three times respectively. The dashboard can also select the mode.

Mode API ID Assistance
Standard 0 Speed-dependent assistance with an 8 A launch limit. Use the built-in curve or enable the saved Custom curve in the dashboard.
Turbo 1 Up to 350 W of requested rolling assistance and a 15 A launch limit.
Aus 2 Motor assistance off.

The two assisting modes blend from their launch settings into rolling assistance between 2 and 8 km/h. The ESP limits the motor-current command to 15 A. The VESC applies its own limits.

The torque sensor reads load at the left crank. Standard and Turbo reuse a valid measured sample 16 forward PAS steps later, half a crank revolution. Reverse pedaling, a pause, or a break in the step sequence clears the history. The live ADC threshold still controls assistance.

The dashboard stores rides in the browser and exports CSV. The Custom curve and its selection are saved on the ESP32.

Diagnostics and hardware

Run the native tests with pio test -e test. The firmware uses the bundled VescUart library.

Tailwind is an experimental controller. Its current configuration does not enforce a 25 km/h assist cutoff.

MIT License

About

opensource e-Bike controller replacement for ampler bikes (generation 1)

Resources

Stars

7 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages