Close

Electronics and Remote Control

A project log for Electric Longboard

Can we build a great board for under $400 in less than 3 weeks? (using a few pre-made kit parts)

dudeskidaddydudeskidaddy 06/13/2016 at 17:360 Comments

We wanted to build our own transmitter receiver. Lots of options here. Right now we're playing with Arduino/ATTNIY85 communicating over Serial RF using 2 HC-12s. Need to make sure we get a consistent signal, can transmit data fast enough...figure 20 updates/second is more than enough. This is all under development and haven't made any attempt to drive the motor via Serial communication yet.

In the meantime...we really wanted to play with that motor...and also some basic control logic. The biggest concern will be how to slowly spool up and spool down the motor when the rider moves the throttle quickly. Our ESC (engine speed controller) has only a few options here...so we're forced to do all this in the controller.

We're using a thumb-stick from Spark-Fun and generating a PWM signal from our Arduino Nano that is directly wired to the ESC. We wrote some code to enable a "setup mode" when starting the remote control while holding down the thumb-stick button. This is useful for calibrating the min/max throttle. We also added some logic to slowly spool the motor up/dn. We use a 25ms delay in the control loop, and add/subtract 1 from the PWM value for each iteration.

Speed Control: Right now I'm limiting the motor speed to 50% by simply limiting the PWM sign to half the max value we used when setting up the ESC. Haven't used this yet, so not sure how limiting speed affects torque. I'd like to get max torque for good acceleration, but limit the top speed for safety. Maybe need a better ESC for that, an engine speed sensor...not sure, yet.

I'm hearing a little wheel / belt alignment in this vid. Not really able to get that rear sprocket 100% aligned to the wheel and it has a very very slight wobble... Something to think about.

(update 6/4/2016 The spool up/spool down speed is impossible to measure upside down and un-loaded. Unloaded the motor can go from 0 to full speed practically instantly. Under load it might take a few seconds. The purpose of calibrating acceleration is to make it take around 6 seconds so you don't fall off)

Discussions