Using Arduino Programing
-
- Exalted Member
- Posts: 383
- Joined: Sat Mar 08, 2014 7:10 am
- Division: C
- State: NY
- Has thanked: 0
- Been thanked: 0
Re: Using Arduino Programing
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
-
- Staff Emeritus
- Posts: 1382
- Joined: Sun Apr 19, 2015 6:37 pm
- Division: Grad
- State: FL
- Has thanked: 2 times
- Been thanked: 37 times
Re: Using Arduino Programing
What combo are you using? Have you programmed a brake in your Arduino code?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?
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 Jazzin710@gmail.com
Boca Raton Community High School Alumni
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
kevin@floridascienceolympiad.org || windu34's Userpage
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
kevin@floridascienceolympiad.org || windu34's Userpage
-
- Exalted Member
- Posts: 383
- Joined: Sat Mar 08, 2014 7:10 am
- Division: C
- State: NY
- Has thanked: 0
- Been thanked: 0
Re: Using Arduino Programing
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.windu34 wrote:What combo are you using? Have you programmed a brake in your Arduino code?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?
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 Jazzin710@gmail.com
Innovation =/= success
-
- Staff Emeritus
- Posts: 1382
- Joined: Sun Apr 19, 2015 6:37 pm
- Division: Grad
- State: FL
- Has thanked: 2 times
- Been thanked: 37 times
Re: Using Arduino Programing
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.Bazinga+ wrote: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.windu34 wrote:What combo are you using? Have you programmed a brake in your Arduino code?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?
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 Jazzin710@gmail.com
Boca Raton Community High School Alumni
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
kevin@floridascienceolympiad.org || windu34's Userpage
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
kevin@floridascienceolympiad.org || windu34's Userpage
-
- Exalted Member
- Posts: 383
- Joined: Sat Mar 08, 2014 7:10 am
- Division: C
- State: NY
- Has thanked: 0
- Been thanked: 0
Re: Using Arduino Programing
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
-
- Staff Emeritus
- Posts: 1382
- Joined: Sun Apr 19, 2015 6:37 pm
- Division: Grad
- State: FL
- Has thanked: 2 times
- Been thanked: 37 times
Re: Using Arduino Programing
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
kevin@floridascienceolympiad.org || windu34's Userpage
University of Florida Science Olympiad Co-Founder
Florida Science Olympiad Board of Directors
kevin@floridascienceolympiad.org || windu34's Userpage
-
- Exalted Member
- Posts: 383
- Joined: Sat Mar 08, 2014 7:10 am
- Division: C
- State: NY
- Has thanked: 0
- Been thanked: 0
Re: Using Arduino Programing
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.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.
Innovation =/= success
-
- Exalted Member
- Posts: 51
- Joined: Mon Jan 28, 2013 11:37 am
- Division: Grad
- State: PA
- Has thanked: 0
- Been thanked: 0
Re: Using Arduino Programing
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?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.
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
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