N2Plus Fan Sensors

Post Reply
binxbolling
Posts: 3
Joined: Sat Jul 25, 2020 12:24 am
languages_spoken: english
ODROIDs: N2+
Has thanked: 0
Been thanked: 0
Contact:

N2Plus Fan Sensors

Post by binxbolling »

I had assumed that the N2Plus would use sensors that were supported by lm-sensors, but found that assumption to be wrong. I have an active fan connected to the N2Plus but don't know how to determine if it works, or how to test it. Any recommendations?

User avatar
tobetter
Posts: 6635
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 330 times
Been thanked: 924 times
Contact:

Re: N2Plus Fan Sensors

Post by tobetter »

'lm-sensors' won't be supported, you can test these commands to check if FAN works.

Code: Select all

# cat /sys/devices/virtual/thermal/cooling_device*/type
thermal-gpufreq-0
thermal-gpucore-0
pwm-fan
thermal-cpufreq-0
thermal-cpufreq-1
thermal-cpucore-0
# echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state

binxbolling
Posts: 3
Joined: Sat Jul 25, 2020 12:24 am
languages_spoken: english
ODROIDs: N2+
Has thanked: 0
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by binxbolling »

Thank you for your response.

I received the following response after entering "cat /sys/devices/virtual/thermal/cooling_device*/type":
thermal-gpufreq-0
thermal-gpucore-0
pwm-fan
thermal-cpufreq-0
thermal-cpufreq-1
thermal-cpucore-0

After entering "echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state" I received no response.

hominoid
Posts: 485
Joined: Tue Feb 28, 2017 3:55 am
languages_spoken: english
ODROIDs: C2, C4, XU4, MC1, N1, N2, N2+, HC4
Location: Lake Superior Basin, USA
Has thanked: 47 times
Been thanked: 160 times
Contact:

Re: N2Plus Fan Sensors

Post by hominoid »

The HK images have 2 thermal trip points for activating the fan.

Code: Select all

hominoid@odroid-n2plus:~$ cat /sys/devices/virtual/thermal/thermal_zone0/trip_point_4_temp
65000
hominoid@odroid-n2plus:~$ cat /sys/devices/virtual/thermal/thermal_zone0/trip_point_5_temp
75000
The easiest way to activate the fan is to change the first trip point to 20c which has the effect of turning the fan on always. There is a slight delay before the fan starts.

Code: Select all

hominoid@odroid-n2plus:~$ echo 20000 | sudo tee /sys/devices/virtual/thermal/thermal_zone0/trip_point_4_temp
[sudo] password for hominoid: 
20000
hominoid@odroid-n2plus:~$ 
You can use these command in /etc/rc.local to change the trip points at boot time if you want to set different cooling levels then the default.
These users thanked the author hominoid for the post (total 3):
odroid (Sat Jul 25, 2020 10:06 am) • secuflag (Fri Jul 31, 2020 11:23 pm) • m_ueberall (Wed Aug 19, 2020 8:17 pm)

binxbolling
Posts: 3
Joined: Sat Jul 25, 2020 12:24 am
languages_spoken: english
ODROIDs: N2+
Has thanked: 0
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by binxbolling »

Thanks. That worked.

Richardblakecr
Posts: 10
Joined: Sun Aug 09, 2020 11:26 pm
languages_spoken: english
ODROIDs: ODROID N2 Plus
Has thanked: 7 times
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by Richardblakecr »

How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?

User avatar
tobetter
Posts: 6635
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 330 times
Been thanked: 924 times
Contact:

Re: N2Plus Fan Sensors

Post by tobetter »

Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
These users thanked the author tobetter for the post:
m_ueberall (Thu Aug 20, 2020 5:07 pm)

Richardblakecr
Posts: 10
Joined: Sun Aug 09, 2020 11:26 pm
languages_spoken: english
ODROIDs: ODROID N2 Plus
Has thanked: 7 times
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by Richardblakecr »

tobetter wrote: ↑
Wed Aug 12, 2020 11:37 am
Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
I'm on Android πŸ˜…, but I'll give it a go!

User avatar
tobetter
Posts: 6635
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 330 times
Been thanked: 924 times
Contact:

Re: N2Plus Fan Sensors

Post by tobetter »

