Hi everyone,
I am working on a project that is using 2 dc motors with encoders (running one after the other). I have a working code that is controlled by which key on the keyboard I press. For both motors I have made a command so that when a set key is pressed the motor will go back to a count of 0 (start position) and when I test this using just one motor I can see it working with the serial monitor counting the encoder. Is it possible to count for both motors in the same code? So when the first motor has run its course and has been made to go back to a count of 0, I can then control the next motor in the same monitor window and it will then count for that motor. Sorry if I have explained this poorly. Any help is much appreciated, I still very new to arduino so I may be missing something obvious.
Thanks