Skip to content

Commit

Permalink
Main merged and visually matching
Browse files Browse the repository at this point in the history
  • Loading branch information
brickbots committed Mar 8, 2024
1 parent 533b2aa commit e84cc92
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions python/PiFinder/displays.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def get(self, color_intensity):
class DisplayBase:
resolution = (128, 128)
color_mask = RED_RGB
titlebar_height = 18
titlebar_height = 17
base_font_size = 10
bold_font_size = 12
small_font_size = 8
Expand Down Expand Up @@ -93,7 +93,7 @@ class DisplaySSD1351(DisplayBase):

def __init__(self):
# init display (SPI hardware)
serial = spi(device=0, port=0, bus_speed_hz=48000000)
serial = spi(device=0, port=0, bus_speed_hz=40000000)
device_serial = ssd1351(serial, rotate=0, bgr=True)

device_serial.capabilities(
Expand Down
2 changes: 1 addition & 1 deletion python/PiFinder/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ def main(script_name=None, show_fps=False, verbose=False):
global display_device

# display_device = get_display(hardware_platform)
display_device = get_display("PFPro")
display_device = get_display("Pi")
init_keypad_pwm()
setup_dirs()

Expand Down
2 changes: 1 addition & 1 deletion python/PiFinder/ui/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ def message(self, message, timeout=2):
)
message = " " * int((16 - len(message)) / 2) + message
self.draw.text(
(9, 54), message, font=self.fonts.bold.font.font, fill=self.colors.get(255)
(9, 54), message, font=self.fonts.bold.font, fill=self.colors.get(255)
)
self.display.display(self.screen.convert(self.display.mode))
self.ui_state.set_message_timeout(timeout + time.time())
Expand Down
8 changes: 4 additions & 4 deletions python/PiFinder/ui/chart.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,15 +193,15 @@ def update(self, force=False):
fill=self.colors.get(0),
)
self.draw.text(
(18, 20),
(self.display_class.titlebar_height + 2, 20),
"Can't plot",
font=self.font_large.font,
font=self.fonts.large.font,
fill=self.colors.get(255),
)
self.draw.text(
(25, 50),
(self.display_class.titlebar_height + 2 + self.fonts.large.height, 50),
"No Solve Yet",
font=self.font_base.font,
font=self.fonts.base.font,
fill=self.colors.get(255),
)

Expand Down

0 comments on commit e84cc92

Please sign in to comment.