Shop OBEX P1 Docs P2 Docs Learn Events
Bs1usb — Parallax Forums

Bs1usb

CowggoddCowggodd Posts: 3
edited 2006-12-07 17:14 in BASIC Stamp
Hey everyone newbie here but I have a question
I just purchased a BS1USB and I was wondering if anyone could throw me some sample code of how to comunicate with the BS1USB and visual basic 6?· I want to start off with a basic program that clicking certain buttons will turn on certain LED's.· Can anyone help me out? thanks

~Adam

Comments

  • Paul HooverPaul Hoover Posts: 15
    edited 2006-12-06 21:29
    Newbie here too. I've been trying to get the usb to communicate with Flash for some software prototyping. I've gotten the main board to communicate to flash through the serial port by using a socket and now I want to get it working with the usb stick. Any help would be great.
  • tj60647tj60647 Posts: 18
    edited 2006-12-07 01:44
    Hello,

    The BS1USB [noparse][[/noparse]and other USB products from Parallax] are using FTDI chips. The FTDI driver that you install when using this device creates a virtual com port [noparse][[/noparse]VCP] when the USB device is plugged in.

    This COM port will show up just like a serial port on the PC [noparse][[/noparse]or Mac].

    If you are using VB6 [noparse][[/noparse]or the socket thing from the Flash thread http://forums.parallax.com/forums/default.aspx?f=5&m=153716], you will be able to connect to the device as if it were a serial port. We use Flash because it is relatively easy to develop useful interface prototypes.

    Paul, if you have the VCP drivers intalled on your machine and plug in the BS1USB a new serial port will show up when you run Socket2SerialServer.exe.

    We are currently using the Socket2SerialServer to connect Flash to a wireless device which uses the FTDI drivers and a VCP [noparse][[/noparse]the DLP-RF1]...and ultimately to a BS2 with a wireless transceiver [noparse][[/noparse]the DLP-RF2].
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-12-07 03:35
    Hello,
    ·
    ·· Jon Williams did an article on decoding the DEBUG output from the BS1.· He used RealBASIC to write his application, but I understand there are a lot of similarities.· You could probably use the code as a guide to implementing this on VB6.· Please see the link below in our Completed Projects Forum.· Take care.

    http://forums.parallax.com/showthread.php?p=567110


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • CowggoddCowggodd Posts: 3
    edited 2006-12-07 05:17
    haha! wow that was a fast reply! lol just kiddin!· I am slacking on my project here so i just now got the led's set up but i still don't fully understand how the two devices comunicate.· I know i need to dish the money out and buy the beginner's book but i do understand some things.· I know with the serial driver for the BS1USB you can set it to a com port.· Then with VB6 you use the Comm control to send values to it?· But I suppose what i don't understand is what do you put in the device to know what to do with the values it recieves?· I know im not really pulling my part and reading up and working on it more but since the other guy i was working on it with finally returned it i should be back in business in a few days.· So please don't lose hope on me yet lol
  • CowggoddCowggodd Posts: 3
    edited 2006-12-07 05:30
    I just read that article at http://forums.parallax.com/showthread.php?p=567110·by Jon Williams and i understand it a lot moresorry i posted before i read the whole article.· I will try thing out during this week and let you guys know how it goes.
  • Paul HooverPaul Hoover Posts: 15
    edited 2006-12-07 17:14
    Great! I will try that serial connection today and see if it works. Thanks.
Sign In or Register to comment.