Results 1 to 6 of 6

Thread: Signalling a STAMP from the serial port?

  1. #1
    Admin. Linux loser.
    Auto Apps:loading...
    Bugbyte's Avatar
    Join Date
    Sep 2004
    Location
    Corning, NY
    Posts
    7,359
    Blog Entries
    2

    Signalling a STAMP from the serial port?

    I'm nearly finished with a STAMP circuit to activate a servo in the car. I want to activate it in two ways. First, with a momentary push button switch. I've figured out how to do this and it works fine.

    I'd also like to activate the same servo via the computer. I'd like to use voice control to do it. I'm thinking that a VB program that "lights" up one of the serial port pins for a 1/4 second or so and then link that pin to the same pin that the momentary push button switch is connect to would work.

    My question is - is this a viable way to do this? If so, what is the appropriate command to send to the port?

    Thanks in advance.
    Quote Originally Posted by ghettocruzer View Post
    I was gung ho on building a PC [until] just recently. However, between my new phone having internet and GPS and all...and this kit...Im starting to have trouble justfiying it haha.
    Want to:
    -Find out about the new iBug iPad install?
    -Find out about carPC's in just 5 minutes? View the Car PC 101 video

  2. #2
    Maximum Bitrate kiltjim's Avatar
    Join Date
    Feb 2004
    Location
    PA, USA
    Posts
    805
    So you don't waste outputs on the serial port, use a DTS or RTS pin. I know VB is able to do this, but it depends on the library you use for the command. You can easily program the pin to go high for any amount of time by triggering a timer to go off, and then signal the pin to go low again. If anything, you can always program the STAMP to using the BUTTON command, and regardless of the length of the signal it would go off.
    2000 Subaru OBS

    Dell P3 @ 900 Mhz
    7" Lilliput TS w/DigitalWW in-dash mount
    80GB External HD

    I am Zero Bitrate....

  3. #3
    Constant Bitrate takissd's Avatar
    Join Date
    May 2004
    Location
    San Diego, CA
    Posts
    118
    since you are using the serial port why arent you sending a message through it, let's say "A1" and then have the stamp reading the serial port (thru the dedicated pin 16 - serial port) or another pin using the "serin" command. When you send A1 (thats pretty easy to do with VB) it will make the servo open and sending A0 it will make it close the tray. That way you have more control over it! Dont forget you can make more commands to use other stuff through the stamp!
    -VIA EPIA M10000/512MB/40GB HD
    -DWW motorized 7'
    -BU 303 GPS w/iGuidance/ CF
    -Opus90w
    -Belkin Bluetooth
    -Pioneer HU

    [||||||||||] 95% done

  4. #4
    Admin. Linux loser.
    Auto Apps:loading...
    Bugbyte's Avatar
    Join Date
    Sep 2004
    Location
    Corning, NY
    Posts
    7,359
    Blog Entries
    2
    Because I didn't know there was a "serin" command.

    I like your suggestion. So I could implement this...how?

    1. Connect WHICH line from the serial cable to pin 16 of the STAMP?

    2. I'm pretty sure I can figure out from the STAMP documentation how to handle a code received from the serial port on the STAMP.

    3. What would I do to set up the serial port on the computer? I mean, baud, bit rate, parity. Since I'm already using VB to communicate with a serial servo controller (that's what the STAMP replaces), I'm pretty sure I can figure out how to communicate with the STAMP if I know the right settings.
    Quote Originally Posted by ghettocruzer View Post
    I was gung ho on building a PC [until] just recently. However, between my new phone having internet and GPS and all...and this kit...Im starting to have trouble justfiying it haha.
    Want to:
    -Find out about the new iBug iPad install?
    -Find out about carPC's in just 5 minutes? View the Car PC 101 video

  5. #5
    Constant Bitrate takissd's Avatar
    Join Date
    May 2004
    Location
    San Diego, CA
    Posts
    118
    hmmmm...ok: connect on serial port DSR and RTS together. then Rx of serial port goes to pin 1 of stamp (SOUT) Tx goes to (SIN) pin 2 . For more info go to page 26 on the stamp manual it has a good picture in there.
    Now for serin the general command is
    SERIN Rpin { \Fpin }, Baudmode, { Plabel, } { Timeout, Tlabel, } [ InputData ]
    where Fpin is 16 for our case. (page 385 on latest stamp manual from parallax.com)

    it has several examples in there to basically its like cut and paste

    Let me know if you have questions!
    btw i was talking about stamp II
    -VIA EPIA M10000/512MB/40GB HD
    -DWW motorized 7'
    -BU 303 GPS w/iGuidance/ CF
    -Opus90w
    -Belkin Bluetooth
    -Pioneer HU

    [||||||||||] 95% done

  6. #6
    Constant Bitrate takissd's Avatar
    Join Date
    May 2004
    Location
    San Diego, CA
    Posts
    118
    oh yeah parity and all that, 9600 N 1 from what i remember...
    -VIA EPIA M10000/512MB/40GB HD
    -DWW motorized 7'
    -BU 303 GPS w/iGuidance/ CF
    -Opus90w
    -Belkin Bluetooth
    -Pioneer HU

    [||||||||||] 95% done

Similar Threads

  1. serial port to game port adapter wiring
    By asif in forum General Hardware Discussion
    Replies: 5
    Last Post: 08-17-2006, 05:47 PM
  2. USB Serial Port Adapter Troubles
    By bLindmOnkey in forum General MP3Car Discussion
    Replies: 0
    Last Post: 10-14-2004, 12:29 AM
  3. Via Mini-ITX Epia 5000 serial port not working
    By vash in forum General Hardware Discussion
    Replies: 2
    Last Post: 08-13-2002, 09:48 PM
  4. how can I use my printer port as a serial port on win Xp
    By babas151 in forum General Hardware Discussion
    Replies: 3
    Last Post: 04-09-2002, 06:23 PM
  5. 1 serial port, 2 devices
    By Meatballman in forum General Hardware Discussion
    Replies: 7
    Last Post: 04-16-2000, 11:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •