Pages: [1]   Go Down
Author Topic: Help needed Arduino Uno R3  (Read 2021 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm new to Arduino and was trying to use a stepper with the EasyDriver, Im using a code i found here http://www.danielschweinert.com/resources/BLOG/stepperSingleChannel03.pde. The problem is whenever i connect the EasyDrive GND to the UNO GND the L-LED goes off, i'm very poor in programming and therefore cannot see what is wrong with the code, can someone help me find why the code is not working in my setup?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No one willing to give a hand????
Logged

Offline Offline
Faraday Member
**
Karma: 67
Posts: 2701
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Your stepper should be powered by an external power supply, not the Arduino.
Would you show us how the project is wired, a diagram and/or picture?
Logged

The way you have it in your schematic isn't the same as how you have it wired up!

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Here is the connection also borrowed from Daniels blog
Logged

Offline Offline
Faraday Member
**
Karma: 67
Posts: 2701
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Don't be upset, but re-check YOUR wiring, is it the same as this diagram?
Is your battery fully charged?
If you disconnect the motor does the sketch run OK?
Logged

The way you have it in your schematic isn't the same as how you have it wired up!

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Have disconnected everything except the ground, when i remove the ground and run it over the serial monitor i get readings, but when i put the wire back it stops.
Logged

Offline Offline
Faraday Member
**
Karma: 67
Posts: 2701
The last thing you did is where you should start looking.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You could have a bad EasyDriver.

When you put the ground back and the L LED goes out, what voltage do you measure on the Arduino +5 pin?
Is the Arduino Power LED still on when the L Led goes out?
Logged

The way you have it in your schematic isn't the same as how you have it wired up!

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, the Arduino Power LED is on, notice that the code was written for Duemilanove, but experts say that it should work ok. Another info you need to know is that other sketches all work without any problem.
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17294
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, the Arduino Power LED is on, notice that the code was written for Duemilanove, but experts say that it should work ok. Another info you need to know is that other sketches all work without any problem.

Duemilanove and Uno use same 328P chip, so no difference running on either board type with code generated for either one. Only if total compiled code size is nearly filling the chip can there possibly be a difference as the Uno has a smaller code size bootloader so a slightly larger sketch can be loaded Vs the Duemilanove board.

Lefty
« Last Edit: January 23, 2013, 08:13:42 pm by retrolefty » Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Still no help
Logged

Offline Offline
Full Member
***
Karma: 5
Posts: 113
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Still no help
Hmmm. Not here at you're beck & call - be polite!

You say you are new, have you managed to get other sketches working?

I don't know this stepper card.
If you connect dir & step to LED's to they light (I assume you have no scope, or maybe a multimeter?) - i.e. are you producing signals?

Since there is no clock, can you static drive the card by manually supplying signals to these two pins.
It was said above that you may have a dud board, so you need to isolate where the problem is - Arduino pins, software, the board, the motor, power-supply.
Where does your 12V come from? does it provide enough current?
Logged

For whom does the clock pulse? It pulses for you!

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Sorry for not being polite.
Both cards work with other sketches without any problem at all, works even with other sketches i have scavanged around internet, the reason i went for this code is that it has extended functions and mainly that it solves a bug i had with another sketch whereby the stepper sometimes disregards the direction change command. And if you check this code, it had the same problem initially.
Logged

Offline Offline
Full Member
***
Karma: 5
Posts: 113
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

So, have you connected an LED/scope/analyser/meter/Serial etc. to pins 11 & 12 (no board)? Have you verified outputs exist as expected?
Are your press-buttons/pots working as expected, again, meter and/or output result of press-buttons to other (13?) ports. i.e. intercept the change in the code and call a routine to toggle the pin.

Silly question, but have you double checked your wiring?
A ploy I like to use, is explain the problem to someone who doesn't have any understanding (gf/bf, wife/husband etc. are useful) it helps you to see the wiring/code more accurately without glossing over the bits "you know". Many a time I've got to the point of "and this makes this go..... Oh!" Another bug sorted smiley-wink Also flowcharting someone else's code can help.

Do you have a simulator? I use this one http://www.arduino.com.au/Simulator-for-Arduino.php It's still under development, but can save hours. I'm waiting on the latest release.

Quote
Both cards work with other sketches without any problem at all,

If they STILL work as expected with other sketches, you have two options - wiring (always a good idea to use different coloured wire smiley-small) or code - start breaking it down!

Slightly off topic:
Personally, if I were going to offload the pin count to another board, I'd probably include the ramp too on the driver board and give it i2c communication. Check out the PICs at microchip, they have a massive range of products and a very mature free development system MPLAB. You say you are new to Arduino, but the above is not beyond you smiley
« Last Edit: January 25, 2013, 04:21:58 am by 0AlphaOmega » Logged

For whom does the clock pulse? It pulses for you!

Offline Offline
Newbie
*
Karma: 0
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks alot , let me try experimenting with your suggestions and see how far i can go then come back with a feedback.
Logged

Pages: [1]   Go Up
Jump to: