树莓派上使用的DS3231时钟模块
直接复制的国外分享:
# Comment out the blacklist entry so the module can be loaded on boot
You should see a response with what the chip thinks is the date. I think mine said 1999 or some such. No problem.
If your system date is NOT correct (if you don't have an internet connection or something), set the date using ONE of the following commands, with the appropriate date and time, of course:
<span style="line-height: 1.5;"># Only do ONE of two the below:</span>Next, to read the time from the RTC chip and set the system time from it at every boot, open /etc/rc.local and add these two lines above the exit 0 line:
echo ds3231 0x68 > /sys/class/i2c-adapter/i2c-1/new_deviceWe can also disable the ntp daemon and fake-hwclock during boot.
sudo update-rc.d ntp disableThat's it. Pretty easy.
You can still sync the system time from the internet using...
sudo ntpd -gq
B+的可以么 谢谢分享,学习中。。。 在论坛共享的1、31号的raspibian系统上测试失败 2012年的资料,也不经证实,直接转 我现在正在折腾这个模块,不能用啊
页:
[1]