Closed RoboDurden closed 1 year ago
I have this hardware Arduino Nano. Is it suitable for the software example you requested?
Yes, the Atmega328P can handle 19200 SoftwareSerial. But do not spend too much time on the example. I could copy and paste something in 10 minutest. Simply do not want to do because i completely rewrote the serial communication with my Gen2.x so i do not want do see that old Gen2.0 serial code. With the code and links i posted here, people should succeed with code themselves. But if you really want to support your repo, than a simple .ino with an Atmega238p would be best.
Thanks for your requests/suggestions. I added a much simpler solution in the repos for testing the motor (on the Slave side):
Have fun and let me know how it goes.
Yes that is also a good idea. Still users will need some arduino code to make use of the firmware. And most users have never even done any arduino code ! So an arduino example usually is very helpful. Don't want to cause you any trouble. As i said, if i thought it to be very important, i would have already done it. But 99% of all users only do "stupid fun projects", so i am am happy with your repo to compile with my online compiler. And some of the users come up with an arduino example :-)
Sorry i can no longer flash binaries to my gen 2.0 setup even so it was just sitting untouched on my desk for a few months. ST-Link no longer connects. No happiness to spend more time on this today. And tomorrow i will leave again for a few weeks.
Someone else will have to test the binaries.
P.S. the test binary should be a master so users can check that both motors are spinning before begining with the arduino code.
So with my Gen2.x i put the TEST_SPEED
in the #ifdef MASTER
section, overwriting the speed and steer that is supposed to be received from the arduino:
#ifdef TEST_SPEED
speed = 3 * (ABS(( ((int32_t)steerCounter+100) % 400) - 200) - 100);
//speed = 300;
#endif
Done.
Nice to see that your are willing to maintain your repo. Thanks :-)
Thank you very much for creating the makefile. So i have added this repo to my online compiler: https://pionierland.de/hoverhack/
Would be nice if you could add a simple arduino example as this firmware needs 19200 baud serial communicatoin to control it.
Simple one liner to vary speed from -300 to +300:
SendAnswer() might be the original function from https://github.com/flo199213/Hoverboard-Firmware-Hack-Gen2/blob/master/PPMDeviceArduino_V1.0/PPMDevice/SteeringSerial.cpp
greeting from Germany, Roland and please sign my petition "comprehensive plan for Peace in the world ": www.RoboDurden.de !!!