PWM Fan Header and Controller Installation
# │forum
t
@CFSworks I assume you used a soldering pencil when installing the EMC2301 fan controller. I tried my heat gun. That worked fine for the 4-pin header, but the EMC2301 chip is very small and difficult to place correctly. Does the small triangle on the TPiv2.4 board at U109 indicate this is pin 1 on the EMC2301? I only want to solder this thing into place once.
c
I have never heard it called that but yes. I also used a magnifying visor and a toothpick to get the chip placed. I think I heated the pad instead of the leads so as not to disturb the chip placement until it was soldered. But iirc pin 1 is the corner closest to the HDMI port. Let me double check
Yes, pin 1 faces the "rear panel ports" side of the TPi2.
c
Yep
t
Okay. Glad I haven't solder the part yet because it would have been upside down. I suppose the chamfered corner on the pad outline should have been a clue. I'm also glad to hear that Turing Machines is including PWM fan support in the v2.5 board.
n
i'm still pissed off about the EMC2301 driver that ended up in mainline. It's a dumb stupid one that just uses the chip as a straight PWM controller.
That chip has an internal closed-loop RPM control algorithm that (w/my driver, modified from the one used in the Traverse Ten64) works with
cooling-maps
to smoothly scale RPM between temperature thresholds instead of just stepping N different pwm amounts at different temps
but nvidia didn't bother to implement any of that and they sent their driver a week before matt sent his
c
Sounds like you have the means, motive, and opportunity to submit some really sweet improvement patches to linux-hwmon to rectify the situation 😉
t
Could you share your driver source via GitHub?
n
its been up for a while
might need some updates to work on latest kernel
this is the better code to use, matt rewrote it
t
Thanks! Got the EMC2301 soldered onto my board and tested with BMC firmware 2.0.5 tonight.
n
im not sure if he fixed the issue with lower-rpm fans that i fixed in mine (see closed issues)
s
What were your results with 2.0.5?
t
Adding an EMC2301 and PWM fan header to a TPiv2.4 running BMC firmware 2.0.5 provides 11-step, variable speed fan support. The default speed is "0" or off. I've temporarily added several lines to the S93startup script that, conditionally, set the current fan speed (cur_state, R/W fifo) to the maximum fan speed value (max_state, RO fifo) defined by the driver. Ideally, bmcd, tpi and the BMC-UI will gain fan speed control support for the TPiv2.5 board release. The TPiv2.4 board seems to have one, instrumented, thermal zone: the BMC itself. The RTL8370MB-CG+ Ethernet switch chip has a passive heat sink on it. I suspect this will be the hottest component on the board itself if/when TM adds management capability. As I have time, I'll look at @User driver. I believe it provides infinitely variable fan speed control. For reference, the PWM device entries are under /sys/class/thermal/cooling_device0/. The thermal zone device entries are under /sys/class/thermal/thermal_zone0/.
I've never soldered a thing in my life what tools will i need to perform this mod
Does the BMC control the fan or do i need to do something on one of the CM4's
t
Those are the correct part numbers. The EMC2301 is tiny. I trashed two before I got one soldered correctly. You'll need a good soldering pencil/iron and either flux core solder or soldering paste. "Tin" the soldering iron and the pad contacts. The amount of solder required is infinitesimal.
c
^ I'd recommend getting ~5 of each especially if you're new to soldering. They're cheap and you're going to damage a couple of them.
If you've never soldered anything yourself, look online to see if there's a makerspace/hackerspace near where you live. These clubs usually have the tools (and will often let you use them without membership on "open night") and people who are more than happy to teach you the technique.
n
yeah the EMC2301 is a very clever little chip that can do closed-loop RPM control (and its siblings can do closed-loop PID rpm-temperature control even, but you can do that with hwmon in linux on the BMC easily enough) but the mainline driver uses it as a dumb PWM generator and RPM sensor which is just stupid
t
That's good to know. I wasn't certain whether the one thermal zone on the V2.4 board reported anything useful. Hard to know what is being measured.
n
so now that i have my board set up i can answer this
there's a thermistor next to the fan header
i haven't confirmed that's what's actually being read but it seems likely, that or it's the T113's internal temp sensor (if it has one)
t
I'm uncertain why the BMC chip would be monitored. It doesn't have a heat sink and a mPCIe slot is directly above it. There are two chips on the board that have passive heat sinks: the Ethernet switch and one other chip between the node 3 and 4 sockets.
u
@Terarex (Dan Donovan) How warm is the BMC and Ethernet switch when running?
t
I'm not certain. Other than when flashing nodes, the BMC is basically idling. The switch is running in unmanaged mode, so the computational load is low. Implementing network traffic management on the switch will create a computational load resulting in heat.
n
it doesn't have a heatsink, no, but it's an Allwinner chip with built-in DRAM they can get pretty spicy the RISC-V version gets a lot hotter than the cortex-A7 though
but, point was that generally even small SoCs have at least one internal temp sensor, but it appears that the T113-s3 does not
t
Since I'm doing the mod to a second board, a few posts on where and how to add the EMC2301 chip and 4-pin PWM fan header to a TPIliv2.3/2.4 board.
The area of the board that is of interest (before). In particular, this mod adds a 4-pin PWM fan header to the unpopulated 4-pin "FAN" location and an EMC2301 fan controller to the unpopulated U109 pad. Note two things: - the small hole within the silkscreened outline of "FAN". The header is keyed with a small pin that fits into this hole. - the silkscreened outline at pad U109 has a small notch that indicates the location of pin 1 on the EMC2301. https://cdn.discordapp.com/attachments/1178396039145848932/1263262037094567956/PXL_20240717_215753802.jpg?ex=669997f3&is=66984673&hm=fc5cbb92089eb0805ea323f195caa5a8a649e4388a84ee375c26d07f483684a9&
These are the two components that need to be added. - On the left: the 4-pin header. Note the small plastic key pin. - On the right, an EMC2301 fan controller. Note the small dimple denoting pin 1. (Yes, this chip is tiny.) I purchased both components from Digi-Key. Actually multiple of each because these aren't available generally and soldering mistakes can and do happen. The parts are: - EMC2301-1-ACZL-TR https://www.digikey.com/en/products/detail/microchip-technology/EMC2301-1-ACZL-TR/3872090 and - WM4330-ND https://www.digikey.com/en/products/detail/molex/0470531000/2421261 https://cdn.discordapp.com/attachments/1178396039145848932/1263262711546908683/PXL_20240717_221321451.jpg?ex=66999894&is=66984714&hm=44050c64fa0f1322fc78af012287594111756494e8e209c976e596c66482853e&
This is what the board should look like after the mods are in place. This is my original board, which died. I'll post another photo of the second board I'm modifying. Hopefully, it won't be as messy. https://cdn.discordapp.com/attachments/1178396039145848932/1263265526826664050/PXL_20240717_220913110.MP.jpg?ex=66999b33&is=669849b3&hm=20e67732f99a4cd66163b2454ea856d4a97434b8ad041680932f470bc7c8b77b&
There is a lot of noise in this macro photo, but no obvious signs of a bridged contact or short. Almost time to test. Update: seems to work fine. Now I need to dive back into building the latest firmware. https://cdn.discordapp.com/attachments/1178396039145848932/1263639813626663022/PXL_20240718_233043030.jpg?ex=669ba088&is=669a4f08&hm=a4f2178ef44a3892ec05f412e980cfee9f8a2cc3acb33ac9b383cb6e384d4ca1&
50 Views