It's been a long time between posts, I've just moved to the USA, started a new job. But I have been able to start working on this motor control again. Purchased some new batteries (8x 15Ah LiFePo headway cells with a BMS!!) and am starting to work through getting my bike up and running.
If anyone has been following and wants to try building a motor control, now might be the time to take the dive because...
I'm releasing hardware V5.0 incorporating:
- A (working + tested) over current protection implemented in hardware.
- All logic on the power board now uses the same 3.3V rail, simplifying the power supplies.
- 5V buck exclusively for phone charging and other external circuitry.
- Capability to mount a daughter board directly to the power module for bluetooth support etc.
All in all, while I'm yet to drive serious power through it, I feel this hardware is quite stable.
Files created in Altium Designer btw. I'm looking into converting it over to CircuitMaker.
And I'm also releasing some software to make it run. it's still pretty fundamental, I've zipped up a cut down version of Motorware 12 (which is a few versions behind the current 15, but I haven't had time to update my code base, I've modified a bunch of files to get my hardware and the serial port working) So all that's required to compile, debug and run is TI's IDE, Code Composer Studio (I'm running V6, the latest). Create a new workspace and import the projects from "solutions\instaspin_foc\boards\boostxldrv8301_revB\f28x\f2802xF\projects\ccs5"
The software I'm running on my bike is a modified "lab 5a" It drives the motor with constant current based on throttle position, regenerative braking is supported via a second potentiometer. Some basic runtime data is periodically transmitted over 9800baud serial.
Lab 2b is also included for measuring motor parameters, after the software has finished analysing the motor, lab2b has a constant speed mode for testing the motor control and measured parameters, which should then be copied into a new motor profile in 'user.h' before using lab 5.
See TI's instaspin website for the lab user guide which contains all the info you will need to get started.
And please post any comments. Files are in dropbox links on the left.