Shop OBEX P1 Docs P2 Docs Learn Events
Transporter Boe - Bot signaling question — Parallax Forums

Transporter Boe - Bot signaling question

HindsVo-TechHindsVo-Tech Posts: 5
edited 2014-04-18 12:01 in BASIC Stamp
Situatiion: I have a Boe-Bot that we are using as a transporter with a trailer attached and we are using the Ping kit and sensor to autotomically travel through a maze course. We are wanting the Boe Bot to send a signal to the left turn signal when the left servo is activated and another signal when the right servo is activated. It needs to send a signal to pin 12 or pin 13 . When right servo turns, pin 13 needs a high. When the left servo turns we need a high on pin 12. How would we write this in our code?

Comments

  • GenetixGenetix Posts: 1,754
    edited 2014-04-16 15:31
    For what you want to do, the LEDs need their own I/O pins. For example, the left LED on P11 and the right LED on P0.
  • 72sonett72sonett Posts: 82
    edited 2014-04-18 12:01
    We are wanting the Boe Bot to send a signal to the left turn signal when the left servo is activated and another signal when the right servo is activated...
    So I suppose that at some point in your program you tell a servo to start turning, like in a ´turn right´ subroutine. In that subroutine you add a first line like
    HIGH 13
    and on leaving the subroutine, just before the RETURN you add
    LOW 13.
    In the ´turn left´ subroutine you add a first line
    HIGH 12
    and on leaving that subroutine you add
    LOW 12.
Sign In or Register to comment.