Page 1 of 1

Fan and GPIO header related question

Posted: Sat May 25, 2019 8:33 pm
by MineSweGamer
Hi,
Ive been looking if i am able to connect a 40x40x10mm fan for my Pi 3 B+ in my case and the clearance isn't a problem. I was looking at an Noctua NF-A4x10 5V for silent running and it comes with a cable for 2 pin DC running with bare wires in the end. I was planning to connect it to the GPIO as i really don't care about speed control and don't care if it's running 100% all time.

The problem is that i cant seem to find GPIO single pin header connectors for it. Will i be able to Run a 5V Noctua fan from the GPIO and if yes, Where can i find the 1-pin GPIO Headers? I live in Sweden and prefer to order from within the EU to i don't have to struggle with customs.

Thanks in advance.

Re: Fan and GPIO header related question

Posted: Sat May 25, 2019 8:42 pm
by dl324
MineSweGamer wrote:
Sat May 25, 2019 8:33 pm
The problem is that i cant seem to find GPIO single pin header connectors for it. Will i be able to Run a 5V Noctua fan from the GPIO and if yes, Where can i find the 1-pin GPIO Headers? I live in Sweden and prefer to order from within the EU to i don't have to struggle with customs.
Pi GPIOs are 3.3V and they can't sink or source enough current to run a fan.

You'll need to use a GPIO to drive a transistor with the fan as a high side load. A logic level N channel MOSFET with a current rating high enough for your fan would be easiest.

If you want to be able to control the speed, you could use PWM. You could get the CPU temperature and adjust fan speed accordingly.

Re: Fan and GPIO header related question

Posted: Sat May 25, 2019 8:50 pm
by MineSweGamer
dl324 wrote:
Sat May 25, 2019 8:42 pm
MineSweGamer wrote:
Sat May 25, 2019 8:33 pm
The problem is that i cant seem to find GPIO single pin header connectors for it. Will i be able to Run a 5V Noctua fan from the GPIO and if yes, Where can i find the 1-pin GPIO Headers? I live in Sweden and prefer to order from within the EU to i don't have to struggle with customs.
Pi GPIOs are 3.3V and they can't sink or source enough current to run a fan.

You'll need to use a GPIO to drive a transistor with the fan as a high side load. A logic level N channel MOSFET with a current rating high enough for your fan would be easiest.

If you want to be able to control the speed, you could use PWM. You could get the CPU temperature and adjust fan speed accordingly.
You sure? According to the docs, the pi has 5V on Pins 2 and 4 while Pins 1 and 17 are 3.3V. Whats wrong with Pins 2 and 4 for 5V?

Official docs on GPIO https://www.raspberrypi.org/documentation/usage/gpio/

Re: Fan and GPIO header related question

Posted: Sat May 25, 2019 9:18 pm
by Ernst

Re: Fan and GPIO header related question

Posted: Sat May 25, 2019 9:30 pm
by LTolledo
For a fan that size better split the 5v and Gnd from the microUSB cable and use that to power the fan.

Re: Fan and GPIO header related question

Posted: Sat May 25, 2019 9:45 pm
by HawaiianPi
Yes, I use that same fan on a couple of Pi computers I have, including my SSD booted 3B. It works great, even without a heatsink!

Image

I wired a male fan connector to the +5V and Ground on the expansion header, so I could just plug the fan in (other 3 wires are serial GPIO).
Pi_Fan_Serial_GPIO_cable_small.jpg
Pi_Fan_Serial_GPIO_cable_small.jpg (23.13 KiB) Viewed 558 times
MineSweGamer wrote:
Sat May 25, 2019 8:50 pm
You sure? According to the docs, the pi has 5V on Pins 2 and 4 while Pins 1 and 17 are 3.3V. Whats wrong with Pins 2 and 4 for 5V?
Technically, the 5V, 3.3V and ground pins on the expansion header are not GPIO (general purpose input output), since the Pi doesn't read or write data to them. Some people get a bit too pedantic about that.

Re: Fan and GPIO header related question

Posted: Sun May 26, 2019 12:18 am
by dl324
MineSweGamer wrote:
Sat May 25, 2019 8:50 pm
You sure? According to the docs, the pi has 5V on Pins 2 and 4 while Pins 1 and 17 are 3.3V. Whats wrong with Pins 2 and 4 for 5V?

Official docs on GPIO https://www.raspberrypi.org/documentation/usage/gpio/
I measured GPIO4-11 when I was experimenting with register access.

The schematic is crap, but it shows VDDIO2_[12] connected to 3.3V. The first GPIO 2 and 3 have pull up resistors to 3.3V.
pigpio.jpg
pigpio.jpg (46.57 KiB) Viewed 521 times
The document you referenced said GPIO are 3.3V:
gpioVoltage.jpg
gpioVoltage.jpg (18.42 KiB) Viewed 514 times

Re: Fan and GPIO header related question

Posted: Sun May 26, 2019 12:54 am
by PhatFil
you can buy kits of male and female dupont connector kits so you can crimp your own 1,2,3..etc pin male or female cable headers, just search for 'Dupont Kit' and your search engine should give you ebay/amazon etc options..
And youtube should give you lots of hints and tips...

But imho its a lot less time consuming and hassle to buy a few dupont ribbon cables and cut/splice or solder in wires as needed..

I think the key info hinted to above is that the Pi gpio header has 3.3v gpio pins as well as connections to the ground 3.3v and 5v dc power rails. you cant draw more than 12 or 16 ma from a 3.3v gpio pin, But the 5v pin is not as limited.


So your 5v fan can simply be connected to the +5v pin and a ground pin on the gpio header to run at full pelt with power to the pi turned on.

but to have it under gpio control you will need some extra circuitry to limit the 5V supply either by degree or simply on or off.

If quiet and unobtrusive i would probably be happy with it on 100% with pi power ;)