Wireless Controller for Pacer Powered Vehicles
This is the firmware for controllers that are compatible with Pacer powered vehicles.
The controller works by performing a handshake with the Pacer powered vehicle and will then send inputs in for acceleration, brake or neutral signals.
What is Pacer?
Pacer is a development platform that enables fast and cheap development of light electric vehicles.
Pacer bundles open source software with modular hardware components.
Pacer was created to simplify the development of light electric vehicles by providing out of the box trivial functionality like connectivity, controlling and state management of the vehicle.
Software Getting Started
Set up a PlatformIO development environment for ESP8266. (Check this guide)
Build and Upload
pio run --target upload(run this command in the root of the project) Note: You might want to look through the config file in
data/directory and change relevant configurations.
Hardware Getting Started
Note: The commands and the handshake procedure is described in the Commands.h file.
In this setup a Pacer powered vehicles is refered to as Master and the controller is refered to as Slave.
- Master requests name from slave on the defaule radio address and channel.
- Slave send the name to the Master.
- Master sends a newly generate address to the slave.
- Slave saves the received address and sends it back.
- Master validates that the new address was transmitted correctly and asks the Slave to proceed to changing the address.
- Both Master and Slave change addresses.
- On the new address Master is sending the clearest channel to Slave.
- Slave saves the new channel and sends it back.
- Master validates that the new channel was transmitted correctly and asks the Slave to proceed to changing the channel.
- Both Master and Slave change channels.
- Master asks the Salve to wait until it tries to register the controller.
- If registration was successful Master confirms successful registration and asks the Slave to go into IDLE_MODE
- Slave goes to IDLE mode and waits to be activated. -- Handshake finished --
- Master is moving the communication from the Radhiohanshake class to the NunchuckController classs.
- Master asks the Slave to set ACTIVE_MODE
- Master asks requests inputs from Slave.
- Slave sends inputs to Slave.
There is a forum thread dedicated to Pacer where you can get quick answers to your questions.
You can support the Pacer project by purchasing hardware required for running Pacer and other products from the Faraday Motion Web Shop. We highly appreciate your support.
There is a long road of development until we get Pacer to be the go to solution. Any contributions are highly valued.
For minor fixes of code and documentation, go ahead and submit a pull request.
Feature branches with lots of small commits (especially titled "oops", "fix typo", "forgot to add file", etc.) should be squashed before opening a pull request. At the same time, please refrain from putting multiple unrelated changes into a single pull request.
Constantin Colac and Sune Pedersen