diff options
author | Damien George <damien.p.george@gmail.com> | 2014-04-21 20:18:37 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-04-21 20:18:37 +0100 |
commit | ca045d97b949fbc87a2c56594431a42abfd1f2ba (patch) | |
tree | 9a86c5bf7f0a957846cdd71271f1fe19de450617 /tools/pyboard.py | |
parent | 5ea69859c9037624a8d6e6e2b4c73c78cb6c3e55 (diff) | |
download | micropython-ca045d97b949fbc87a2c56594431a42abfd1f2ba.tar.gz micropython-ca045d97b949fbc87a2c56594431a42abfd1f2ba.zip |
tools: Update pyboard.py to work with latest changes to RTC.
Diffstat (limited to 'tools/pyboard.py')
-rw-r--r-- | tools/pyboard.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/pyboard.py b/tools/pyboard.py index d5b3237cab..a44710914e 100644 --- a/tools/pyboard.py +++ b/tools/pyboard.py @@ -89,8 +89,8 @@ class Pyboard: return self.exec(pyfile) def get_time(self): - t = str(self.exec('pyb.time()'), encoding='ascii').strip().split()[1].split(':') - return int(t[0]) * 3600 + int(t[1]) * 60 + int(t[2]) + t = str(self.eval('pyb.RTC().datetime()'), encoding='ascii')[1:-1].split(', ') + return int(t[4]) * 3600 + int(t[5]) * 60 + int(t[6]) def execfile(filename, device='/dev/ttyACM0'): pyb = Pyboard(device) |