
Turkishmoose
Hi all, this is my first ever post and first robot. Hoping to get some help as I am brand new to the EZ-B board and the way it works.
I built this little rover, using servos and some handiwork. The attached 'missile launcher' is actually a modified USB toy. I removed the motors for horizontal, vertical movement, and replaced with servos and it works great...
QUESTION: The launcher has a third motor, which I left in, and it controls the launch. If I hook it up to a 5V power, it launches the nerf. Great! But here's my problem: I want to control it. If I hook it up to a digital port, on the GND and 5V, it just keeps running. I want it to only run when I press the button on the laptop. If I hook it up to the EXT and GND, it doesn't run at all - even when I turn the PWM up all the way to 100 on the ARC.
I tried building a Transistor Switch, using an NPN transistor - I guess the EXT doesn't have enough juice to keep the transistor gate open?
I'm completely stuck - basically I need to have a switch on the EZ-B, that will provide a 5V current through the motor, when I click a button on the laptop (the joystick to be exact).
Can someone help?
P.S. Excited to have joined the community!
The 5V on the EZ-B is always hot, always 5V, so connecting anything between 5V and Ground will constantly run. What you need to do is use a TIP switching circuit .
The current for the signal is not going to be enough to drive more than just an LED so a motor is out of the question. Depending on the load of the motor the 5V may be enough (assuming so as you said it runs), otherwise you will need to run an external supply to the motor rather than the 5V as in the tutorial.
Edit: If it's not clear in the tutorial, you use a Set Digital control to activate the circuit, like a switch. For scripts or joystick control use the Set(Digital Port, On/Off) command i.e. Set(D0,on)
Further edit: If you only need it to run for a second or so to fire you can use a script like;
That tutorial looks like it's what I need - thanks!