phyBOARD-Wega AM335x [PB-00802-xxx]
70
©
PHYTEC Messtechnik GmbH 2014 L-792e_1
3.2.12
Addressing the RTC
The RTC RV-4162-C7 on the phyCORE-AM335x can be accessed as
/dev/rtc0
. It also has the
entry
/sys/class/rtc/rtc0
in the sysfs file system, where you can, for example, read the
name
.
Date and time can be manipulated with the
hwclock
tool, using the
-w
(systohc) and
-s
(hctosys) options. For more information about this tool refer to the manpage of
hwclock
.
To set the date first use
date
(see
man date
on the PC) and then run
hwclock -w -u
to store
the new date into the RTC.
Please note that in case you need to use RTC’s interrupt, you need to shortcut pin 37
x_intr1
and pin 40
x_intr_RTCn
of the expansion connector X69. But this can only be done if
you do not need this interrupt line for a touch controller.
3.2.13
CPU Core Frequency Scaling
The phyBOARD-Wega AM335x supports dvfs (dynamic voltage and frequency scaling).
Several different frequencies are supported. Type
cat
/sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
to get a complete list. In case you have an AM3354 or AM3359 with a maximum of 800 MHz
the result will be:
300000
600000
720000
800000
.
The voltages are scaled according to the setup of the frequencies.
You can decrease the maximum frequency (e.g. to 720000)
echo
720000
>
/sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
or increase the minimum frequency (e.g. to 600000)
echo
600000
>
/sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
Asking for the current frequency is done with:
cat
/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq
So called governors are selecting one of these frequencies in accordance to their goals,
automatically. The governors available can be listed with the following command:
cat
/sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors