View unanswered posts | View active topics It is currently Fri Aug 01, 2014 7:04 pm






Reply to topic  [ 4 posts ] 
Claw, Cortex program help 
Author Message
Rookie

Joined: Tue May 10, 2011 5:37 pm
Posts: 5
Post Claw, Cortex program help
I have a simple code but sometimes in operation the clawMotor will stop running and i have to move it by hand to reset it. think it is in the programing but i'm still new to VEX so a code error is not out of the question. I have a robot arm that picks up parts by using the joystick buttons. But5D and But5U, as well as But6U and But6D. The five button controls slower and fine tuned claw control, and 6 is a stronger more powerful close on the part so it does not slip out. The coding is...


#pragma config(Motor, port3, clawMotor, tmotorNormal, openLoop)
//*!!Code automatically generated by 'ROBOTC' configuration wizard !!*//

task main()
{
while (1 == 1)
{
if(vexRT[Btn6D] == 1)
motor[clawMotor] = 80;
else if(vexRT[Btn6U] == 1) // this part is the fast opening and is mostly unused.
motor[clawMotor] = -80;

else if(vexRT[Btn5D] == 1)
motor[clawMotor] = 40;
else if(vexRT[Btn5U] == 1)
motor[clawMotor] = -40;
else
motor[clawMotor] = 0;
}
}


Tue May 10, 2011 5:56 pm
Profile
Rookie

Joined: Tue May 10, 2011 5:37 pm
Posts: 5
Post Re: Claw, Cortex program help
when the arm is fully extended the claw will not extend. it is a two pivot arm and the power seam high. i am testing right now to find the bug


Tue May 10, 2011 8:11 pm
Profile
Site Admin
Site Admin

Joined: Mon Jun 08, 2009 4:50 pm
Posts: 70
Post Re: Claw, Cortex program help
Hi Sirup96,

I downloaded your code and it works fine for me. I played around with it and still everything was working fine. Perhaps your mechanism has some kind of physical stop or is getting too tight or difficult for the motor to move it? The code seems to work fine...

Sorry that I couldn't be of more help,

_________________
Bence Feher

Undergraduate Intern - NREC, Robotics Academy
ROBOTC - Testing/Documentation/Developer

Computer Science, Japanese, East Asian Studies
University of Pittsburgh, Konan University 甲南大学


Thu May 12, 2011 11:56 am
Profile
Rookie

Joined: Tue May 10, 2011 5:37 pm
Posts: 5
Post Re: Claw, Cortex program help
Hey thanks for the try man. i was only able to cause the problem when the arm is fully extended so i'm looking into a power levels. i got the 1.6 Amp 7.2v battery hocked to the cortex. If i could i would hook more power to it and see it i would change. Your the only feedback i got and with robotics event happening soon i don't think i can order a bigger battery in time. Would any one know if hocking four motors under pressers of weight of around 2kg or 4.4 Lbs draws the peck off the battery listed above. I'm right now looking into gear box system but i have done it to big before that i actually broken a gear inside of if for the claw. Near as i can tell the problem is physical or a battery power, or the program witch i have not found a problem yet.


Thu May 12, 2011 8:08 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 4 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.