Try and fix display on real display
This commit is contained in:
parent
132e20b220
commit
558274927c
3 changed files with 8 additions and 7 deletions
|
@ -105,7 +105,7 @@ class DBFAnimation(BubaAnimation):
|
|||
title = self.station
|
||||
else:
|
||||
title = f"{self.station} ({page+1}/{all_len})"
|
||||
self.buba.text(page=0, row=0, col_start=0, col_end=120, text=title, align=BubaCmd.ALIGN_LEFT)
|
||||
self.buba.text(page=0, row=0, col_start=0, col_end=92, text=title, align=BubaCmd.ALIGN_LEFT)
|
||||
for i, train in enumerate(trains):
|
||||
if train['isCancelled']:
|
||||
when = "--"
|
||||
|
@ -113,11 +113,11 @@ class DBFAnimation(BubaAnimation):
|
|||
when = self.countdown(train)
|
||||
if when < 0:
|
||||
when = 0
|
||||
self.buba.text(page=0, row=i + 1, col_start=0, col_end=120, text=self.short_train(train['train']))
|
||||
self.buba.text(page=0, row=i + 1, col_start=12, col_end=76, text=self.short_station(train['destination']))
|
||||
self.buba.text(page=0, row=i + 1, col_start=105, col_end=120,
|
||||
self.buba.text(page=0, row=i + 1, col_start=0, col_end=119, text=self.short_train(train['train']))
|
||||
self.buba.text(page=0, row=i + 1, col_start=12, col_end=104, text=self.short_station(train['destination']))
|
||||
self.buba.text(page=0, row=i + 1, col_start=105, col_end=119,
|
||||
text=str(when), align=BubaCmd.ALIGN_RIGHT)
|
||||
self.buba.set_page(0)
|
||||
for i in range(10):
|
||||
self.buba.text(page=0, row=0, col_start=93, col_end=120, text=datetime.datetime.now().strftime("%H:%M:%S"), align=BubaCmd.ALIGN_RIGHT)
|
||||
self.buba.text(page=0, row=0, col_start=93, col_end=119, text=datetime.datetime.now().strftime("%H:%M:%S"), align=BubaCmd.ALIGN_RIGHT)
|
||||
sleep(1)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue