You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+66-1
Original file line number
Diff line number
Diff line change
@@ -116,7 +116,72 @@ The microcontroller firmware of the `Raspberry Pi Pico` was created in micropyth
116
116
The source code files are located in the folder `src/firmware_rp2040` and the Python source code files in the folder `src/firmware_rp2040/src`.
117
117
The program `Thonny` can be used to adapt the software directly on the scale.
118
118
119
-
## BUILD FIRMWARE IMAGE
119
+
### STRUCTURE
120
+
121
+
The entry point of the software is in the `main.py`, which is called by the custom pre-boot script `boot.py`. The general configuration of the hardware (e.g. which pins the buttons are connected to) is done in the `config.py` file.
122
+
123
+
The control of the hardware components is done in the files:
124
+
125
+
*`ui.py` - UI system + display control
126
+
*`ledring.py` - LED effects for the LED ring
127
+
*`Scales.py` - readout of the HX711
128
+
*`settings.py`- filesystem access for writing/reading recipe files and settings
129
+
130
+
All these classes can be easily called from all other scripts using the singleton pattern. This makes integration very simple and uniform:
To create a finished and complete firmware image, the folder `src/firmware_rp2040` contains a bash script which creates the images using `Docker` for the `Raspberry Pi Pico` and `Raspberry Pi Pico W` and the required boot configurations.
0 commit comments