Skip to content

Commit 494600b

Browse files
committed
stmhal: Add lcd.c to Makefile, and init LCD in main.
1 parent e2e9011 commit 494600b

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

stmhal/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ SRC_C = \
8383
file.c \
8484
sdcard.c \
8585
diskio.c \
86+
lcd.c \
8687

87-
# lcd.c \
8888
# servo.c \
8989
# accel.c \
9090
# timer.c \

stmhal/main.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@
3232
#include "storage.h"
3333
#include "sdcard.h"
3434
#include "ff.h"
35+
#include "lcd.h"
3536
#if 0
3637
#include "servo.h"
37-
#include "lcd.h"
3838
#include "accel.h"
3939
#include "timer.h"
4040
#include "pybwlan.h"
@@ -64,10 +64,8 @@ void flash_error(int n) {
6464

6565
void __fatal_error(const char *msg) {
6666
#if MICROPY_HW_HAS_LCD
67-
#if 0
6867
lcd_print_strn("\nFATAL ERROR:\n", 14);
6968
lcd_print_strn(msg, strlen(msg));
70-
#endif
7169
#endif
7270
for (;;) {
7371
flash_error(1);
@@ -260,12 +258,12 @@ int main(void) {
260258
switch_init();
261259
#endif
262260

263-
#if 0
264261
#if MICROPY_HW_HAS_LCD
265262
// LCD init (just creates class, init hardware by calling LCD())
266263
lcd_init();
267264
#endif
268265

266+
#if 0
269267
#if MICROPY_HW_ENABLE_SERVO
270268
// servo
271269
servo_init();

0 commit comments

Comments
 (0)