Richardblakecr wrote: ↑
Wed Aug 12, 2020 12:44 pm
tobetter wrote: ↑
Wed Aug 12, 2020 11:37 am
Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
I'm on Android πŸ˜…, but I'll give it a go!
Oh, then there is another instruction here.
viewtopic.php?p=301249#p301249
These users thanked the author tobetter for the post:
Richardblakecr (Wed Aug 12, 2020 1:08 pm)

Richardblakecr
Posts: 10
Joined: Sun Aug 09, 2020 11:26 pm
languages_spoken: english
ODROIDs: ODROID N2 Plus
Has thanked: 7 times
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by Richardblakecr »

tobetter wrote: ↑
Wed Aug 12, 2020 12:46 pm
Richardblakecr wrote: ↑
Wed Aug 12, 2020 12:44 pm
tobetter wrote: ↑
Wed Aug 12, 2020 11:37 am
Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
I'm on Android πŸ˜…, but I'll give it a go!
Oh, then there is another instruction here.
viewtopic.php?p=301249#p301249
Thank you, but it did not do anything. After double-checking, but that one command turns it on so, as long as I do not reboot it will be fine I guess.

User avatar
tobetter
Posts: 6635
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 330 times
Been thanked: 924 times
Contact:

Re: N2Plus Fan Sensors

Post by tobetter »

Richardblakecr wrote: ↑
Wed Aug 12, 2020 1:10 pm
tobetter wrote: ↑
Wed Aug 12, 2020 12:46 pm
Richardblakecr wrote: ↑
Wed Aug 12, 2020 12:44 pm
tobetter wrote: ↑
Wed Aug 12, 2020 11:37 am
Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
I'm on Android πŸ˜…, but I'll give it a go!
Oh, then there is another instruction here.
viewtopic.php?p=301249#p301249
Thank you, but it did not do anything. After double-checking, but that one command turns it on so, as long as I do not reboot it will be fine I guess.
Did you update the device tree partition with the file in the link?
These users thanked the author tobetter for the post:
Richardblakecr (Wed Aug 12, 2020 9:00 pm)

Richardblakecr
Posts: 10
Joined: Sun Aug 09, 2020 11:26 pm
languages_spoken: english
ODROIDs: ODROID N2 Plus
Has thanked: 7 times
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by Richardblakecr »

tobetter wrote: ↑
Wed Aug 12, 2020 1:12 pm
Richardblakecr wrote: ↑
Wed Aug 12, 2020 1:10 pm
tobetter wrote: ↑
Wed Aug 12, 2020 12:46 pm
Richardblakecr wrote: ↑
Wed Aug 12, 2020 12:44 pm
tobetter wrote: ↑
Wed Aug 12, 2020 11:37 am
Richardblakecr wrote: ↑
Wed Aug 12, 2020 11:26 am
How do I make this change be permanent? I got it to work.. but... when I reboot the fan does not spin. How can I make the fan triggers change permanently?
Can you please do an update kernel package so you have 4.9.230-94?
After updating, please check if you have the file /media/boot/amlogic/overlays/odroidn2/fanspeed-full.dtbo.
If you have this file, edit the file /media/boot/config.ini like this. By adding fanspeed-full will make the fan run permanently.

Code: Select all

; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 fanspeed-full"

[overlay_custom]
overlays="i2c0 i2c1"
I'm on Android πŸ˜…, but I'll give it a go!
Oh, then there is another instruction here.
viewtopic.php?p=301249#p301249
Thank you, but it did not do anything. After double-checking, but that one command turns it on so, as long as I do not reboot it will be fine I guess.
Did you update the device tree partition with the file in the link?
I'm running LineageOS 17.1, so the config.ini isn't in the right spot. There was an alternate method, and I've incerted the changes to the boot.ini that worked for the person that had lineageOS 16, but my fan still won't spin. Lol

There is something I punch into the terminal and I can get it to spin by using an echo and tee command.

Later I find out when I try to over clock the system. It won't over clock. Lol, I change the speed and it won't stay changed when I verify it. So there is some more trouble shooting to do, the over clocking was why I wanted the fan on in the first place.

jejones3141
Posts: 1
Joined: Fri May 13, 2016 12:17 pm
languages_spoken: english
Has thanked: 2 times
Been thanked: 0
Contact:

Re: N2Plus Fan Sensors

Post by jejones3141 »

