Well the good news is that I've got new video to share with you. But the rest of this post will just be a bit of a status update. Brakes, I've finally implemented the brake pedal. The wheelchair gearbox includes an electric brake, it's pretty much a spring loaded metal plate that clamps down unless power is applied to it. I had hoped I could send a PWM signal that would slowly apply/release this brake. So that was the first thing I tried with the brake pedal, duty cycle controlled directly by the brake pedal. Sadly, it didn't work. It stayed in one state until a certain duty cycle was reached, and then flipped to the other state. Perhaps a different frequency would have worked, I'm not sure. I decided to not pursue that any further. That brake wasn't really meant for anything more than parking and holding the wheelchair still.
Instead, I implemented the "regen" brakes. Not really a regen, it doesn't recharge the batteries while braking, it simply shorts the motor leads together. When "coasting" the motor is spinning and working as a generator, so when you enable the braking mode on the motor controller, it shorts the motor leads together through the mosfets. This works exceptionally well as a brake. So well that it pretty much locks up the tires under all conditions. It's possible to ramp this on, or make it be more than on/off with the brake pedal, but I believe I'll need wheel speed sensors and a lookup table to do it.
When I implemented the "regen" brakes, I set it up so that when the brake pedal is pressed more than about 80%, it engages engages the parking brake, which is certain to lock up the rear tires. It's handy when at a full stop, the regen brakes don't work when not moving, it'll creep. With the parking brake engaged, it's not going to budge.
Next up, I plan to implement the buttons on/in the steering wheel. I'm fully planning on going overboard here. The microcontroller I have controlling the drivetrain is a Teensy++, I plan to put a Teensy inside the steering wheel. The Teensy is a lot like the Arduino Mini (nano? whatever they call it), but has native USB for easier programming. The reason I want to have a full on microcontroller up there is that I can simply run 4 wires from it to the Teensy++ in back (power, ground, and I2C's pair). The steering wheel has paddles on it, I'll use the right paddle for forward, and left for reverse. There are also something like 6 buttons and 6 LED's that I can use for various features and indicators.
Here's the latest video, with my kids riding the thing around.
I'll post the latest code that's running on it soon. Right now it's still a rough draft that would be a poor example for anyone to look at. I can barely follow the flow myself.