Using Arduino Programing

User avatar
Bazinga+
Exalted Member
Exalted Member
Posts: 383
Joined: March 8th, 2014, 7:10 am
Division: C
State: NY
Has thanked: 0
Been thanked: 0

Re: Using Arduino Programing

Post by Bazinga+ »

I am using an esc brushless motor combo which is attached to and powers an arduino through the BEC , but I've had problems where the car speeds up and doesn't stop(I currently have it programmed to stop after a certain time). I noticed that if one of the connections (ground, voltage, or signal) disconnects, the motor will keep spinning and powering the vehicle for some time. Anyone know how to fix this?
Innovation =/= success
User avatar
windu34
Staff Emeritus
Staff Emeritus
Posts: 1383
Joined: April 19th, 2015, 6:37 pm
Division: Grad
State: FL
Has thanked: 2 times
Been thanked: 40 times

Re: Using Arduino Programing

Post by windu34 »

Bazinga+ wrote:I am using an esc brushless motor combo which is attached to and powers an arduino through the BEC , but I've had problems where the car speeds up and doesn't stop(I currently have it programmed to stop after a certain time). I noticed that if one of the connections (ground, voltage, or signal) disconnects, the motor will keep spinning and powering the vehicle for some time. Anyone know how to fix this?
What combo are you using? Have you programmed a brake in your Arduino code?
In regards to your second question, I really need to see a pic of your setup and/or your code to help you because that makes very little sense.
PM me or email me at [email protected]
Boca Raton Community High School Alumni
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
[email protected] || windu34's Userpage
User avatar
Bazinga+
Exalted Member
Exalted Member
Posts: 383
Joined: March 8th, 2014, 7:10 am
Division: C
State: NY
Has thanked: 0
Been thanked: 0

Re: Using Arduino Programing

Post by Bazinga+ »

windu34 wrote:
Bazinga+ wrote:I am using an esc brushless motor combo which is attached to and powers an arduino through the BEC , but I've had problems where the car speeds up and doesn't stop(I currently have it programmed to stop after a certain time). I noticed that if one of the connections (ground, voltage, or signal) disconnects, the motor will keep spinning and powering the vehicle for some time. Anyone know how to fix this?
What combo are you using? Have you programmed a brake in your Arduino code?
In regards to your second question, I really need to see a pic of your setup and/or your code to help you because that makes very little sense.
PM me or email me at [email protected]
Oh never mind. I'm using a skryrc 9 turn motor ESC combo, and I guess it automatically keeps running its last input if it loses connection to the arduino. Turns out I had a different problem. In the code I used a logarithmic function for a gradual speed increase and decrease, but I just copy pasted the speed up and forgot to change the numbers for the slowing down, so instead it ended up speeding up even faster. But still the car is so fast its scary. I measured its speed when it was going at barely a third max speed, and if was like 40 mph... Even a pillow barrier didn't prevent the car from getting damaged.
Innovation =/= success
User avatar
windu34
Staff Emeritus
Staff Emeritus
Posts: 1383
Joined: April 19th, 2015, 6:37 pm
Division: Grad
State: FL
Has thanked: 2 times
Been thanked: 40 times

Re: Using Arduino Programing

Post by windu34 »

Bazinga+ wrote:
windu34 wrote:
Bazinga+ wrote:I am using an esc brushless motor combo which is attached to and powers an arduino through the BEC , but I've had problems where the car speeds up and doesn't stop(I currently have it programmed to stop after a certain time). I noticed that if one of the connections (ground, voltage, or signal) disconnects, the motor will keep spinning and powering the vehicle for some time. Anyone know how to fix this?
What combo are you using? Have you programmed a brake in your Arduino code?
In regards to your second question, I really need to see a pic of your setup and/or your code to help you because that makes very little sense.
PM me or email me at [email protected]
Oh never mind. I'm using a skryrc 9 turn motor ESC combo, and I guess it automatically keeps running its last input if it loses connection to the arduino. Turns out I had a different problem. In the code I used a logarithmic function for a gradual speed increase and decrease, but I just copy pasted the speed up and forgot to change the numbers for the slowing down, so instead it ended up speeding up even faster. But still the car is so fast its scary. I measured its speed when it was going at barely a third max speed, and if was like 40 mph... Even a pillow barrier didn't prevent the car from getting damaged.
Ya I recommend setting aside a full weekend and hammering out the code; its going to take alot of trial runs and code tinkering to be able to properly control your setup.
Boca Raton Community High School Alumni
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
[email protected] || windu34's Userpage
User avatar
Bazinga+
Exalted Member
Exalted Member
Posts: 383
Joined: March 8th, 2014, 7:10 am
Division: C
State: NY
Has thanked: 0
Been thanked: 0

Re: Using Arduino Programing

Post by Bazinga+ »

Nah the code is quite simple. It took me like a week to get the encoder code working , but for this I just made it speed up and slow down linearly.
Innovation =/= success
User avatar
windu34
Staff Emeritus
Staff Emeritus
Posts: 1383
Joined: April 19th, 2015, 6:37 pm
Division: Grad
State: FL
Has thanked: 2 times
Been thanked: 40 times

Re: Using Arduino Programing

Post by windu34 »

Has anyone found that the code needed to run the many functions of the vehicle takes up too much space and CPU on the arduino? I have decided to split my code up inoto components to multiple arduinos in orderto smoothly run it using arduino master slave connections.
Boca Raton Community High School Alumni
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
[email protected] || windu34's Userpage
User avatar
Bazinga+
Exalted Member
Exalted Member
Posts: 383
Joined: March 8th, 2014, 7:10 am
Division: C
State: NY
Has thanked: 0
Been thanked: 0

Re: Using Arduino Programing

Post by Bazinga+ »

windu34 wrote:Has anyone found that the code needed to run the many functions of the vehicle takes up too much space and CPU on the arduino? I have decided to split my code up inoto components to multiple arduinos in orderto smoothly run it using arduino master slave connections.
I don't see any point in having 2 arduinos. I've figured out how to make sure the program runs smoothlyand on a regular arduino uno (took a looot of trouble shooting), and I doubt that will fix it. I tried running everything from an arduino DUE (specs are all like 10x better than uno) and still had the same problem so the issue is the program not the processor (an instrument is only as good as its musician). I'd definitely start with Google.
Innovation =/= success
User avatar
finagle29
Exalted Member
Exalted Member
Posts: 51
Joined: January 28th, 2013, 11:37 am
Division: Grad
State: PA
Has thanked: 0
Been thanked: 0

Re: Using Arduino Programing

Post by finagle29 »

windu34 wrote:Has anyone found that the code needed to run the many functions of the vehicle takes up too much space and CPU on the arduino? I have decided to split my code up inoto components to multiple arduinos in orderto smoothly run it using arduino master slave connections.
Might be an indication that you're overcomplicating the problem: keep it simple silly. Although modularization across arduinos is an interesting challenge, is it worth the effort and can it perform as well as smaller, simpler code on one arduino?
Bayard Rustin HS Alum

2013 Events: Thermo, Circuit Lab, Experiment, Robot Arm
2014 Events: Circuit Lab, Experiment, TPS, Mat Sci, Astro
2015 Events: Astro, Chem Lab, Compound Machines, Experiment, Time, TPS
2016 Events: Astro, Cell Bio, Chem Lab, Electric Vehicle, Time, Protein Modeling, Wind Power
Locked

Return to “Electric Vehicle C”

Who is online

Users browsing this forum: No registered users and 1 guest