
PRO
RoboHappy
USA
Asked
— Edited
I'm perplexed....:) is there a simple script command that can stop a servos movement when the servo starts moving?
I am trying to use a lever switch within a gripper. When I tell the gripper to begin closing around an object, and then the object presses against the lever switch,the gripper servo could immediately stop.
I've looked thru the EZ script manual, just cant the right command or function. Any ideas? Thanks in advance.
setservo(d8,90)
stop()
ecample servo wil stop at 90 degree
Code:
In order to use a lever switch you will need to read it on another digital port... It will need a pull up resistor.... Once the switch is triggered the pin will go high (or low, depending on how you wired it).... You can read this and then use the command release to kill the servo movement....
It's a good read that will give you insight on how a robot works. When you opened the JD box, loaded the software, and followed the instructions, there are warnings not to exceed servo limits. If you do, a servo will be damaged.
If you'd like your robot to hold stuff. Add foam pieces to it. Here, i'll show you what i have done..
I should also add that I got the soft foam from the newer ezrobot robot box. The newer boxes have a soft foam compared to the old hard foam. I had the foam changed once I found out how bad dense foam is for the environment. Soft foam is much better for the environment, but still not great... But better! And it makes good gripper holders.
I am still reading and searching some stuff. This idea steamed from a recent book
about building a Arlo robot from John Blankenship.
Yes I am using a lever switch connected as an input, which ezb reads it just fine. I do want to mount into the gripper,and have the object press the switch and cause the
grippers moving servo stop all together as to not break the servo or the gripper. I would also be using some foam rubber to help with the grip. I do know servos dont have feedback, and I use all kinds of servos in all my Rc model airplanes for years.
I like the "release" command idea, but will that stop the servos motion or actually cause the servo to be inactive?
Im using the ezb gripper for this design, and later I may plan on changing over to Vex hardware for the arms.
The servos to do not "stop" while closing. You will need to send each position, reading the switch on sending each position.
Code:
Code:
im the process of mounting the whole arm assembly to the bot. Would like to upload a pic of it whe I get the chance too.