Skip to content

Commit

Permalink
Sync with local development
Browse files Browse the repository at this point in the history
  • Loading branch information
vanvught committed Jan 14, 2024
1 parent a8e4499 commit 962454d
Show file tree
Hide file tree
Showing 190 changed files with 9,276 additions and 8,607 deletions.
3 changes: 2 additions & 1 deletion firmware-template-gd32/Includes.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
$(info "Includes.mk")

INCLUDES:=-I./include -I../include -I../lib-configstore/include -I../lib-flash/include -I../lib-flashcode/include -I../lib-hal/include -I../lib-debug/include
INCLUDES:=-I./include -I../include
INCLUDES+=-I../lib-debug/include
INCLUDES+=$(addprefix -I,$(EXTRA_INCLUDES))
INCLUDES+=-I../firmware-template-gd32/include
INCLUDES+=-I../firmware-template-gd32/template
Expand Down
2 changes: 1 addition & 1 deletion firmware-template-gd32/Rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ COPS+=-ffunction-sections -fdata-sections
COPS+=-Wall -Werror -Wpedantic -Wextra -Wunused -Wsign-conversion -Wconversion
COPS+=-Wduplicated-cond -Wlogical-op

CPPOPS=-std=c++11
CPPOPS=-std=c++20
CPPOPS+=-Wnon-virtual-dtor -Woverloaded-virtual -Wnull-dereference -fno-rtti -fno-exceptions -fno-unwind-tables
CPPOPS+=-Wuseless-cast -Wold-style-cast
CPPOPS+=-fno-threadsafe-statics
Expand Down
4 changes: 3 additions & 1 deletion firmware-template-gd32/lib/Rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ SRCDIR=src src/gd32 $(EXTRA_SRCDIR)

include ../firmware-template-gd32/Includes.mk

INCLUDES+=-I../lib-configstore/include -I../lib-device/include -I../lib-display/include -I../lib-flash/include -I../lib-flashcode/include -I../lib-hal/include -I../lib-lightset/include -I../lib-network/include

DEFINES:=$(addprefix -D,$(DEFINES))
DEFINES+=-D_TIME_STAMP_YEAR_=$(shell date +"%Y") -D_TIME_STAMP_MONTH_=$(shell date +"%-m") -D_TIME_STAMP_DAY_=$(shell date +"%-d")

Expand All @@ -39,7 +41,7 @@ COPS+=-ffunction-sections -fdata-sections
COPS+=-Wall -Werror -Wpedantic -Wextra -Wunused -Wsign-conversion -Wconversion
COPS+=-Wduplicated-cond -Wlogical-op

CPPOPS=-std=c++11
CPPOPS=-std=c++20
CPPOPS+=-Wnon-virtual-dtor -Woverloaded-virtual -Wnull-dereference -fno-rtti -fno-exceptions -fno-unwind-tables
CPPOPS+=-Wuseless-cast -Wold-style-cast
CPPOPS+=-fno-threadsafe-statics
Expand Down
13 changes: 0 additions & 13 deletions gd32_emac_artnet_pixel_dmx_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -101,12 +97,6 @@ void main() {
fw.Print("Art-Net 4 Pixel controller {16x 4 Universes} / 2x DMX");
nw.Print();

display.TextStatus(NetworkConst::MSG_MDNS_CONFIG, Display7SegmentMessage::INFO_MDNS_CONFIG, CONSOLE_YELLOW);

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

display.TextStatus(ArtNetMsgConst::PARAMS, Display7SegmentMessage::INFO_NODE_PARMAMS, CONSOLE_YELLOW);

ArtNetNode node;
Expand Down Expand Up @@ -280,9 +270,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222230;
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704725179;
11 changes: 0 additions & 11 deletions gd32_emac_artnet_pixel_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -94,10 +90,6 @@ void main() {
fw.Print("Art-Net 4 Pixel controller {8x 4 Universes}");
nw.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

display.TextStatus(ArtNetMsgConst::PARAMS, Display7SegmentMessage::INFO_NODE_PARMAMS, CONSOLE_YELLOW);

ArtNetNode node;
Expand Down Expand Up @@ -230,9 +222,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
2 changes: 1 addition & 1 deletion gd32_emac_artnet_pixel_multi/include/sofware_version_id.h
Original file line number Diff line number Diff line change
@@ -1 +1 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222259;
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1702811908;
11 changes: 0 additions & 11 deletions gd32_emac_ddp_pixel_dmx_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -98,10 +94,6 @@ void main() {
mDns.ServiceRecordAdd(nullptr, mdns::Services::DDP, "type=display");
mDns.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

// LightSet A - Pixel - 64 Universes

PixelDmxConfiguration pixelDmxConfiguration;
Expand Down Expand Up @@ -223,9 +215,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
2 changes: 1 addition & 1 deletion gd32_emac_ddp_pixel_dmx_multi/include/sofware_version_id.h
Original file line number Diff line number Diff line change
@@ -1 +1 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222269;
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1702811913;
11 changes: 0 additions & 11 deletions gd32_emac_ddp_pixel_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -92,10 +88,6 @@ void main() {
mDns.ServiceRecordAdd(nullptr, mdns::Services::DDP, "type=display");
mDns.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

PixelDmxConfiguration pixelDmxConfiguration;

PixelDmxParams pixelDmxParams;
Expand Down Expand Up @@ -196,9 +188,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
2 changes: 1 addition & 1 deletion gd32_emac_ddp_pixel_multi/include/sofware_version_id.h
Original file line number Diff line number Diff line change
@@ -1 +1 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222278;
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1702811915;
11 changes: 0 additions & 11 deletions gd32_emac_debug/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -115,10 +111,6 @@ void main() {
fw.Print("Debug");
nw.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

display.SetTitle("Debug");
display.Set(2, displayudf::Labels::HOSTNAME);
display.Set(3, displayudf::Labels::IP);
Expand Down Expand Up @@ -164,9 +156,6 @@ void main() {
remoteConfig.Run();
configStore.Flash();
mDns.Run();
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();

Expand Down
11 changes: 0 additions & 11 deletions gd32_emac_e131_pixel_dmx_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -100,10 +96,6 @@ void main() {
fw.Print("sACN E1.31 Pixel controller {8x 4 Universes} / 2x DMX");
nw.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

display.TextStatus(E131MsgConst::PARAMS, Display7SegmentMessage::INFO_BRIDGE_PARMAMS, CONSOLE_YELLOW);

E131Bridge bridge;
Expand Down Expand Up @@ -277,9 +269,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
3 changes: 2 additions & 1 deletion gd32_emac_e131_pixel_dmx_multi/include/sofware_version_id.h
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222298;
// Generated do 14 sep 2023 12:39:45 CEST
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1694687985;
11 changes: 0 additions & 11 deletions gd32_emac_e131_pixel_multi/firmware/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@

#include "mdns.h"

#if defined (ENABLE_HTTPD)
# include "httpd/httpd.h"
#endif

#include "displayudf.h"
#include "displayudfparams.h"
#include "displayhandler.h"
Expand Down Expand Up @@ -94,10 +90,6 @@ void main() {
fw.Print("sACN E1.31 Pixel controller {8x 4 Universes}");
nw.Print();

#if defined (ENABLE_HTTPD)
HttpDaemon httpDaemon;
#endif

display.TextStatus(E131MsgConst::PARAMS, Display7SegmentMessage::INFO_BRIDGE_PARMAMS, CONSOLE_YELLOW);

E131Bridge bridge;
Expand Down Expand Up @@ -225,9 +217,6 @@ void main() {
mDns.Run();
#if defined (NODE_RDMNET_LLRP_ONLY)
llrpOnlyDevice.Run();
#endif
#if defined (ENABLE_HTTPD)
httpDaemon.Run();
#endif
display.Run();
hw.Run();
Expand Down
3 changes: 2 additions & 1 deletion gd32_emac_e131_pixel_multi/include/sofware_version_id.h
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1704222308;
// Generated do 14 sep 2023 12:39:46 CEST
constexpr uint32_t DEVICE_SOFTWARE_VERSION_ID=1694687986;
2 changes: 1 addition & 1 deletion lib-artnet/Rules.mk
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
EXTRA_INCLUDES+=../lib-lightset/include ../lib-properties/include ../lib-hal/include ../lib-network/include ../lib-configstore/include
EXTRA_INCLUDES+=../lib-lightset/include ../lib-properties/include ../lib-network/include

ifneq ($(MAKE_FLAGS),)
ifeq ($(findstring NODE_ARTNET,$(MAKE_FLAGS)), NODE_ARTNET)
Expand Down
21 changes: 9 additions & 12 deletions lib-artnet/include/artnetpolltable.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/**
* Art-Net Designed by and Copyright Artistic Licence Holdings Ltd.
*/
/* Copyright (C) 2017-2023 by Arjan van Vught mailto:info@orangepi-dmx.nl
/* Copyright (C) 2017-2024 by Arjan van Vught mailto:info@orangepi-dmx.nl
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
Expand Down Expand Up @@ -33,16 +33,13 @@

#include "artnet.h"

enum TArtNetPollInterval {
ARTNET_POLL_INTERVAL_SECONDS = 8,
ARTNET_POLL_INTERVAL_MILLIS = (ARTNET_POLL_INTERVAL_SECONDS * 1000)
};

enum TArtNetPollTableSizes {
ARTNET_POLL_TABLE_SIZE_ENRIES = 255,
ARTNET_POLL_TABLE_SIZE_NODE_UNIVERSES = 64,
ARTNET_POLL_TABLE_SIZE_UNIVERSES = 512
};
namespace artnet {
static constexpr uint32_t POLL_INTERVAL_SECONDS = 8;
static constexpr uint32_t POLL_INTERVAL_MILLIS = (POLL_INTERVAL_SECONDS * 1000U);
static constexpr uint32_t POLL_TABLE_SIZE_ENRIES = 255;
static constexpr uint32_t POLL_TABLE_SIZE_NODE_UNIVERSES = 64;
static constexpr uint32_t POLL_TABLE_SIZE_UNIVERSES = 512;
} // namespace artnet

struct TArtNetNodeEntryUniverse {
uint32_t nLastUpdateMillis;
Expand All @@ -55,7 +52,7 @@ struct TArtNetNodeEntry {
uint8_t ShortName[artnet::SHORT_NAME_LENGTH];
uint8_t LongName[artnet::LONG_NAME_LENGTH];
uint16_t nUniversesCount;
struct TArtNetNodeEntryUniverse Universe[ARTNET_POLL_TABLE_SIZE_NODE_UNIVERSES];
struct TArtNetNodeEntryUniverse Universe[artnet::POLL_TABLE_SIZE_NODE_UNIVERSES];
};

struct TArtNetPollTableUniverses {
Expand Down
4 changes: 2 additions & 2 deletions lib-artnet/src/artnetconst.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/**
* Art-Net Designed by and Copyright Artistic Licence Holdings Ltd.
*/
/* Copyright (C) 2019-2023 by Arjan van Vught mailto:info@orangepi-dmx.nl
/* Copyright (C) 2019-2024 by Arjan van Vught mailto:info@orangepi-dmx.nl
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
Expand All @@ -31,7 +31,7 @@
#include "artnetconst.h"
#include "artnet.h"

const uint8_t ArtNetConst::VERSION[] = { 1, 58 };
const uint8_t ArtNetConst::VERSION[] = { 1, 59 };

const uint8_t ArtNetConst::ESTA_ID[artnet::ESTA_SIZE] = { 0x50, 0x00 }; ///< https://tsp.esta.org/tsp/working_groups/CP/mfctrIDs.php
const uint8_t ArtNetConst::OEM_ID[] = { 0xff, 0xff }; ///< Waiting OEM from Artistic Licence Holdings Ltd.
Loading

0 comments on commit 962454d

Please sign in to comment.