Need Help using Stratux fan controller on PiAware Raspberry Pi 3

Complete newbie here. I’ve managed to re-purpose my Stratux Raspberry Pi 3 into a Piaware feeder outputting both 1090 and 978 traffic using adcd567’s excellent instructions at How to Install and Configure Piaware 5.0 SD card image - Quickstart Guide Note: The Stratux SDRs I used were already serialized saving a step in the process (Serial #s were “stratux:1090” and “stratux:978”)

After running for a while, I started getting warnings about CPU temps from Flightaware which started causing errors with MLAT. I have a fan installed in the case, and I have the Stratux AHRS Sensors and Fan Controller which worked great with the Stratux software. I’ve now realized that some coding is required to turn the fan on and off once CPU temps reach predefined levels, when using it with PiAware. I’m have no/limited knowledge of coding and compiling, but the Stratux developer does provide the coding for controlling the fan here: stratux/fancontrol.go at master · cyoung/stratux · GitHub

Running a fan 24/7 to keep our RP3/Piaware feeders cool, is noisy and wastes energy. Also those little fans just aren’t designed for prolonged 100% usage. The Stratux AHRS Sensors and Fan Controller is available on Amazon for $14.98 and is easily installed on the GPIO pins and then the fan is plugged into it.

Any coding experts out there interested in figuring out how to make this work on a PiAware image/installation?

Thanks,
Gary

1 Like

I bought a miuzei pi case on amazon…has a fan and heatsinks dropped my temps 20 degrees across the board…plug and play…as far as noise its quiet but its in the attic anyways…couldn’t just swap out the case?

I have a similar case with heat sinks and fan. It works great keeping the the CPU cooler when plugged directly into the GPIO pins 4 and 6 which are always on. I’ve tried 3 different fans but all are noisy. When used in any living space in the house it is pretty annoying. So having the fan come on only when needed would be a great benefit. I am going to try a Noctua NF-A4x10 5V, Premium Quiet Fan, 3-Pin, 5V , hoping it will be more quiet. Still a temp controlled on/off function for the PiAware would be a great feature.

The Pi has some hardware PWM support on (some? maybe all?) GPIO pins.

Here’s some starting points:

https://gpiozero.readthedocs.io/en/stable/api_output.html#gpiozero.PWMOutputDevice
https://gpiozero.readthedocs.io/en/stable/api_internal.html#cputemperature

Someone asked about this on the Stratux subreddit the other day.

I wrote a fan speed control script for Stratux that was replaced with some more efficient fan code later on.

The simple python script should work just fine for most peoples needs.

Just need to change the PWM pin from 11 to 12 for use with the Stratux AHRS board.