Newb needs help. Code routing power to servos instead of LED's!
Hi, folks. I just picked up a Boe-Bot kit and am very excited about it. I have worked with qBasic before, so I have the rudiments of programming down ok, but as far as microcontrollers and breadboards, I am still in larvae phase.
I am following the instructions in chapter 2, activity 2 of the curriculum provided which involves lighting 2 LED's via the breadboard. I have read and re-read the instructions and followed them to the utmost of my abilities, but still when I run the program, it runs power to the servo outputs whose numbers correspond with the pin numbers of the resistor/LED circuits that I'm trying to get to work. Here is the program:
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "The LED to pin 13 is blinking."
DO
HIGH 13
PAUSE 500
LOW 13
PAUSE 500
LOOP
This is verbatim what is in the book. I don't think that it's a wiring problem because if it was, then nothing should happen when I run this code, right? Instead, my left servo is pulsing. I ran the resistors and LED's exactly as pictured in the book too and made sure that all components were seated properly and made good contact. The LED's are correctly oriented polarity-wise. Any advice would be much appreciated.
I am following the instructions in chapter 2, activity 2 of the curriculum provided which involves lighting 2 LED's via the breadboard. I have read and re-read the instructions and followed them to the utmost of my abilities, but still when I run the program, it runs power to the servo outputs whose numbers correspond with the pin numbers of the resistor/LED circuits that I'm trying to get to work. Here is the program:
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "The LED to pin 13 is blinking."
DO
HIGH 13
PAUSE 500
LOW 13
PAUSE 500
LOOP
This is verbatim what is in the book. I don't think that it's a wiring problem because if it was, then nothing should happen when I run this code, right? Instead, my left servo is pulsing. I ran the resistors and LED's exactly as pictured in the book too and made sure that all components were seated properly and made good contact. The LED's are correctly oriented polarity-wise. Any advice would be much appreciated.
Comments
Thanks again for the help.
Not changing your 3-position switch to position 0 is very common when starting off. Hope this helps
Jax
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
If a robot has a screw then it must be romoved and hacked into..