Can you install Argon One fan control script on Manjaro arm

I got an Argon One case for my raspberry pi and I was wondering if there is an install script for Arch. I can’t find any results or scripts on google.

They got it going in this thread:

https://archived.forum.manjaro.org/t/how-to-install-argonone/113990

Hi
I have followed the instructions from hectorkvs in his post of 12 April 2020 to the letter as best I can:

git clone (Elrondo46 script from github)
cd argonone
sudo pacman -S base-devel (to install some missing packages)
makepkg -si
yay -S raspberrypi-userland-aarch64-git
sudo systemctl enable argononed.service
sudo reboot

Make sure you put :
dtparam=i2c_arm=on
dtparam=i2c-1=on
enable_uart=1
in config.txt before rebooting.

also I forgot to mention that the ’ enable_uart=1 ’ in /boot/config.txt in conjunction with having ’ kgdboc=ttyAMA0,115200 ’ mentioned in /boot/cmdline does crash the kernel (kernel panic) so please check for this if you are planning on automatically add the uart-option to /boot/config.txt.
I did fix this by removing ’ kgdboc=ttyAMA0,115200 ’ from my /boot/cmdline.If you have a problem with shuting down when the power isn’t cut as it should (power led still working, after pi shutdown) you need to change in ’ /usr/lib/systemd/system-shutdown/argononed-poweroff.py ’ the following:

Line 20
bus.write_byte_data(0x1a,0,0) to looks like this…

hope this help

However, when I try to configure the fan (test by setting to always on) it still doesn’t work.
When I check sudo sytstemctl status argononed.service I get:

argononed.service - Argon One Fan and Button Service
Loaded: loaded (/usr/lib/systemd/system/argononed.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2021-01-15 19:53:52 AEST; 1min 14s ago
Process: 1881 ExecStart=/opt/argonone/bin/python3 /opt/argonone/bin/argononed.py (code=exited, status=1/FAILURE)
Main PID: 1881 (code=exited, status=1/FAILURE)

Jan 15 19:53:52 ARMManjaroKDE systemd[1]: argononed.service: Main process exited, code=exited, status=1/FAILURE
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: argononed.service: Failed with result ‘exit-code’.
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: argononed.service: Scheduled restart job, restart counter is at 5.
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: Stopped Argon One Fan and Button Service.
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: argononed.service: Start request repeated too quickly.
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: argononed.service: Failed with result ‘exit-code’.
Jan 15 19:53:52 ARMManjaroKDE systemd[1]: Failed to start Argon One Fan and Button Service.

Here’s the output of Neofetch for my system:

[stevemanjkde@ARMManjaroKDE /]$ neofetch
stevemanjkde@ARMManjaroKDE

OS: Manjaro ARM Linux aarch64
Host: Raspberry Pi 4 Model B Rev 1.4
Kernel: 5.4.83-1-MANJARO-ARM
Uptime: 1 hour, 37 mins
Packages: 1005 (pacman)
Shell: bash 5.1.0
Resolution: 1920x1080
DE: Plasma 5.20.4
WM: KWin
Theme: Breath2Dark [Plasma], Breeze [GTK2], Breath-Dark [GTK3]
Icons: breath2-dark [Plasma], breath2-dark [GTK2/3]
Terminal: konsole
CPU: BCM2835 (4) @ 1.500GHz
Memory: 2122MiB / 7379MiB

Going crazy. Please help.

Steve
Not a coder, just a user with a few years experience.

What happens if you just execute:

/opt/argonone/bin/python3 /opt/argonone/bin/argononed.py

Any errors in the output?

I may be thinking about something else but was installing RPi.GPIO mentioned in the guide.

Also I would git rid of raspberrypi-userland-aarch64-git and use raspberrypi-userland-aarch64 in the repo. The AUR package has not been updtaed in almost a year.

Thanks for your reply.
This is the output of running the commands you suggested.

/opt/argonone/bin/python3 /opt/argonone/bin/argononed.py
Traceback (most recent call last):
File “/opt/argonone/bin/argononed.py”, line 9, in
import smbus
ModuleNotFoundError: No module named ‘smbus’

Does this suggest a hardware error? The original argonone script works fine on a Ubuntu Mate for ARM that I have installed on a separate SSD.

Steve

Sounds like a missing dependency.

Try installing smbus2 with:
sudo pip install smbus2

I decided to give this a try and the fan speed setting does work. It seems to check the cpu temp at some interval, as the fan does not (de)activate immediately upon hitting the configured temperature, not according to my conky script anyway.

Edit: After running this a couple of days with the fan set to run at 40° C, it does make a definite difference. Especially noticeable by the temperature of the case. I had my doubts as to how much of a difference the fan would make.

So this evening I become aware that the fan is not spinning up. I check the status of the service and it is failed. I run the python app from the command line and see the error, file not found for /dev/i2c-1
I check and sure enough, not there. Why? dunno. Why did it exist previously? dunno.

How did I fix it? By adding the following to config.txt

dtparam=i2c1=on

I believe there is more than one way to activate this device, so no doubt my messing around with settings caused its (dis)appeance.

Yeh didn’t work for me, trying to find the version that actually worked for me on Manjaro.

I switched to using argonone-c-git in the AUR. It does not depend on the gpio python package.

It uses a dtoverlay= in the config.txt and can be configured like:

dtoverlay=argonone,hysteresis=5
dtparam=fantemp0=45,fanspeed0=33
dtparam=fantemp1=50,fanspeed1=67
dtparam=fantemp2=55,fanspeed2=100

And you can use the command line to change the values on the fly, if desired.

1 Like

Hey thanks for helping me get it working, I did try it but I didn’t quite know how to get it working until you showed me. while using dtoverlay=argonone,hysteresis=5 my fan would always be on even if it was sitting in at 40ish c before it would turn on so I set it to auto and it now only runs when needed and stopped.

Fan still seems to want to run before it even hits the correct minimal temp which is annoying because they fan is a bit annoying and high pitched and I don’t want to hear it for a long amount of time, got any ideas on how to fix that? …

I might make a post about this so others can easily find this if they need it.