Hello, (and a happy new year!)
I'm using the official 20.04 minimal image on my hc4 oled.
I would like to use the integrated RTC.
The manual on the wiki for the C4 does not work.
Is there a guide available somewhere? Or should this work out of the box?
Thank you very much in advance!
how to enable RTC on HC4 OLED?
- tobetter
- Posts: 7118
- Joined: Mon Feb 25, 2013 10:55 am
- languages_spoken: Korean, English
- ODROIDs: Many
- Location: Paju, South Korea
- Has thanked: 380 times
- Been thanked: 1041 times
- Contact:
Re: how to enable RTC on HC4 OLED?
Please refer to the link,
https://wiki.odroid.com/odroid-hc4/appl ... =homecloud
Or simply install odroid-homecloud-display.
https://wiki.odroid.com/odroid-hc4/appl ... =homecloud
Or simply install odroid-homecloud-display.
Code: Select all
sudo apt update
sudo apt install odroid-homecloud-display
-
- Posts: 19
- Joined: Sat Nov 23, 2019 5:30 am
- languages_spoken: english
- ODROIDs: ODROID-HC2, ODROID-C4, ODROID-HC4, ODROID-C2
- Has thanked: 0
- Been thanked: 0
- Contact:
Re: how to enable RTC on HC4 OLED?
Hi @tobetter,
thank you for your reply!
However, it seems this still does not enable the RTC for me - after a reboot, I get:
and
Do i need to load the pcf8563.dtbo overlay from /media/boot/amlogic/overlays/odroidc4 manually?
edit:
I have modified /media/boot/config.ini and included the pcf8563.dtbo in the overlays array:
Then, the rtc is available in /dev as well as it is shown in timedatectl:
Is this the way it's supposed to be configured / enabled?
thank you for your reply!
However, it seems this still does not enable the RTC for me - after a reboot, I get:
Code: Select all
root@smaug ~ # timedatectl
Local time: Fri 2021-01-01 11:06:30 CET
Universal time: Fri 2021-01-01 10:06:30 UTC
RTC time: n/a
Time zone: Europe/Berlin (CET, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
root@smaug ~ #
Code: Select all
root@smaug ~ # ls -l /dev |grep -i rtc
1 root@smaug ~ #
Code: Select all
130 root@smaug ~ # lsmod | grep rtc
1 root@smaug ~ # lsmod | grep i2c
i2c_meson_master 20480 1
root@smaug ~ #
edit:
I have modified /media/boot/config.ini and included the pcf8563.dtbo in the overlays array:
Code: Select all
; Device Tree Overlay
overlay_resize=16384
overlay_profile=
overlays="spi0 i2c0 i2c1 uart0 pcf8563"
Code: Select all
root@smaug ~ # timedatectl
Local time: Fri 2021-01-01 11:17:27 CET
Universal time: Fri 2021-01-01 10:17:27 UTC
RTC time: Fri 2021-01-01 10:17:28
Time zone: Europe/Berlin (CET, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
- tobetter
- Posts: 7118
- Joined: Mon Feb 25, 2013 10:55 am
- languages_spoken: Korean, English
- ODROIDs: Many
- Location: Paju, South Korea
- Has thanked: 380 times
- Been thanked: 1041 times
- Contact:
Re: how to enable RTC on HC4 OLED?
Apparently, it is ... if you can see and use hwclock then adding pcf8563 to boot.ini is correct.Nox997 wrote: ↑Fri Jan 01, 2021 7:09 pmedit:
I have modified /media/boot/config.ini and included the pcf8563.dtbo in the overlays array:Then, the rtc is available in /dev as well as it is shown in timedatectl:Code: Select all
; Device Tree Overlay overlay_resize=16384 overlay_profile= overlays="spi0 i2c0 i2c1 uart0 pcf8563"
Is this the way it's supposed to be configured / enabled?Code: Select all
root@smaug ~ # timedatectl Local time: Fri 2021-01-01 11:17:27 CET Universal time: Fri 2021-01-01 10:17:27 UTC RTC time: Fri 2021-01-01 10:17:28 Time zone: Europe/Berlin (CET, +0100) System clock synchronized: yes NTP service: active RTC in local TZ: no
-
- Posts: 19
- Joined: Sat Nov 23, 2019 5:30 am
- languages_spoken: english
- ODROIDs: ODROID-HC2, ODROID-C4, ODROID-HC4, ODROID-C2
- Has thanked: 0
- Been thanked: 0
- Contact:
Re: how to enable RTC on HC4 OLED?
hello,
unfortunately, even with pcf8563 loaded, during a reboot, the system is not getting the first time information from the RTC but defaults to the unix epoch.
The last command shows what I mean:
dmesg output might give a hint as to why this is:
So it seems the rtc is registered way later that the point in time when the kernel tries to get the time from the RTC.
What can I do about this? Is this a configuration error on my side?
Thank you very much in advance for your help!
unfortunately, even with pcf8563 loaded, during a reboot, the system is not getting the first time information from the RTC but defaults to the unix epoch.
The last command shows what I mean:
Code: Select all
xxxx@odroidhc4 ~ % last
xxxx pts/0 192.168.17.26 Wed Jan 13 21:39 gone - no logout
reboot system boot 4.9.241-66 Thu Jan 1 01:00 still running
xxxx pts/0 192.168.17.26 Wed Jan 13 21:37 - 21:39 (00:01)
reboot system boot 4.9.241-66 Thu Jan 1 01:00 - 21:39 (18640+20:38)
Code: Select all
xxxx@odroidhc4 ~ % sudo dmesg |grep -i rtc
[ 9.574066] hctosys: unable to open rtc device (rtc0)
[ 16.032098] rtc-pcf8563 0-0051: rtc core: registered rtc-pcf8563 as rtc0
What can I do about this? Is this a configuration error on my side?
Thank you very much in advance for your help!
- rooted
- Posts: 8268
- Joined: Fri Dec 19, 2014 9:12 am
- languages_spoken: english
- Location: Gulf of Mexico, US
- Has thanked: 728 times
- Been thanked: 302 times
- Contact:
Re: how to enable RTC on HC4 OLED?
See this:Nox997 wrote: So it seems the rtc is registered way later that the point in time when the kernel tries to get the time from the RTC.
What can I do about this? Is this a configuration error on my side?
Thank you very much in advance for your help!
viewtopic.php?t=41488
- neal
- Posts: 244
- Joined: Fri Apr 14, 2017 10:02 am
- languages_spoken: Korean, English
- Has thanked: 9 times
- Been thanked: 18 times
- Contact:
Re: how to enable RTC on HC4 OLED?
See this wiki as well:rooted wrote: ↑Thu Jan 14, 2021 7:56 pmSee this:Nox997 wrote: So it seems the rtc is registered way later that the point in time when the kernel tries to get the time from the RTC.
What can I do about this? Is this a configuration error on my side?
Thank you very much in advance for your help!
viewtopic.php?t=41488
https://wiki.odroid.com/accessory/add-o ... rtc_shield
Who is online
Users browsing this forum: No registered users and 2 guests