Dannyb648
Posts: 9
Joined: Wed Feb 26, 2014 11:28 am

Controlling 9v NERF gun from a Pi

Fri Mar 07, 2014 2:32 pm

Hey guys,

I'm working on mounting a nerf gun onto a rc car and controlling everything from a Raspberry Pi. I've got all of the actual circuits sorted, so when I complete them, they go (gun fires, car drives).

I need to be able to use the r pi to simply switch on and off each circuit. I want to have it so when I power a gpio pin, it completes the nerf guns circuit and it fires, and the same for all of the car motors.

I have no idea where to start in actually doing this. The nerf gun and the cars motors all run off of 9v.

Is this possible, and if so how? If not is there another board I could use?

User avatar
joan
Posts: 14937
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Controlling 9v NERF gun from a Pi

Fri Mar 07, 2014 2:53 pm

I know just enough to know that it is doable.

The Pi's gpios are 3V3 so you will need buffer circuitry between the Pi and your circuits.

How are your circuits triggered, i.e. what completes the circuit?

Angelus88
Posts: 442
Joined: Mon May 13, 2013 9:25 am
Location: Ivrea, TO (Italy)

Re: Controlling 9v NERF gun from a Pi

Fri Mar 07, 2014 2:59 pm

You could use a simple relay board. If you need to open and close each circuit, you just have to wire each circuit to a relay that you can control with the RPi through the GPIO pins.

When the realy is switched on, the circuit is closed and so power goes through and it fires! :D

Take a look here

Dannyb648
Posts: 9
Joined: Wed Feb 26, 2014 11:28 am

Re: Controlling 9v NERF gun from a Pi

Fri Mar 07, 2014 3:16 pm

Well I've simply got a nerf gun and a rc car and worked backwards, the circuit can be however I want it to be.

I looked through at page you linked, what sort of relay would I be needing, would any do? Will I need a relay for each thing I wan to control (4 motors and a fifth for the gun?)

Angelus88
Posts: 442
Joined: Mon May 13, 2013 9:25 am
Location: Ivrea, TO (Italy)

Re: Controlling 9v NERF gun from a Pi

Fri Mar 07, 2014 3:20 pm

That relay can handle 10A (250V AC or 30V DC) so it's way enough to handle just 9v.

And yes... I think you need a relay for each circuit to open and close.

You could choose a board with 8 relays and use just 5 of them or you could use 2 boards: one with 4 relays and the other one with just one relay

Return to “Beginners”