Shop OBEX P1 Docs P2 Docs Learn Events
BS2 bidirectional communications — Parallax Forums

BS2 bidirectional communications

Dirty HowiDirty Howi Posts: 20
edited 2013-11-13 12:10 in BASIC Stamp
Is it possible to send a command from a pc to a BS2 to have it turn on one/many LED lights? we are skonking something here at the office.

basically we scan a item barcode, look up the item, and based on attributes send a string of numbers "1,4,7" to the BS2 from the PC and have it turn on outputs 1,4,7 which have lights on it.

still awaiting the manuals and kit so thought i'd ask :)

thanks ya'll.

Comments

  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2013-11-13 12:03
    Welcome to the forum!! Feel free to ask any of your questions here. There are several knowledgeable people here to help.

    If your PC program can send serial data, then yes absolutely. You can even simplify your example by sending the ON/OFF pattern as a binary number. So up to eight LEDs could be controlled per data BYTE that you send.
  • PublisonPublison Posts: 12,366
    edited 2013-11-13 12:05
    Dirty Howi wrote: »
    Is it possible to send a command from a pc to a BS2 to have it turn on one/many LED lights? we are skonking something here at the office.

    basically we scan a item barcode, look up the item, and based on attributes send a string of numbers "1,4,7" to the BS2 from the PC and have it turn on outputs 1,4,7 which have lights on it.

    still awaiting the manuals and kit so thought i'd ask :)

    thanks ya'll.

    Welcome to the forums!

    The BS2 can accept serial input via the SERIN command. On a standard BS2 , this is usually limited to 9600 BAUD.

    Are you going to use Visual Basic on the PC side, or a custom program?


    EDIT: Beau types faster than me. :)
  • Dirty HowiDirty Howi Posts: 20
    edited 2013-11-13 12:10
    the lookup service will be in C#, i'll figure out how to send via Serial/USB adapter (will be on a laptop initially) i'm just gathering parts and info right now ;) thanks, but as is a typical engineer, mind runs faster than fingers sometimes LOL.

    so something like

    1..scan barcode
    2..hit service, get lights needed
    3..send data to BS2 rig
    4..Light up lights

    so there will be a test client software, a WCF service to interface to the database, then the BS2 rig to do the actual work :)
Sign In or Register to comment.