Serial to 3 bs2

Hi guys. I am currently working on a project that requires 3 basic stamps and want to be able to program them in their board. I was thinking of using the usb BOE to connect to the computer and have 4 wires come off that (Sin, Sout, ATN, and Gnd) and go through a 3 way switch to each stamp in the main project board, however it doesnt work. I have continuity between each of the 4 pins on the BOE board to each stamp in the main project board and no shorts between them but still nothing. The cable betweeen the BOE board and the switch is approx 800mm long and between the switch and the stamps is approx 400mm long. Is this too long? is there something else i can do?
Any help would be greatly appreciated. Thanks.
«1

Comments

  • If I could have an image or drawing of your setup, then I would probably be able to help.
    All efforts made in vain are doomed to fail.
  • AwesomeCronkAwesomeCronk Posts: 465
    edited 2018-05-25 - 23:58:57
    You could get a USB to Serial adapter for each stamp, and then swap the debugging cable between them all. Also, with you switch, all wires need to be disconnect from stamps 1 and 2 in order to program stamp 3, etc.
    All efforts made in vain are doomed to fail.
  • Thanks AwesomeCronk. I was trying to avoid buying 3 usb to serial adapters, hence using the built in one on the boe board was an idea. And yes the switch does disconnect the other 2 stamps so only 1 is connected at a time. I just dont understand why it wont work if continuity is good, Thats why i thought it may be the length of cable.
  • AwesomeCronkAwesomeCronk Posts: 465
    edited 2018-05-26 - 00:08:38
    Can you post an image of this? Also, a wiring diagram would help.
    All efforts made in vain are doomed to fail.
  • OH! You need to connect the ground of each stamp with that of the BOE in order for proper communication!
    All efforts made in vain are doomed to fail.
  • Yes ground is connected. Stay tuned for a diagram. I will post one a little later.
  • Thanks.
    All efforts made in vain are doomed to fail.
  • Also, could I get a link to the switch you are using?
    All efforts made in vain are doomed to fail.
  • So, ground is shared.
    Sout is connected to switch.
    Sin is connected to switch.
    Atn is connected to switch.
    Correct me if I'm wrong.
    All efforts made in vain are doomed to fail.
  • Your wiring connecting the switch may be messing up somehow, perhaps improper connections?
    All efforts made in vain are doomed to fail.
  • If you have a multimeter, put the switch in position 1 to connect stamp 1 and then check all the pins to Atn on you PC for continuity. Repeat this for all stamps and pins.
    All efforts made in vain are doomed to fail.
  • Yes thats correct.
    Im confused, are you saying all the pins on the selected stamp must have continuity to atn pin on pc?
    I have continuity from atn on boe to tan on selected stamp only.
    continuity from Sin on boe to Sin on selected stamp only
    continuity from Sout on boe to Sout on selected stamp only.
    Gnd is connected to all stamps all the time
  • Yes, what you have is correct.
    All efforts made in vain are doomed to fail.
  • Then why am i pulling my hair out. Is it a sensitive signal that i am sending to the stamps? Do i need to use shielded cable at all?
  • I have a .txt wiring diagram, but do not know how to attach it. PM me with you email and I can send it.
    All efforts made in vain are doomed to fail.
  • Maybe source your Vdd and Vin to the BOE as well.
    All efforts made in vain are doomed to fail.
  • Tried that and to no avail.
  • Victory.
    All working now!! Yay!! Thanks AwesomeCronk.
    I added a 0.1uF cap between gnd and atn on each of the 3 stamps.
  • Glad I could help! If you need anything else, just let me know.
    All efforts made in vain are doomed to fail.
  • cjleydon wrote: »
    Victory.
    All working now!! Yay!! Thanks AwesomeCronk.
    I added a 0.1uF cap between gnd and atn on each of the 3 stamps.

    Glad to hear you found something that worked.

    But I'm curious...what was the problem that the capacitor remedied? Were you able to 'scope the signal on the ATN pin and see something amiss?

    DJ
    Well-written documentation requires no explanation.
  • I looked at the schematic for the USB boe board and for connecting a bs2 to a db9 serial connector and noticed the db9 to bs2 had a cap but the USB boe board didn’t. I just thought I would try it because I had tried everything else and it worked. I’m not exactly sure why though
  • If anyone knows why it worked I would be happy if they shared it here please. I’m always keen on learning more
  • I sure don't.
    All efforts made in vain are doomed to fail.
  • From what I understand about the atn pin it resets the stamp before the program is downloaded. Maybe it is being held on for too long and so the stamp is still being reset while the program is sent. The cap would maybe turn the signal into a short pulse.
    That’s only a guess though. But I still don’t understand why it works without the cap if it’s plugged straight into the boe board. Maybe cable length?
  • Makes sense. The BOE might not have one because it has a timer in it's driver chip(the one that says FTDI in it).
    All efforts made in vain are doomed to fail.
  • cjleydon,

    This comes from Nuts & Volts column #63, which is in Volume 2.
    https://www.parallax.com/downloads/nuts-and-volts-basic-stamps-volume-2

    Figure 63.1 is the programming port and DEBUG interface.
    The capacitors on the ATN line allow the Stamp to be reset by the PC but will block a steady state on the serial DSR line.
    This will be important later when we connect the Stamp to a terminal program.
  • That makes sense.
    All efforts made in vain are doomed to fail.
  • Thanks genetix. Good to know.
  • cjleydon,

    You can find all of those articles here and there is a treasure trove of information in there so take a look.
    https://www.parallax.com/search?search_api_views_fulltext=nuts+and+volts&=Search
Sign In or Register to comment.