lynxmotion.net/phpbb/viewtop … 5417#45417
Can’t get the thing to talk to my microcontroller now. Seems similar too. (lights on nobody home)!!
lynxmotion.net/phpbb/viewtop … 5417#45417
Can’t get the thing to talk to my microcontroller now. Seems similar too. (lights on nobody home)!!
Stop linking one page to another. You’re making me dizzy!!! Let’s just try and fix your problem.
Remember that your PC will not allow more than one application to talk to the same serial port at the same time! Close anything using the serial port before you try to open another application to talk to the same serial port.
yep ok all done. Shall we move to the other thread as it’s sort of a new problem?
What microcontroller are you using?
How do you have it connected?
Do you have any programming examples you could show us?
Using a picaxe 8M at the mo but am planning to use an 'axe 40x1
serout of pin2 > Rx on the ssc and ground > ground via each board.
Here is the code:
start:
serout 2,N2400,("#5 P1600 T1000 ",13)
pause 1000
serout 2,N2400,("#5 P2400 T1000 ",13)
pause 5000
goto start:
Interestingly when I run this the indicator LED blinks, one second pause then blinks again, then three seconds pause and blink.
If I change the value of ‘pause 5000’ to 1000 say, the blinking of the LED changes accordingly. Like the problem with the PC connection last week, the ssc seems to be registering commands but not acting on them.
Baud rate set at 2.4k throughout the system. (jumpers are in the correct positions. (none))
Also the power jumpers are in the correct positions as described in the users manual. I’ve tried two and one battery configurations.
Batteries are measuring 8.26v and 5.98v.
Also tried:
let w0 = 1000
let w1 = 1000
let b4 = 5
start:
serout 2,N2400,("#",#b4, " P",#w1, " T",#w0,13)
pause 1000
w1 = 2000
serout 2,N2400,("#",#b4, " P",#w1, " T",#w0,13)
pause 5000
w1 = 1000
goto start
Because you are using the TTL input not the RS-232 level shifter input I would recommend using the inverted mode. That’s how the Atom Pro connects to the SSC-32. Just because the LED is blinking does not mean it’s formatted properly. It will also blink if the wrong baud rate is used. But it’s definitely an indicator that the correct com port is being used.
In this case I believe it’s a pure coincidence that it’s not connecting.
serout 2,I2400,("#5 P1600 T1000 ",13)
Nope. still the same ol’ blinkin LEDs. I’ve just tried (to no avail):
start:
low 2
serout 2,T2400,("#5 P1600 T1000 ",13)
pause 1000
low 2
serout 2,T2400,("#5 P2400 T1000 ",13)
pause 3000
goto start:
For a reality check try, it with LynxTerm just to make sure nothing has changed with the board. I’m at a loss as to what could be going on. I don’t know anything about the controller you are using. Do you have two wires going from the SSC-32 to the other microcontroller? Signal and ground? I see you removed the N and replaced it with an T. Is the T used for inverted serial data?
A)yes
B)yes
C)yes
Did you test it with LynxTerm?
lynxterm working perfectly
Hey Jim my Picaxe forum helper found this warning in the user manual. Not sure if it’s relevant though.
Important! Don’t issue a speed or time command to the servo controller as the first instruction. It will assume it needs to start at 500uS and will zip there as quickly as possible. The first positioning command should be a normal "# P " command. Because the controller doesn’t know where the servo is positioned on power up it has to be this way.
I’m gonna try
SEROUT 2,N2400,("#5 P1600",13)
pause 1000
'only.
'Then:
start:
serout 2,N2400,("#5 P1600 T1000 ",13)
pause 1000
serout 2,N2400,("#5 P2400 T1000 ",13)
pause 3000
goto start:
I’ll let you know
Thanks for that. Your microcontroller’s output… Is it 3.3 or 5vdc? Is it open collector or totem pole output. If it works on LynxTerm then it should work with a microcontroller. And at 2400baud… nothing should have trouble working at this low a baud rate. I’m perplexed…
That’s got nothing to do with it. Trust me…
no luck
It’s 5v and I think open collector but I’m not sure. I’ll run it by picaxe peeps and let you know.
If it’s open collector you will need to add a 10k pullup to the pin.
Zis is vat he say:
“Yah, LOW 2 for N2400 and HIGH 2 for T2400. This sounds like a very cool servo controller for only $35.00. Controls 32 servos with time and speed control. Hope you get it going adzthename”
Make sense? Do I still need the 10k pullup? I’ve got the breadboard out and am working on it as we speak!
Sh***ng **** I almost had a heart attack. It made me jump
IT WORKS !!!