I got a fan for my Odroid N2+ and find myself in a similar situation; the fan is connected but doesn't run.

"uname -v" displays "#1 SMP PREEMPT Ubuntu 5.7.14-202008080152-focal (2020-08-07)"

"cat /sys/devices/virtual/thermal/cooling_device*/type" just gives the output

thermal-cpufreq-0
thermal-cpufreq-1
pwm-fan

"echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state" has no effect.

How can I make sure the fan will run?

User avatar
istanbulls
Posts: 380
Joined: Tue May 14, 2019 10:18 pm
languages_spoken: Turkish
ODROIDs: ODROID; N2, C4, XU4, N2+, CH4
Location: Istanbul-Turkey
Has thanked: 234 times
Been thanked: 54 times
Contact:

Re: N2Plus Fan Sensors

Post by istanbulls »

jejones3141 wrote: ↑
Wed Aug 26, 2020 11:15 am
I got a fan for my Odroid N2+ and find myself in a similar situation; the fan is connected but doesn't run.

"uname -v" displays "#1 SMP PREEMPT Ubuntu 5.7.14-202008080152-focal (2020-08-07)"

"cat /sys/devices/virtual/thermal/cooling_device*/type" just gives the output

thermal-cpufreq-0
thermal-cpufreq-1
pwm-fan

"echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state" has no effect.

How can I make sure the fan will run?
I am having the same problem.
It worked fine with Ubuntu-Mate.
But fan did not work with Ubuntu-Gnome-Wayland 20.04.1.
I have tried all the methods described here.

User avatar
tobetter
Posts: 6635
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 330 times
Been thanked: 924 times
Contact:

Re: N2Plus Fan Sensors

Post by tobetter »

istanbulls wrote: ↑
Thu Oct 29, 2020 9:49 am
jejones3141 wrote: ↑
Wed Aug 26, 2020 11:15 am
I got a fan for my Odroid N2+ and find myself in a similar situation; the fan is connected but doesn't run.

"uname -v" displays "#1 SMP PREEMPT Ubuntu 5.7.14-202008080152-focal (2020-08-07)"

"cat /sys/devices/virtual/thermal/cooling_device*/type" just gives the output

thermal-cpufreq-0
thermal-cpufreq-1
pwm-fan

"echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state" has no effect.

How can I make sure the fan will run?
I am having the same problem.
It worked fine with Ubuntu-Mate.
But fan did not work with Ubuntu-Gnome-Wayland 20.04.1.
I have tried all the methods described here.
Let me look into this if I am missing when building the image.
These users thanked the author tobetter for the post:
istanbulls (Thu Oct 29, 2020 10:53 am)

User avatar
istanbulls
Posts: 380
Joined: Tue May 14, 2019 10:18 pm
languages_spoken: Turkish
ODROIDs: ODROID; N2, C4, XU4, N2+, CH4
Location: Istanbul-Turkey
Has thanked: 234 times
Been thanked: 54 times
Contact:

Re: N2Plus Fan Sensors

Post by istanbulls »

tobetter wrote: ↑
Thu Oct 29, 2020 10:11 am
istanbulls wrote: ↑
Thu Oct 29, 2020 9:49 am
jejones3141 wrote: ↑
Wed Aug 26, 2020 11:15 am
I got a fan for my Odroid N2+ and find myself in a similar situation; the fan is connected but doesn't run.

"uname -v" displays "#1 SMP PREEMPT Ubuntu 5.7.14-202008080152-focal (2020-08-07)"

"cat /sys/devices/virtual/thermal/cooling_device*/type" just gives the output

thermal-cpufreq-0
thermal-cpufreq-1
pwm-fan

"echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state" has no effect.

How can I make sure the fan will run?
I am having the same problem.
It worked fine with Ubuntu-Mate.
But fan did not work with Ubuntu-Gnome-Wayland 20.04.1.
I have tried all the methods described here.
Let me look into this if I am missing when building the image.
I am in no hurry!

Code: Select all

