Shop OBEX P1 Docs P2 Docs Learn Events
Adding a 2nd BS2 — Parallax Forums

Adding a 2nd BS2

johntechjohntech Posts: 8
edited 2006-08-24 19:59 in BASIC Stamp
I have the BS2 Discovery Kit and have went through most of the stuff in the What's a Microcontroller book.
My question is is it possible to connect 2 [url=mailto:BS2@'s]BS2's[/url] together and have them communicate with each other?

Also is it possible to pull the BS2 chip off the kit board and place it on my own board and supply it with 5 volts dc? Would I need anything else to run the chip once I have it programmed?

Comments

  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-08-24 12:05
    johntech -

    The answer to your first question is YES, via SERIN/SEROUT. I can't answer your second question, as I've never personally seen a "Discovery Kit".

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-08-24 12:24
    Yes, you can put the BS2 on your own board. Put +5 to Vdd, and tie Vss to ground. I think you need to tie ATN somewhere. You can download the BOE schematic from the Parallax website for guidance.

    Personally, I like the $20 "Super Carrier Board", http://www.parallax.com/detail.asp?product_id=27130
    This gives you some prototyping area where you can add sockets or chips·to make your own circuits.

    Post Edited (allanlane5) : 8/24/2006 12:27:44 PM GMT
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-24 15:42
    With 5V and Ground you could have it on the breadboard area (once programmed).· You don't need to worry about the ATN pin or anything else.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • johntechjohntech Posts: 8
    edited 2006-08-24 18:38
    To comunicate with each other, I would have to write some sort of serial routine to do that correct?
    Or could I connect an output from one to the input of the other as sort of like a "trigger" and visa versa?

    A simple example woulds be : BS2 #1 would run until something happens and it would send an output high or low to a input
    pin on BS2 #2 and then it would run until it sent a hi/lo signal back to BS2 #1 to "trigger" it to start again

    Thanks for all your help guys!!

    John
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-24 18:47
    You could do it that way if you want.· Previous posts mentioned serial communication, but if you just want to signal it with a high or low you can do that as well, and on the target module just monitor the state of the I/O line in a loop, then react based on its level.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-08-24 19:59
    Typically you connect with a TX pin, an RX pin, and a ground. You then SEROUT the TX pin (while the other does a SERIN on that pin), and do a SERIN on the RX pin, while the other does a SEROUT on the RX pin.

    Typically, you determine one to be the 'Master', while the other is the 'Slave'. You do this, because the 'slave' will spend more time waiting in a SERIN for the 'master' to talk to it. You have to do this because the BS2 doesn't 'buffer' RS232. If the 'receiver' is not waiting in a SERIN when a 'sender' sends to it, it won't get the data.
Sign In or Register to comment.