summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/__pycache__/features.cpython-312.pycbin0 -> 9305 bytes
-rw-r--r--source/__pycache__/hardware_driver.cpython-312.pycbin0 -> 4078 bytes
-rw-r--r--source/main.py15
3 files changed, 7 insertions, 8 deletions
diff --git a/source/__pycache__/features.cpython-312.pyc b/source/__pycache__/features.cpython-312.pyc
new file mode 100644
index 0000000..f4fb57d
--- /dev/null
+++ b/source/__pycache__/features.cpython-312.pyc
Binary files differ
diff --git a/source/__pycache__/hardware_driver.cpython-312.pyc b/source/__pycache__/hardware_driver.cpython-312.pyc
new file mode 100644
index 0000000..0ff8d39
--- /dev/null
+++ b/source/__pycache__/hardware_driver.cpython-312.pyc
Binary files differ
diff --git a/source/main.py b/source/main.py
index c587c6e..95c7b0c 100644
--- a/source/main.py
+++ b/source/main.py
@@ -6,14 +6,13 @@ from PySide6.QtWidgets import (
QVBoxLayout,
QWidget,
)
-
from PySide6.QtCore import Qt
import hardware_driver as lcd
import features as fe
import sys
-F = fe.feat()
-L = lcd.LCD()
+F = fe.feat() # Assuming 'feat' is a class in your 'features' module
+L = lcd.LCD() # Assuming 'LCD' is a class in your 'hardware_driver' module
class mainWindow(QMainWindow):
@@ -24,8 +23,8 @@ class mainWindow(QMainWindow):
self.mainUI()
def mainUI(self):
- central_widget = QWidget(self)
- self.setCentralWidget(central_Widget)
+ central_widget = QWidget(self) # Fixed variable name (capital 'C' to lowercase)
+ self.setCentralWidget(central_widget)
self.label = QLabel("CONNECTED TO I2C DEVICE", self)
self.label.setAlignment(Qt.AlignCenter)
@@ -39,9 +38,9 @@ class mainWindow(QMainWindow):
central_widget.setLayout(layout)
- def clear_screen():
- fe.clear()
- self.label.setText("Cleared the LCD screen", self)
+ def clear_screen(self): # Added 'self' as the first argument
+ F.clear() # Call the clear method from 'feat' object
+ self.label.setText("Cleared the LCD screen") # Update the label text
if __name__ == "__main__":