diff options
Diffstat (limited to 'client/ur_fuzzy_alarm_clock.py')
-rwxr-xr-x | client/ur_fuzzy_alarm_clock.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/client/ur_fuzzy_alarm_clock.py b/client/ur_fuzzy_alarm_clock.py index e86d6fd..1f0775d 100755 --- a/client/ur_fuzzy_alarm_clock.py +++ b/client/ur_fuzzy_alarm_clock.py @@ -39,14 +39,14 @@ class FuzzyAlarmClock: days = [] for j in xrange(8): days.append(bool(int(data[i][0]) & 2**j)) - days.reverse() + days = days[7:8] + days[:7] data[i] = days+data[i][1:] return data def set_alarm(self,alarm,values): s = 'a'+str(alarm) b0 = 0 - for i,bit in enumerate(values[:8][::-1]): + for i,bit in enumerate(values[1:8] + values[0:1]): b0 += bit << i s += "%02x"%(b0) for val in values[8:]: |