Commit 299d42e1 authored by lyong's avatar lyong

fix:修改测试硬件RTC节点

parent 96a20b0f
......@@ -102,7 +102,13 @@ function checkAutoFactory() {
}
function getRtcTime() {
system("hwclock > /tmp/hwRtc.txt");
// hwclock -f /dev/rtc1
// /dev/rtc1
var partFilePath = "../../../../../dev/rtc1";
if (!fs.exists(partFilePath)) {
return "NA";
}
system("hwclock -f /dev/rtc1 > /tmp/hwRtc.txt");
const coresStr = fs.read("/tmp/hwRtc.txt", "r");
if (coresStr) {
return coresStr.split('\n');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment