Lynxmotion Tech Support

www.lynxmotion.com
It is currently Mon May 20, 2013 3:46 am

All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 12 posts ] 
Author Message
 Post subject: Jerky servo movements?
PostPosted: Tue May 08, 2012 12:36 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
I'm obviously doing something wrong here, but after a few days of trying to figure it out myself, I think I need help. 8)
I'm most likely going about it all wrong, and better ideas are welcome. End desired result is to control servos over a LAN with a local potentiometers (Using a USB Netshare Station to control the SSC-32 over the LAN). This is all part of a home security system I'm setting up for myself, in case anyone was curious. :D

Lemme start with the setup:

I've got a pot wired into an Arduino which is sending its value into Roborealm.
I take the value and run it through a VBScript to get a value I can control the servo with:
Code:
pot1 = GetVariable("pot1")
servo1 = GetVariable("servo1")

servo1 = (pot1 + 250) * 2

SetVariable "servo1", servo1
SetVariable "pot1", pot1

The servo1 variable (which is now 500-2500) is assigned to the servo in the SSC-32 module in Roborealm.

I can use the sliders on the SSC-32 module to control the servo directly with no problems. I can move the pot and the servo follows suit. But when the pot is turned at a steady rate the servo will jerk to a spot, pause, then jerk to the next spot until it reaches its destination. This has me thinking its the VBScript, but the values its reporting to the SSC-32 seem constant and stable.

I've tried:
Slowing down/increasing the rate of the servos in the SSC-32 module.
Using isolated power for the VS and VL on the SSC-32.
Using different servos.
Using another Arduino instead of the SSC-32 to control the servo (still does it)
Sprinkling magic pixie dust onto it.

All which leads me to think I'm just sending the signal to the control board wrong somehow.
I'm rather new to almost all of this as I'm sure you can tell, so please go easy on me if I'm doing something terribly stupid. :lol:
Any help or advice would be much appreciated!


Top
 Profile  
 
PostPosted: Tue May 08, 2012 4:22 pm 
Offline
Lynxmotion Founder
User avatar

Joined: Mon Oct 31, 2005 10:46 am
Posts: 9325
Location: my quiet place
What you are describing may be a delay in the throughput of your system. I feel bad replying with so little info when you typed up so much. :P The trick is to find out where...

_________________
Jim Frye, the Robot Guy
http://www.lynxmotion.com
I've always tried to do my best...


Top
 Profile  
 
PostPosted: Tue May 08, 2012 5:31 pm 
Offline
Robot Guru
User avatar

Joined: Fri May 25, 2007 8:21 pm
Posts: 3868
Location: Central Coast, CA, USA
I don't fully know your setup, but if you have an Arduino with a pot, and an SSC-32, why not have the Arduino talk directly to the SSC-32, and also copy info back to the PC running VB? that would take out some of the delay...

Alan KM6VV

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


Top
 Profile  
 
PostPosted: Tue May 08, 2012 11:09 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
Jim:

Could the delay be from the way I have it set up? That maybe I'm going the long/wrong way about doing it?
I figured its pretty much the same setup as running a joystick. Which I just tested. A joystick feeding data to Roborealm has no problems, and everything is smooth. I'd just use the joystick but I actually need more analog inputs than a joystick would offer (only five on the 360 one I was testing), hence my idea on using an Arduino Mega (with its 16 analog inputs).

Maybe if I used the Arduino as a joystick instead of using the Arduino Roborealm Module, it'll eliminate the delay? Because all a joystick is is an I/O board right? Lot's of examples of the Arduino being used as one out there.
Now I'm talking to myself and asking rhetorical questions, it must be late. :lol:

Don't worry about the short reply, everything helps. Your reply actually got me thinking about the joystick thing! Plus typing it all out helps me rethink if I've missed anything. :D

Also, if you don't mind my highjacking my own thread partly; my trial of Roborealm is up next week and I was wondering if when I bought a copy from you guys if it was a download or a disc? If it's a disc I need to come up with a bigger order so I don't waste those shipping costs. :mrgreen:


Alan:

I couldn't figure out a way link the two boards over a LAN without a computer to handle the serial connections. The Arduino will be located in a different building from the SSC-32, which is why I need the control over a network. Which I'm currently using a USB Net Share Station for. Just like the RouterBot James made a few years ago:
http://www.lynxmotion.net/viewtopic.php?f=9&t=6871&p=67698&hilit=usb+netshare#p67698
Yeah, I've been creeping for a long time. :oops:

If it's possible to somehow control the SSC-32 with the Arduino directly via an eithernet shield or something I'd need a shove in the right direction to figure it out, as it would actually be a preferable method. I'm only using Roborealm because I was already testing it for a different part of the project (the video monitoring and DVR parts of the security setup) and wanted to see if I could do them both in the same program.


Sorry for making you guys read so much, I'll try keeping it shorter next time. :oops:


Top
 Profile  
 
PostPosted: Wed May 09, 2012 9:26 am 
Offline
Snails in tiny top hats
User avatar

Joined: Mon Oct 31, 2005 10:43 am
Posts: 831
Location: Illinois
nonnef wrote:
Also, if you don't mind my highjacking my own thread partly; my trial of Roborealm is up next week and I was wondering if when I bought a copy from you guys if it was a download or a disc? If it's a disc I need to come up with a bigger order so I don't waste those shipping costs. :mrgreen:

Roborealm is a physical CD, not a download - I've edited the product description to clearly indicate this, sorry for the confusion!

_________________
Image Beth
Lynxmotion, Inc
http://www.lynxmotion.com

THANKS I COULD HELP BRO


Top
 Profile  
 
PostPosted: Wed May 09, 2012 12:41 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
Snailkeeper (Admin) wrote:
nonnef wrote:
Also, if you don't mind my highjacking my own thread partly; my trial of Roborealm is up next week and I was wondering if when I bought a copy from you guys if it was a download or a disc? If it's a disc I need to come up with a bigger order so I don't waste those shipping costs. :mrgreen:

Roborealm is a physical CD, not a download - I've edited the product description to clearly indicate this, sorry for the confusion!



Thanks Beth. :)


Top
 Profile  
 
PostPosted: Wed May 09, 2012 1:35 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
Steven over at Roborealm pointed this out:

"Have you tried graphing the port1 variable using the Chart_Variable to see if that input also has noise on it? This is most likely the cause since AD conversion has a lot of sensitivity and can have a good deal of noise."

It was just noise in the pot. Problem solved!


Top
 Profile  
 
PostPosted: Wed May 09, 2012 1:47 pm 
Offline
Lynxmotion Founder
User avatar

Joined: Mon Oct 31, 2005 10:46 am
Posts: 9325
Location: my quiet place
Yeah, that'd be a tough one to solve without that little bit of info. ;) Glad you got it going!

_________________
Jim Frye, the Robot Guy
http://www.lynxmotion.com
I've always tried to do my best...


Top
 Profile  
 
PostPosted: Wed May 09, 2012 4:47 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
Robot Dude wrote:
Yeah, that'd be a tough one to solve without that little bit of info. ;) Glad you got it going!


Always seems to be the simple things I overlook. :wink:


Top
 Profile  
 
PostPosted: Thu May 10, 2012 12:05 pm 
Offline
Robot Guru
User avatar

Joined: Fri May 25, 2007 8:21 pm
Posts: 3868
Location: Central Coast, CA, USA
There is, although I have not done it for the Arduino and Ethernet card (shield). Seems you can Telnet commands. I did do that with my Foscam Internet camera (WiFi), so I know it can be done, although I can't find my notes now!

Here's a link to Arduino code to serve as a server and take commands to read/write pins etc.

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1278686415

Alan KM6VV

nonnef wrote:
Alan:

I couldn't figure out a way link the two boards over a LAN without a computer to handle the serial connections. The Arduino will be located in a different building from the SSC-32, which is why I need the control over a network. Which I'm currently using a USB Net Share Station for. Just like the RouterBot James made a few years ago:
http://www.lynxmotion.net/viewtopic.php?f=9&t=6871&p=67698&hilit=usb+netshare#p67698
Yeah, I've been creeping for a long time. :oops:

If it's possible to somehow control the SSC-32 with the Arduino directly via an eithernet shield or something I'd need a shove in the right direction to figure it out, as it would actually be a preferable method. I'm only using Roborealm because I was already testing it for a different part of the project (the video monitoring and DVR parts of the security setup) and wanted to see if I could do them both in the same program.

_________________
Visit:
http://groups.yahoo.com/group/SherlineCNC/
http://tech.groups.yahoo.com/group/HexapodRobotIK/


Top
 Profile  
 
PostPosted: Sun May 13, 2012 3:49 pm 
Offline
Roboteer

Joined: Mon Oct 17, 2011 9:35 pm
Posts: 11
Thanks for the info. 8)

KM6VV wrote:
There is, although I have not done it for the Arduino and Ethernet card (shield). Seems you can Telnet commands. I did do that with my Foscam Internet camera (WiFi), so I know it can be done, although I can't find my notes now!

Here's a link to Arduino code to serve as a server and take commands to read/write pins etc.

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1278686415

Alan KM6VV

nonnef wrote:
Alan:

I couldn't figure out a way link the two boards over a LAN without a computer to handle the serial connections. The Arduino will be located in a different building from the SSC-32, which is why I need the control over a network. Which I'm currently using a USB Net Share Station for. Just like the RouterBot James made a few years ago:
http://www.lynxmotion.net/viewtopic.php?f=9&t=6871&p=67698&hilit=usb+netshare#p67698
Yeah, I've been creeping for a long time. :oops:

If it's possible to somehow control the SSC-32 with the Arduino directly via an eithernet shield or something I'd need a shove in the right direction to figure it out, as it would actually be a preferable method. I'm only using Roborealm because I was already testing it for a different part of the project (the video monitoring and DVR parts of the security setup) and wanted to see if I could do them both in the same program.


Top
 Profile  
 
PostPosted: Thu May 17, 2012 1:09 pm 
Offline
Robot Guru

Joined: Thu Jul 13, 2006 10:10 pm
Posts: 2225
I did some tinkering below with a web controlled ssc-32 via an arduino and ethernet shield. If you want quick joystick type control over a lan then a telnet type connection would probably be needed. Check the "chat" examples in the arduino IDE for the basic connection setup.

viewtopic.php?f=20&t=6343

_________________
Why I like my 2005 rio yellow Honda S2000 with the top down, and more!
http://youtube.com/watch?v=pWjMvrkUqX0
http://youtube.com/watch?v=qfyRA-g1nhI
http://web.comporium.net/~shb/S2000video.htm


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group