mirror of
https://github.com/cesanta/mongoose.git
synced 2026-11-06 15:51:25 +00:00
Add modbus dashboard
This commit is contained in:
1 parent
30738f6638
commit
64ca1ad787
21 files changed
+3003
-7
No files matched your search
@@ -1,13 +1,14 @@
|
||||
CFLAGS = -W -Wall -Wextra -Wno-error -Wundef -Wshadow -Wdouble-promotion
|
||||
CFLAGS += -Wformat-truncation -fno-common -Wconversion -Wno-sign-conversion
|
||||
CFLAGS += -ffunction-sections -fdata-sections #-fmessage-length=0 -fsigned-char
|
||||
CFLAGS += -march=rv32imafc -mabi=ilp32f #-msmall-data-limit=8 -mno-save-restore
|
||||
CFLAGS += -ffunction-sections -fdata-sections
|
||||
CFLAGS += -march=rv32imafc -mabi=ilp32f
|
||||
CFLAGS += -DSYSCLK_FREQ_144MHz_HSE -I. -Ivendor -g3 -Os $(CFLAGS_EXTRA)
|
||||
|
||||
LDFLAGS = -T vendor/link.ld -nostartfiles --specs=nano.specs #--specs=nosys.specs
|
||||
LDFLAGS += -lc -lgcc -Wl,--gc-sections #-Wl,-Map=$@.map
|
||||
LDFLAGS = -T vendor/link.ld -nostartfiles --specs=nano.specs
|
||||
LDFLAGS += -lc -lgcc -Wl,--gc-sections
|
||||
|
||||
SOURCES = main.c mongoose.c vendor/system_ch32v30x.c vendor/startup_ch32v30x_D8C.S
|
||||
SOURCES = main.c mongoose.c net.c packed_fs.c vendor/system_ch32v30x.c vendor/startup_ch32v30x_D8C.S
|
||||
CFLAGS += -DHTTP_URL=\"http://0.0.0.0/\" -DHTTPS_URL=\"https://0.0.0.0/\"
|
||||
|
||||
ifeq ($(OS),Windows_NT)
|
||||
RM = cmd /C del /Q /F /S
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
#include "hal.h"
|
||||
#include "mongoose.h"
|
||||
#include "net.h"
|
||||
|
||||
#define BTN_PIN PIN('B', 3) // On-board user button
|
||||
#define LED1_PIN PIN('A', 15) // On-board red LED
|
||||
@@ -105,7 +106,8 @@ int main(void) {
|
||||
}
|
||||
|
||||
MG_INFO(("Initialising application..."));
|
||||
mg_http_listen(&mgr, "http://0.0.0.0", fn, NULL);
|
||||
mg_http_listen(&mgr, "http://0.0.0.0:8000", fn, NULL);
|
||||
web_init(&mgr);
|
||||
|
||||
MG_INFO(("Starting event loop"));
|
||||
for (;;) {
|
||||
|
||||
@@ -6,7 +6,8 @@
|
||||
#define MG_ENABLE_TCPIP 1
|
||||
#define MG_ENABLE_CUSTOM_MILLIS 1
|
||||
#define MG_ENABLE_CUSTOM_RANDOM 1
|
||||
//#define MG_ENABLE_PACKED_FS 1
|
||||
#define MG_ENABLE_PACKED_FS 1
|
||||
#define MG_ENABLE_FILE 0
|
||||
#define MG_ENABLE_DRIVER_STM32 1
|
||||
#define MG_ENABLE_LINES 1
|
||||
#define MG_IO_SIZE 256
|
||||
@@ -0,0 +1 @@
|
||||
../../modbus-dashboard/net.c
|
||||
@@ -0,0 +1 @@
|
||||
../../modbus-dashboard/net.h
|
||||
@@ -0,0 +1 @@
|
||||
../../modbus-dashboard/packed_fs.c
|
||||
Reference in new issue
Block a user