Pages: [1]   Go Down
Author Topic: Reading analog input using Arduino Motor Shield  (Read 931 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 27
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi there!
I would like to ask you if it is possible to read an analog input using arduino motor shield while a DC motor is going forward and backward. I have a big problem when I'm trying to do this because a delay of 90ms is necessary in order to move the DC motor and I need to sense an analog input with a sampling time of Ts=0.01s. Could you advice me please?
Thank you!
Logged

New Jersey
Offline Offline
Faraday Member
**
Karma: 65
Posts: 3643
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No reason why not, unless your motor shield is using all your analog pins.

It sounds as though you are using delay though, so you're going to need millis to manage your motor instead so you can read the ADC. As ever, the blink without delay example sketch proviced with the IDE shows you how to use millis in this way.
Logged

Pages: [1]   Go Up
Jump to: