View unanswered posts | View active topics It is currently Wed Oct 01, 2014 4:16 am






Reply to topic  [ 9 posts ] 
Servos Won't Move 
Author Message
Rookie

Joined: Thu Oct 02, 2008 12:35 pm
Posts: 12
Post Servos Won't Move
Hey I am having trouble with my servos, and they won't move at all, no matter what I do. At first, it was just nothing would move, but now I'm getting these messages:
On the NXT Screen:
PgmCnt: 000036
Type: 34

and from RobotC:


Attachments:
Error Report.JPG
Error Report.JPG [ 18.61 KiB | Viewed 2652 times ]

_________________
Gracious Professionalism. Their standard, our standard.
Thu Nov 20, 2008 1:32 pm
Profile
Site Admin
Site Admin

Joined: Wed Jan 24, 2007 10:42 am
Posts: 604
Post Re: Servos Won't Move
That box tells me it's a programming issue...

So.... I need some code to help!

_________________
Timothy Friez
ROBOTC Developer - SW Engineer
tfriez@robotc.net


Thu Nov 20, 2008 2:11 pm
Profile
Rookie

Joined: Thu Oct 02, 2008 12:35 pm
Posts: 12
Post Re: Servos Won't Move
This is our Code, its really simple, I've been trying to just get the servos to move, but it wont at all, so this is what I made as a test.

Code:
#pragma config(Hubs,  S1, HTMotor,  HTMotor,  HTServo,  none)
#pragma config(Motor,  mtr_S1_C1_1,     ,              tmotorNone, openLoop)
#pragma config(Motor,  mtr_S1_C1_2,     ,              tmotorNone, openLoop)
#pragma config(Motor,  mtr_S1_C2_1,     ,              tmotorNone, openLoop)
#pragma config(Motor,  mtr_S1_C2_2,     ,              tmotorNone, openLoop)
#pragma config(Servo,  srvo_S1_C3_1,    serv1,                tServoNormal)
//*!!Code automatically generated by 'ROBOTC' configuration wizard               !!*//

task main()
{
  servo[servo1] = 100;
  wait10Msec(300);
}

_________________
Gracious Professionalism. Their standard, our standard.


Fri Nov 21, 2008 12:06 pm
Profile
Professor

Joined: Fri Sep 19, 2008 1:22 am
Posts: 200
Post Re: Servos Won't Move
What version of RobotC are you running. Look at the version number on the splash screen when you start it up. The current version is 1.46.

_________________
Jeff McBride
Benson Robotics Club


Fri Nov 21, 2008 3:46 pm
Profile
Rookie

Joined: Sat Nov 22, 2008 7:14 pm
Posts: 12
Location: NJ
Post Re: Servos Won't Move
You have declared servo1 as serv1 so you need:
Code:
servo[serv1] = 100;


Not:
Code:
servo[servo1] = 100;

_________________
Ethan Spitz
Team 464 Programmer


Sat Nov 22, 2008 7:24 pm
Profile
Novice

Joined: Thu Oct 09, 2008 7:58 pm
Posts: 79
Post Re: Servos Won't Move
I don't know if you're doing this in your real FTC code, but remember to include a forever loop.


Sat Nov 22, 2008 8:40 pm
Profile
Site Admin
Site Admin

Joined: Wed Jan 24, 2007 10:42 am
Posts: 604
Post Re: Servos Won't Move
Sounds like you're not using version 1.46... What version are you using?

Edit: Tested on 1.46, looks like it's the name of the servo:

Code:
task main()
{
  servo[serv1] = 100;
  wait10Msec(300);
}


That code works, but saying servo1 instead of 'serv1' causes the error.

_________________
Timothy Friez
ROBOTC Developer - SW Engineer
tfriez@robotc.net


Mon Nov 24, 2008 12:34 pm
Profile
Rookie

Joined: Thu Oct 02, 2008 12:35 pm
Posts: 12
Post Re: Servos Won't Move
Ethan Spitz wrote:
You have declared servo1 as serv1 so you need:
Code:
servo[serv1] = 100;


Not:
Code:
servo[servo1] = 100;


Yes I know this, and I have tried it as you have listed, and it still functions exactly the same. :breakcomputer:

_________________
Gracious Professionalism. Their standard, our standard.


Mon Nov 24, 2008 12:44 pm
Profile
Rookie

Joined: Thu Oct 02, 2008 12:35 pm
Posts: 12
Post Re: Servos Won't Move
Well, just figured out what the problem was: I messed up the motor and servo controller setup, and accidentally put an extra motor controller if front of my servo controller in the code, which was unlike our robot. I figured it was some kind of logic error, and that was completely the case.

_________________
Gracious Professionalism. Their standard, our standard.


Tue Nov 25, 2008 11:33 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 9 posts ] 

Who is online

Users browsing this forum: No registered users and 2 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 © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.