November 23, 2024, 02:26:57 PM

News:

You can now use Vixen to program your Prop-1 and Prop-2 controllers!  Get started quickly and easily, without having to learn PBASIC.  Details in the Library forum.


Beginner Prop SX owner

Started by davisgraveyard, May 14, 2008, 12:33:10 PM

Previous topic - Next topic

JonnyMac

I've got an N&V column due and another project to finish up, but I should be able to start this over the weekend -- I have most of the parts in other projects already, it's just a matter of assembling them and getting everything connected (hardware and software).
Jon McPhalen
EFX-TEK Hollywood Office

JonnyMac

May 16, 2008, 10:00:38 AM #16 Last Edit: May 27, 2008, 08:01:46 PM by JonnyMac
It's interesting what a little time on a treadmill will do for one's creativity....  I actually wrote a more complicated version of this program last night that included a "background" servo controller and UART, but those aren't necessary for this program to work.  This version should do what you want: read the two X/Y joysticks for the Vex transmitter (or receiver) and send those values out to a PC.  If you connect servos to P0..P3 they will respond in real-time to the joystick movement.  This program is 100% SX/B -- no assembly required.

I still have to build a cable to connect my VEX to the Prop-SX; when I get that working I'll show you how.

[Edit] Final program is in this thread: http://www.efx-tek.com/php/smf/index.php?topic=630.msg3339#msg3339
Jon McPhalen
EFX-TEK Hollywood Office

davisgraveyard

I have my Vex Transmitter/Receiver.  Waiting to hear how to build my cable for the Prop SX.  Looking forward to trying your program out.

If I recall from a previous post you suggest just using the transmitter and attaching to the RJ-11 in the back of it.  No need for the receiver right?

Jeff

randyaz

July 27, 2008, 03:22:13 PM #18 Last Edit: July 27, 2008, 05:45:21 PM by randyaz
I just took the PropSX plunge and gave all the literature a first run through....Left me alittle queezy.  There's going to be a steep learning curve for me moving up from PBasic but its going to be worth it.

JonnyMac

Think of it like going from an automatic to a stick-shift: it can feel clumsy at first, but once you get the hang of it you have far better control.  The SX does take a little effort, but SX/B really helps.  This document will be helpful to get you going with SX/B:

-- http://www.parallax.com/Portals/0/Downloads/docs/prod/sx/PracticalSXB.pdf

We're getting close to finishing this book and Parallax will release the final version in a couple months or so.
Jon McPhalen
EFX-TEK Hollywood Office

gmacted

July 27, 2008, 08:08:03 PM #20 Last Edit: July 29, 2008, 10:57:05 AM by gmacted
Quote from: JonnyMac on July 27, 2008, 03:58:04 PM
Think of it like going from an automatic to a stick-shift: it can feel clumsy at first, but once you get the hang of it you have far better control.  The SX does take a little effort, but SX/B really helps.  This document will be helpful to get you going with SX/B:

-- http://www.parallax.com/Portals/0/Downloads/docs/prod/sx/PracticalSXB.pdf

We're getting close to finishing this book and Parallax will release the final version in a couple months or so.

I just started using the prop-sx this past week and I like it!  I started reviewing the "Practical SXB" document above and it was very helpful.  The SX key document was also very helpful and necessary to disect any of the code Jon has posted in this forum.  Hopefully the final version will have some information about interrupts.  This is the true power of the Prop-SX IMHO.  I also think that a background in Assembly language is/would be very helpful.  I have looked at a few programs and it appears to write some tight interrupt routines you need to write them in Assembly.


JonnyMac

July 27, 2008, 08:38:23 PM #21 Last Edit: July 27, 2008, 08:41:27 PM by JonnyMac
Yes, the book has a whole chapter on interrupts and several examples (serial, pwm, servos -- the stuff that is useful for what we do).  SX/B generates pretty tight code, so you really don't have to write your interrupts in assembly, but in some cases you'll save a few cycles and that can be important.  Also, there's a lot of pre-existing assembly code that you can easily drop into an SX/B program.  That's what I've done, with minor tweaks here and there to suit my own needs.

For a good book on assembly get Guether Daubach's, "Programming the SX Microcontroller" -- I keep in near my desk and refer to it often.
Jon McPhalen
EFX-TEK Hollywood Office