Parallax Servo Controller with Basic Stamp

Started by ryan_autet June 20, 2005
Hi Im having Trouble using the Parallax servo controller with the
basic X. With the Basic Stamp it sent pw.LOWBYTE pw.HIGHBYTE but The
basic X doesnt sopost that function so. Does any one out know what
exacly it sends when it does that, so i can try and mimic it or has
any one had any sucsess using the BasicX 24 with a Parallax servo
controller?

If so please write back



ryan_autet wrote:

> Hi Im having Trouble using the Parallax servo controller with the
> basic X. With the Basic Stamp it sent pw.LOWBYTE pw.HIGHBYTE but The
> basic X doesnt sopost that function so. Does any one out know what
> exacly it sends when it does that, so i can try and mimic it or has
> any one had any sucsess using the BasicX 24 with a Parallax servo
> controller?
>
> If so please write back

From the documentation the full command is !SC C R pw.LOWBYTE,
pw.HIGHBYTE, $0D

You need some code like this:

Private Const InputQueueSize As Integer = 10 ' 1 byte buffer.
Private Const OutputQueueSize As Integer = 30 ' 1-byte buffer.
Private Const SerialPin as Byte = 20
Private Const Baud As Long = 9600

Private InputQueue(1 To InputQueueSize) As Byte
Private OutputQueue(1 To OutputQueueSize) As Byte

Public Sub OpenSerialPort()
Call OpenQueue(InputQueue, InputQueueSize)
Call OpenQueue(OutputQueue, OutputQueueSize)
Call DefineCom3(SerialPin, 0, bx1000_1000)
Call OpenCom(3, Baud, InputQueue, OutputQueue)
End Sub

PutQueue and PutQueueString will write data into the output queue for
sending on serial port.

Mike


LOL
ok i know i need some code like. I finished that like 3 days go.
Now i need to know what pw.LOWBYTE and PW.HIGHBYTE Sends on the Basic Stamp.
So i can have the BasicX 24 send some thing simaliar. Seeing as it soport
these functions. >From: Mike Perks <basicx@basi...>
>Reply-To: basicx@basi...
>To: basicx@basi...
>Subject: Re: [BasicX] Parallax Servo Controller with Basic Stamp
>Date: Mon, 20 Jun 2005 14:18:02 -0500
>
>ryan_autet wrote:
>
> > Hi Im having Trouble using the Parallax servo controller with the
> > basic X. With the Basic Stamp it sent pw.LOWBYTE pw.HIGHBYTE but The
> > basic X doesnt sopost that function so. Does any one out know what
> > exacly it sends when it does that, so i can try and mimic it or has
> > any one had any sucsess using the BasicX 24 with a Parallax servo
> > controller?
> >
> > If so please write back
>
> From the documentation the full command is !SC C R pw.LOWBYTE,
>pw.HIGHBYTE, $0D
>
>You need some code like this:
>
>Private Const InputQueueSize As Integer = 10 ' 1 byte buffer.
>Private Const OutputQueueSize As Integer = 30 ' 1-byte buffer.
>Private Const SerialPin as Byte = 20
>Private Const Baud As Long = 9600
>
>Private InputQueue(1 To InputQueueSize) As Byte
>Private OutputQueue(1 To OutputQueueSize) As Byte
>
>Public Sub OpenSerialPort()
>Call OpenQueue(InputQueue, InputQueueSize)
>Call OpenQueue(OutputQueue, OutputQueueSize)
>Call DefineCom3(SerialPin, 0, bx1000_1000)
>Call OpenCom(3, Baud, InputQueue, OutputQueue)
>End Sub
>
>PutQueue and PutQueueString will write data into the output queue for
>sending on serial port.
>
>Mike >Yahoo! Groups Links >