RPM & RGB Mod for 52pi Ice Tower Heatsink for Raspberry Pi 4

52pi ICE Tower makes your Raspberry Pi 4 look like a beast but lacks fan and LEDs controls. I fixed that!

The coolest heatsink for Raspberry Pi 4

Improving the design of the 52pi ICE Tower Heatsink

Some time ago I reviewed the ICE Cooling Tower from 52pi – an impressive heatsink with a 40mm fan. You can read more about cooling performance on a Raspberry Pi 4 in that article. There were two glaring issues with it: lack of RPM controls and no controls over RGB LEDs in the fan. I guess, this post fixes that. I think I just made the coolest heatsink for Raspberry Pi 4.

If you like the heatsink you can buy it from the following shops: SeeedStudio,AliExpress,Banggood,AmazonUK,AmazonUS

Modding ICE Cooling Tower

This mod should take you about 30 min, providing you have the components needed. The shopping list is extremely short and inexpensive.

With these components, a couple of cables, some glue, heat-shrink and some patience you will be able to control RPMs of the 40mm fan and add RGB effects to your ICE Cooling Tower.

To start, I have to open up the 40 mm fan and remove the existing LEDs. To open up the fan, press down firmly on the centre axis and the bearing. Both should slide out from its case, exposing the motor coils and the PCB. The PCB comes with 4 LEDs that are surface mounted. These are seriously small, so all it takes to get it off from the PCB is some heat from the soldering iron. Just heat up one side and wiggle the iron a little – the LED should come off without issues. I used 375ºC to achieve this.

Now your ICE Cooling Tower is ready to become the coolest heatsink for Raspberry Pi 4.


The easiest (but there are more sophisticated ways) of controlling a DC motor is to use a PWM signal to limit the RPMs of the motor. Since the ICE Cooling Tower fan comes with no such controls I can use 2N2222 series transistor to control the fan’s speed.

The base of the transistor needs a 1KΩ Resistor to limit the current from the GPIO. Use heat-shrink to separate each pin and prevent accidental shorts.

You should have 3 wires now: signal, 5V and GND. You can glue the transistor to the bottom of the fan. It’s time to add some colour to my project.


I salvaged one of the RGB LED strips from a previous project. I only needed 3 individually addressable WS2812b LEDs. To make the diodes fit, I sheered some of the strip off. Then I used a thin wire to connect all of them, creating a 3 LED long strip.

You can use some glue to keep the LEDs in place. This is how the finished fan mod should look like.

Custom driver in NodeRED

At this point, you could write a driver in Python, but since I already have NodeRED running, I took upon the challenge of creating an interactive driver for the coolest heatsink for Raspberry Pi 4. It’s actually easier than I thought it would be.

I’m going to use 3 nodes to monitor Raspberry’s CPU, control GPIO and the WS2812b LEDs:

node-red-contrib-cpu   node-red-node-pi-gpio  node-red-node-pi-neopixel

The neopixel node relies on a Python driver, so I also had to install:

curl -sS get.pimoroni.com/unicornhat | bash

I have 4 wires to connect:

  • 5V-Power Supply
  • GND-Ground
  • GPIO23 (or any PWM pin)-2N2222’s base pin

Neopixel library leaves me no options, so I have to use GPIO18, but to control the RPMs of the 40 mm fan I can pick any PWM enabled pin.

NodeRED Flow

Injecting a payload every 5sec to the CPU node provides me with the core’s temperature. Based on this value I can create the brackets for colours of the RGB and adjust the fan RPMs.

I’m going to use NodeRED 1.0 environmental settings in subflow to create a config node which lets me set the values that flow will use. For RPMs, the value is 0-100 and for RGB I need to pass the number of LEDs (3) and the colour (this list).


Colour names are assigned in the setting subflow. I picked 7 colours representing the temperature levels. The hotter the core gets, the warmer the colour. Neopixel node just needs the number of pixel in the string.


RPMs are set based on the % value 0-100. My fan struggles to spin on PWM set lower than 30%. My setup keeps the fan off until the CPU core reaches 40ºC. It ramps up to 30% then 50% and 100% if the temperature crosses 60ºC. The GPIO node is set in PWM mode at a frequency of 30Hz.

For some reason, I can actually hear the motor whine at lower RPMs. It’s not loud but it’s there. The sound goes away when the fan spins at 100%.


This is no doubt the coolest heatsink for Raspberry Pi 4. With this simple mod, you can add life to your project. Nothing stops you from displaying different things using the LEDs. For the majority of the time, ICE Cooling Tower keeps the Raspberry Pi 4 under 40C, so it’s silent. The fan kicks in when it has to. What do you think about this project?

If you want to get the latest updates to this project you can follow me via your preferred social media:

And if you feeling like buying me a coffee or supporting me in a more continuous way:

I hope you have enjoyed the project!



[{"id":"64a96b1a.8e3d34","type":"subflow","name":"Fan Settngs","info":"","category":"","in":[{"x":100,"y":80,"wires":[{"id":"dfcb82df.24c84"}]}],"out":[{"x":440,"y":80,"wires":[{"id":"dfcb82df.24c84","port":0}]}],"env":[{"name":"colour1","type":"str","value":""},{"name":"colour2","type":"str","value":""},{"name":"colour3","type":"str","value":""},{"name":"colour4","type":"str","value":""},{"name":"colour5","type":"str","value":""},{"name":"colour6","type":"str","value":""},{"name":"colour7","type":"str","value":""},{"name":"speed1","type":"num","value":"30"},{"name":"speed2","type":"num","value":"50"},{"name":"speed3","type":"num","value":"100"}],"color":"#87A980","icon":"node-red/cog.svg"},{"id":"dfcb82df.24c84","type":"function","z":"64a96b1a.8e3d34","name":"Set Colours","func":"//color\nvar colour1 = env.get(\"colour1\");\nvar colour2 = env.get(\"colour2\");\nvar colour3 = env.get(\"colour3\");\nvar colour4 = env.get(\"colour4\");\nvar colour5 = env.get(\"colour5\");\nvar colour6 = env.get(\"colour6\");\nvar colour7 = env.get(\"colour7\");\n\nflow.set(\"$parent.colour1\", colour1);\nflow.set(\"$parent.colour2\", colour2);\nflow.set(\"$parent.colour3\", colour3);\nflow.set(\"$parent.colour4\", colour4);\nflow.set(\"$parent.colour5\", colour5);\nflow.set(\"$parent.colour6\", colour6);\nflow.set(\"$parent.colour7\", colour7);\n\n//fan RPM\nvar speed1 = env.get(\"speed1\");\nvar speed2 = env.get(\"speed2\");\nvar speed3 = env.get(\"speed3\");\n\nflow.set(\"$parent.speed1\", speed1);\nflow.set(\"$parent.speed2\", speed2);\nflow.set(\"$parent.speed3\", speed3);\n\n\nmsg.payload = \"Your colours are set\";\n\nreturn msg;","outputs":1,"noerr":0,"x":270,"y":80,"wires":[[]]},{"id":"3accd94a.e28186","type":"tab","label":"ICE Cooling Tower Mod (RGB RPM)","disabled":false,"info":"\n![enter image description here](https://notenoughtech.com/wp-content/uploads/2019/11/maxresdefault-10-1024x576.jpg)\n\nICE Tower from 52pi is a beast but lacks RPM controls and RGB LEDs cannot be controlled.  I thought I would fix that and add RPM controls and link the LED colours to CPU temperature\n\n\n - [Complete instruction](https://notenoughtech.com/featured/the-coolest-heatsink-for-raspberry-pi-4/)\n\n\n**Features**:\n\n-   RPM control via PWM\n-   3 WS2818b RGB LEDs (programmable)\n-   Custom Fan Profile\n-   Temperature to Colour script\n\nYou will need the following nodes:\n\n - node-red-contrib-cpu\n - node-red-node-pi-gpio\n - node-red-node-pi-neopixel\n\n\n## Get your 52pi ICE Tower:\n\n - [Seed Studio](http://bit.ly/2WPeKos)\n - [Aliexpress](http://s.click.aliexpress.com/e/nZqXAo5K)\n - [Banggood](https://www.banggood.com/custlink/v3DD0AKY4u)\n - [Gearbest](https://www.gearbest.com/smart-home-controls/pp_1829203.html?wid=1433363&lkid=20102743)\n - [AmazonUK](https://amzn.to/36Ehiu4)\n - [AmazonUS](https://amzn.to/2JV8lTo) \n\n\n\n# Settings\n\n - **Colout1-7** HTML names of colours for each temp range\n - **speed1-3** PWM value in % for fan RPM"},{"id":"5adaa9a0.2d57b8","type":"rpi-gpio out","z":"3accd94a.e28186","name":"Fan RPM (GPIO23)","pin":"16","set":"","level":"0","freq":"30","out":"pwm","x":770,"y":180,"wires":[]},{"id":"ad7cbc04.408c4","type":"rpi-neopixels","z":"3accd94a.e28186","name":"Fan RGB LED (GPIO18)","pixels":"3","bgnd":"red","fgnd":"","wipe":"300","mode":"pcent","rgb":"rgb","brightness":"100","gamma":true,"x":790,"y":260,"wires":[]},{"id":"d32a1139.1fd92","type":"cpu","z":"3accd94a.e28186","name":"","msgCore":false,"msgOverall":false,"msgArray":false,"msgTemp":true,"x":330,"y":220,"wires":[["5ee033f9.e7920c","7c7bae90.a2f0b"]]},{"id":"49a3016a.a7c4b","type":"inject","z":"3accd94a.e28186","name":"","topic":"","payload":"","payloadType":"date","repeat":"5","crontab":"","once":false,"onceDelay":0.1,"x":130,"y":220,"wires":[["d32a1139.1fd92"]]},{"id":"5ee033f9.e7920c","type":"function","z":"3accd94a.e28186","name":"Fan Colour Profile","func":"var colour1 = flow.get(\"colour1\");\nvar colour2 = flow.get(\"colour2\");\nvar colour3 = flow.get(\"colour3\");\nvar colour4 = flow.get(\"colour4\");\nvar colour5 = flow.get(\"colour5\");\nvar colour6 = flow.get(\"colour6\");\nvar colour7 = flow.get(\"colour7\");\n\n\n\n\nvar temp = msg.payload;\n\nif(temp<= 33){\n    msg.payload = colour1;\n}\n\nif(temp<= 35 && temp >33){\n    msg.payload = colour2;\n}\n\nif(temp<= 38 && temp >35){\n    msg.payload = colour3;\n}\n\nif(temp<= 42 && temp >38){\n    msg.payload = colour4;\n}\n\nif(temp<= 45 && temp >42){\n    msg.payload = colour5;\n}\n\nif(temp<= 48 && temp >45){\n    msg.payload = colour6;\n}\n\nif(temp >48){\n    msg.payload = colour7;\n}\n\nreturn msg;","outputs":1,"noerr":0,"x":550,"y":260,"wires":[["ad7cbc04.408c4"]]},{"id":"819fada5.d8636","type":"subflow:64a96b1a.8e3d34","z":"3accd94a.e28186","name":"","env":[{"name":"colour1","value":"Navy","type":"str"},{"name":"colour2","value":"DeepSkyBlue","type":"str"},{"name":"colour3","value":"LightSeaGreen","type":"str"},{"name":"colour4","value":"LawnGreen","type":"str"},{"name":"colour5","value":"Yellow","type":"str"},{"name":"colour6","value":"OrangeRed","type":"str"},{"name":"colour7","value":"Red","type":"str"}],"x":290,"y":100,"wires":[["68c12b8b.2f1a74"]]},{"id":"68c12b8b.2f1a74","type":"debug","z":"3accd94a.e28186","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":470,"y":100,"wires":[]},{"id":"21e6a899.49f838","type":"inject","z":"3accd94a.e28186","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":120,"y":100,"wires":[["819fada5.d8636"]]},{"id":"62362479.6ead4c","type":"comment","z":"3accd94a.e28186","name":"Settings","info":"","x":140,"y":60,"wires":[]},{"id":"7c7bae90.a2f0b","type":"function","z":"3accd94a.e28186","name":"Fan RPM Profile","func":"var speed1 = flow.get(\"speed1\");\nvar speed2 = flow.get(\"speed2\");\nvar speed3 = flow.get(\"speed3\");\n\nvar temp = msg.payload;\n\nif(temp<= 40){\n    msg.payload = 0;\n}\n\nif(temp<= 50 && temp >40){\n    msg.payload = speed1;\n}\n\nif(temp<= 60 && temp >50){\n    msg.payload = speed2;\n}\n\nif(temp >60){\n    msg.payload = speed3;\n}\n\n\nreturn msg;","outputs":1,"noerr":0,"x":540,"y":180,"wires":[["5adaa9a0.2d57b8"]]}]

Source: RPM & RGB Mod for 52pi Ice Tower Heatsink for Raspberry Pi 4

Scroll to Top
Read previous post:

A pre-provisioned solution that provides secure key storage for low-, mid- and high-volume device deployments using the ATECC608A secure element...