odroid@ubuntu:~$ echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state
bash: /sys/devices/virtual/thermal/cooling_device2/cur_state: Permission denied
odroid@ubuntu:~$ echo 20000 | sudo tee /sys/devices/virtual/thermal/thermal_zone0/trip_point_4_temp
[sudo] password for odroid: 
tee: /sys/devices/virtual/thermal/thermal_zone0/trip_point_4_temp: Permission denied
20000
odroid@ubuntu:~$ lscpu | grep "MHz"
CPU max MHz:                     2400,0000
CPU min MHz:                     1000,0000
odroid@ubuntu:~$ cat /sys/devices/virtual/thermal/cooling_device*/type
thermal-cpufreq-0
thermal-cpufreq-1
pwm-fan
odroid@ubuntu:~$ echo 3 > /sys/devices/virtual/thermal/cooling_device2/cur_state
bash: /sys/devices/virtual/thermal/cooling_device2/cur_state: Permission denied
odroid@ubuntu:~$ cat /proc/device-tree/model
Hardkernel ODROID-N2Plusodroid@ubuntu:~$ 
odroid@ubuntu:~$ 
OS I installed for N2.
I made all the updates and upgrades for the N2+.
My Oled screen that starts up when the system is turned on, works sometimes, sometimes not. occasionally I have to enter the command "sudo python3 xxxx.py".

Off topic: I have to say that N2+ is really fast. Using N2+ is enjoyable. :)

User avatar
istanbulls
Posts: 380
Joined: Tue May 14, 2019 10:18 pm
languages_spoken: Turkish
ODROIDs: ODROID; N2, C4, XU4, N2+, CH4
Location: Istanbul-Turkey
Has thanked: 234 times
Been thanked: 54 times
Contact:

Re: N2Plus Fan Sensors

Post by istanbulls »

Hi @tobetter
I can't change it because I don't have administrator rights.
I tried it with sudo su.
I tried it with Nano.
I tried it with Caja "Edit as Administrator".
I could not get administrator permissions.

mad_ady
Posts: 8831
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, C4, N1, N2, H2, Go, Go Advance
Location: Bucharest, Romania
Has thanked: 586 times
Been thanked: 531 times
Contact:

Re: N2Plus Fan Sensors

Post by mad_ady »

@istanbulls here's how I start my oled display. Works every time:

Code: Select all

adrianp@spica-c2:~$ cat /etc/systemd/system/clock.service
[Unit]
Description=OLED clock                                After=network.target

[Service]
WorkingDirectory=/home/adrianp/bin
ExecStart=/usr/bin/python3 /home/adrianp/bin/clock.py
Type=simple
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target
These users thanked the author mad_ady for the post:
istanbulls (Fri Oct 30, 2020 5:38 am)

User avatar
istanbulls
Posts: 380
Joined: Tue May 14, 2019 10:18 pm
languages_spoken: Turkish
ODROIDs: ODROID; N2, C4, XU4, N2+, CH4
Location: Istanbul-Turkey
Has thanked: 234 times
Been thanked: 54 times
Contact:

Re: N2Plus Fan Sensors

Post by istanbulls »

mad_ady wrote: ↑
Fri Oct 30, 2020 5:21 am
@istanbulls here's how I start my oled display. Works every time:

Code: Select all

adrianp@spica-c2:~$ cat /etc/systemd/system/clock.service
[Unit]
Description=OLED clock                                After=network.target

[Service]
WorkingDirectory=/home/adrianp/bin
ExecStart=/usr/bin/python3 /home/adrianp/bin/clock.py
Type=simple
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target
I had no problem using N2.
Problems started with N2 +.
When the system is turned on, the oled screen opens, sometimes the texts are broken and the screen turns on again. After a while the oled screen turns off. The screen turns back on when I run the sudo pythone3 xxxx.py command. interesting problem.
N2 + does not work steadily in general, I am confused, I tried a lot for 2 days.
I'm starting to think this is the case because N2 + OC. :(

did you get sh1106 oled screen? 0.96 is too small, I got used to the 1.3 screen :)

mad_ady
Posts: 8831
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, C4, N1, N2, H2, Go, Go Advance
Location: Bucharest, Romania
Has thanked: 586 times
Been thanked: 531 times
Contact:

Re: N2Plus Fan Sensors

Post by mad_ady »

Yes, I got the 0.96 one because it was available locally. Kids got used to it and can read the time from ~2m away
These users thanked the author mad_ady for the post:
istanbulls (Fri Oct 30, 2020 5:54 am)

Post Reply

Return to β€œHardware and peripherals”

Who is online

Users browsing this forum: No registered users and 1 guest