Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   General Forum (http://www.chiefdelphi.com/forums/forumdisplay.php?f=16)
-   -   Limit Switch Tripping (http://www.chiefdelphi.com/forums/showthread.php?t=126519)

lokistormbringe 15-02-2014 17:18

Limit Switch Tripping
 
Our team is currently using a catapult arm driven by two cim motors with a similar configuration to Boom Done's catapult. Currently, we have a wire attached to the large gear at the top to trigger a limit switch that stops the throwing arm. However, the wire keeps bending out of shape. We are looking for something strong enough to trigger the switch but flexible enough to bend around the switch and the frame while returning to the same position. Do you guys have any ideas?

actual pics can be posted later if you need to see the current config.

SenorZ 15-02-2014 17:39

Re: Limit Switch Tripping
 
So, you have a throwing arm rotating at a high speed (?) and stopping once a limit switch gets tripped?
I would recommend trying to program your "launch" command to only power the motor for a set amount of time. I'm not a programmer though so I don't know how to implement that exactly.

Whippet 15-02-2014 19:23

Re: Limit Switch Tripping
 
If you can post what language you're using, I could help you with the programming of the timing operation mentioned above.

Alan Anderson 15-02-2014 21:53

Re: Limit Switch Tripping
 
Instead of metal, maybe you can try a strip of lexan? It'll flex but return to its original shape (unless you overstress it).

MrRoboSteve 16-02-2014 08:45

Re: Limit Switch Tripping
 
We used small strips of plastic taken from a plastic bottle (I think it was a liquid Tide container) to do something similar last year.

MrForbes 16-02-2014 08:55

Re: Limit Switch Tripping
 
Quote:

Originally Posted by lokistormbringe (Post 1343585)
actual pics can be posted later if you need to see the current config.

Yes, we need to see what you're talking about. Pictures are always very helpful.

See if you can make it so that the switch will be triggered as the arm approaches the end of it's travel, not when it reaches it. And so that the switch is activated as the thing touching it goes by, not as it runs into it. Hard to explain, but make it so that it works sort of like a cam, pushing the switch from the side, not directly in it's face.

We've had lots of trouble with limit switches in applications like this...so this year we have pneumatics doing all of the arm moving stuff, and the only motors on the robot turn stuff that can keep spinning as long as it wants to

lokistormbringe 16-02-2014 21:17

Re: Limit Switch Tripping
 
Quote:

Originally Posted by Whippet (Post 1343652)
If you can post what language you're using, I could help you with the programming of the timing operation mentioned above.

We are using java. The current code runs the throwing arm at full until the top switch is hit and them slowly reverses it back into place. It stops when a second limit switch is hit at the bottom

Whippet 16-02-2014 21:37

Re: Limit Switch Tripping
 
Quote:

Originally Posted by lokistormbringe (Post 1344215)
We are using java. The current code runs the throwing arm at full until the top switch is hit and them slowly reverses it back into place

Alright. I'm not too good with Java, but I think the pseudocode for such an operation would look something like this:

Code:

if(stick.getRawButton(Trigger) == true){
arm.setSpeed(speed);
timer.Delay(time);
arm.setSpeed(0);
}
else {
arm.setSpeed(0);
}

where the variable Time is equal to how long your arm needs to be run, Speed is the power you are applying to your arm, and Trigger is the appropriate button on your joystick. Sorry if this is incorrect, I use LabVIEW and just started learning Java this weekend, but I *think* with some tweaking, this should be what you want.

EDIT: This is for a strictly timing-based solution like SenorZ suggested. I am as yet unsure of how to get the values from limit switches.

tStano 16-02-2014 23:01

Re: Limit Switch Tripping
 
A limit switch is a DigitalInput, and its 'get()' may return true or false when pressed depending upon the switch.

It sounds as if you have the code figured out to me. It sounds like you are looking for the mechanical solution to hitting the switch; of which I have none.
But if you need help with code; feel free to PM me and we can work it out some more.

om_nom_nom 17-02-2014 01:25

Re: Limit Switch Tripping
 
Like other people have said, you'll want to trip the limit switch as it passes right before the endpoint, but not at the end point. Momentum should carry it over a bit if you have your motor controllers set to coast, and you can set a timer of some sort to count before it goes backwards. As for what material to use to trip it, try a decently thick zip tie/ wire tie.

Code-wise, it could look something like this in a CommandGroup:
Code:

addSequential(new MoveArmForwardUntilLimit());
addSequential(new WaitCommand(0.5));
addSequential(new MoveArmBackwardsUntilLimit());


lokistormbringe 17-02-2014 19:38

Re: Limit Switch Tripping
 
Thanks for the coding help. To trip the switch we are going to go with the plastic idea. We cut apart the bottom of a plastic bin and its tripping the switches just fine.

Thanks guys!


All times are GMT -5. The time now is 05:39.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi