#!/bin/sh
### BEGIN INIT INFO
# Provides:          Get current time from RTC
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description:
# Description:
### END INIT INFO
# Author: vheinz@carl-valentin.de

# loglevel deaktivieren fuer serielle schnittstelle
echo "0" > /proc/sys/kernel/printk

# Action
case "$1" in
    start)
        echo -e "Read the RTC" &&
        hwclock -s -u -f /dev/rtc1 &&
        echo "done."
        ;;
    quickstart)
        echo -e "Read the RTC" &&
        hwclock -s -u -f /dev/rtc1 &&
        echo "done."
        ;;
    stop)
        ;;
    restart)
        ;;
    *)
        echo "Usage: $0 {start|quickstart|stop|restart}"
        exit 1
        ;;
esac

exit 0
