The CM4 defaults to using the built-in antenna on its PCB. Adding dtparam=ant2 to my /boot/config.txt and rebooting causes it to use the external antenna and a massive improvement in reception.
I noticed by WiFi reception of my CM4 uConsole got worse when I put the back cover on, and reception was considerably lower compared to an external USB WiFi adapter.
I started modding it to add an adjustable antenna, and discovered that no matter what I antenna I used (or no antenna) the reception was the same. Digging deeper it turns out that the external antenna header on the CM4 board is disabled by default, and it prefers to use the onboard antenna instead. Switching it use the external antenna fixed the reception issues.
I hope that makes it into the default config for the next release.
No reason to depend on the internal one, especially when the uconsole has a metal shell.
Thanks for this, I found that this did make a difference.
One thing I did find that turning this on actually reduced the signal - so I opened it up and not reconnected the antenna but just carefully rotated it in the socket a little bit and when it improved.
It could have been that it didn’t have a clean connection so rotating it helped it make a better contact. Anyhow after that and this config change has now improved WiFi.
Yes, using the latest image. Without this parameter it can’t be using the external antenna, there is no antenna specific customization in the uconsole CM4 patches.
Hearing the mixed results others are having, I would guess there are a variety of environmental factors that might make one work better than the other due to the complex nature of wireless signals.
Cool, just checking. The connector will be the same, but the antenna element should be different. Plugging the 4g antenna into the wifi radio would cause reception issues.
Well i have fixed it thanks to the guys over on the clockwork discord run the below command and reboot. Note inc all the quote marks my wifi is much faster now its a win.
sudo sh -c 'echo "dtparam=ant2" >> /boot/config.txt'
you can check if the command worked with cat /boot/config.txt
I added the dtparam=ant2 line to the bottom of config.txt as recommended and my wireless is still miserable on my CM4. It actually seems to be slightly worse and disconnects more often while the signal strength remains roughly the same. This is very confusing behavior and i thought my connection or antenna were bad, but when i used an old antenna from an ancient desktop wireless card with the same connector there wasnt any improvement.
Yes that setting was much much worse on my 5ghz network.
Reverting to default gives better reception (but still poor in marginal locations in the house)