ARTiGO A820 Linux BSP v3.2.1 Quick Start Guide
23
To output a “Low” value on the GPO pin, use the following command:
$ echo 0 > /sys/class/gpio/gpio7/value
To output a “High” value on the GPO pin, use the following command:
$ echo 1 > /sys/class/gpio/gpio7/value
5.9.
Configuring RTC
As the first step, set the system time with the Linux date command, for example as:
$ date mmddHHMMYYYY
Time
Value
mm
2-digit month
dd
2-digit day
HH
2-digit hours in 24h system
MM
2-digit minutes
YYYY
4-digit year
Time value table
For example, the value 061110072013 means June 11 2013 10:07. The date command
also accepts other time formats. For more information, use the following command:
$ date --help
To write the system time to the RTC, use the following command:
$ hwclock -w -f /dev/rtc0
To read the RTC time, use the following command:
$ hwclock -r