Shop OBEX P1 Docs P2 Docs Learn Events
Connecting 2 BS2 MC together — Parallax Forums

Connecting 2 BS2 MC together

FxProgrmFxProgrm Posts: 3
edited 2005-05-11 15:30 in General Discussion
I am presently working on a project where I have a BS2 and a BS2pe controller linked together using 2 pins.· I am having intermitent problems with the serial communications working from the BS2pe (running sensor reading) and the BS2 (running walking logic).

This is the code in the BS2pe that is sending the message to the master controller:
SEROUT MSTDATA\MSTFLOW,Baud,SerDelay,NoMaster,[noparse][[/noparse]"R"] where MSTDATA is PIN13 and MSTFLOW is PIN12 and Baud is 4800 and SerDelay is a constant defined at 6000.

This is the code in the BS2 that is·reading the message·from the secondary·controller:
SERIN MSTDATA\MSTFLOW,Baud,[noparse][[/noparse]Letter] where MSTDATA is PIN13 and MSTFLOW is PIN12 and Baud is 4800 and SerDelay is a constant defined at 6000.
The BS2 also has serial communications going to the·Parallax Servo Controller·at 9600 baud.

The connections are configured as indicated in the parallax manual for the BS2 with a 1k pulldown/up resistor to ground.

This is all running on the Quad Crawler platform.
Any help or suggestions would be appreciated.

Thanks,

Mike E.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
==== Robotic Toy Box ====

QuadCrawler

Comments

  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-05-11 06:39
    Since you say the problem is intermittent, are you sure it's not a wiring problem?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
  • FxProgrmFxProgrm Posts: 3
    edited 2005-05-11 15:19
    The wiring is as far as I can tell solidly connected.· It seems that if the BS2 is doing something the BS2pe timesout waiting for the BS2 to pickup the message.· I have done some basic timing for the loop that runs on the BS2, and even running the 16 walking steps, it still completes it in a couple seconds which is under the 6 that I have alotted in the serial commands before a timeout.· I have bumped the timeout to 12 seconds and it works better, but does not provide a clue to why it misses on the intervals.· I was thinking that maybe the documentation was incorrect and the pullup/down should be greater than 1k?· Any ideas?

    Thanks,

    Mike E.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ==== Robotic Toy Box ====

    QuadCrawler
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-05-11 15:30
    Perhaps this article will help: http://www.parallax.com/dl/docs/cols/nv/vol3/col/nv81.pdf

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
Sign In or Register to comment.