Skip to content

Commit

Permalink
Update trainings for Luos-engine 3.X.X
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-rabault committed Dec 1, 2023
1 parent 9b0f3ed commit 30cacea
Show file tree
Hide file tree
Showing 150 changed files with 600 additions and 328 deletions.
6 changes: 3 additions & 3 deletions 1_First_Service/Solution/Apps/Blinker_app/blinker.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ volatile time_luos_t blinktime;
unsigned long my_time; // Used to keep track of time
volatile control_t control_app;

static void Blinker_MsgHandler(service_t *service, msg_t *msg);
static void Blinker_MsgHandler(service_t *service, const msg_t *msg);

void Blinker_Init(void)
{
Expand Down Expand Up @@ -70,7 +70,7 @@ void Blinker_Loop(void)
}
}

static void Blinker_MsgHandler(service_t *service, msg_t *msg)
static void Blinker_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == CONTROL)
{
Expand All @@ -83,4 +83,4 @@ static void Blinker_MsgHandler(service_t *service, msg_t *msg)
TimeOD_TimeFromMsg((time_luos_t *)&blinktime, msg);
return;
}
}
}
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/Apps/Blinker_app/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"licence": "MIT",
"dependencies": {
"luos/luos_engine": "^2.6.3"
"luos/luos_engine": "^3.0.0"
}
}
}
2 changes: 1 addition & 1 deletion 1_First_Service/Solution/Arduino/lib/Led/led.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "led.h"
#include "Arduino.h"

void Led_MsgHandler(service_t *service, msg_t *msg)
void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/Arduino/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
11 changes: 7 additions & 4 deletions 1_First_Service/Solution/Arduino/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -31,22 +31,25 @@ lib_ldf_mode =off
build_unflags = -Os
build_flags =
-O1
-include node_config.h
-D LUOSHAL=ATSAMD21_ARDUINO
-D GATEFORMAT=TinyJSON
-D ROBUSHAL=ATSAMD21_ARDUINO
-D PIPEMODE=SERIAL
-D PIPEHAL=ARDUINO
-D LUOSHAL=ATSAMD21_ARDUINO
lib_deps =
luos_engine@^2.6.3
luos_engine@^3.0.0
robus_network
Led
Blinker_App
Pipe
Gate
lib_extra_dirs =
$PROJECT_DIR/../../../../
$PROJECT_DIR/../../../../luos_engine/tool_services
$PROJECT_DIR/../../../../luos_engine/network
$PROJECT_DIR/../Apps
lib


[env:arduino]
board = mkrzero #mkrzero, mkr1000USB or any SAMD21 based Arduino board
platform_packages = framework-arduino-samd@https://github.com/Luos-io/Arduino_core.git
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-F072RB/lib/Led/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "led.h"
#include "gpio.h"

static void Led_MsgHandler(service_t *service, msg_t *msg);
static void Led_MsgHandler(service_t *service, const msg_t *msg);

void Led_Init(void)
{
Expand All @@ -17,7 +17,7 @@ void Led_Init(void)

void Led_Loop(void) {}

static void Led_MsgHandler(service_t *service, msg_t *msg)
static void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/NUCLEO-F072RB/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
14 changes: 9 additions & 5 deletions 1_First_Service/Solution/NUCLEO-F072RB/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,24 @@ lib_ldf_mode =off
build_unflags = -Os
build_flags =
-O1
-include node_config.h
-D GATEFORMAT=TinyJSON
-D ROBUSHAL=STM32F0
-DUSE_HAL_DRIVER
-DUSE_FULL_LL_DRIVER
-DLUOSHAL=STM32F0
-D LUOSHAL=STM32F0
-D GATEFORMAT=TinyJSON
-D PIPEMODE=SERIAL
-D PIPEHAL=NUCLEO-F0
lib_deps =
Luos_engine@^2.9.2
lib_deps =
luos_engine@^3.0.0
robus_network
Led
Blinker_App
Pipe
Gate
lib_extra_dirs =
$PROJECT_DIR/../../../../
$PROJECT_DIR/../../../../luos_engine/tool_services
$PROJECT_DIR/../../../../luos_engine/network
$PROJECT_DIR/../Apps
lib
debug_tool = stlink
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-F401RE/lib/Led/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "led.h"
#include "gpio.h"

static void Led_MsgHandler(service_t *service, msg_t *msg);
static void Led_MsgHandler(service_t *service, const msg_t *msg);

void Led_Init(void)
{
Expand All @@ -17,7 +17,7 @@ void Led_Init(void)

void Led_Loop(void) {}

static void Led_MsgHandler(service_t *service, msg_t *msg)
static void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-F401RE/lib/Led/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"licence": "MIT",
"dependencies": {
"luos/luos_engine": "^2.6.3"
"luos/luos_engine": "^3.0.0"
}
}
}
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/NUCLEO-F401RE/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
12 changes: 8 additions & 4 deletions 1_First_Service/Solution/NUCLEO-F401RE/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,24 @@ lib_ldf_mode =off
build_unflags = -Os
build_flags =
-O1
-include node_config.h
-D GATEFORMAT=TinyJSON
-D ROBUSHAL=STM32F4
-DUSE_HAL_DRIVER
-DUSE_FULL_LL_DRIVER
-DLUOSHAL=STM32F4
-D LUOSHAL=STM32F4
-D PIPEMODE=SERIAL
-D PIPEHAL=NUCLEO-F4
lib_deps =
Luos_engine@^2.9.2
lib_deps =
luos_engine@^3.0.0
robus_network
Led
Blinker_App
Pipe
Gate
lib_extra_dirs =
$PROJECT_DIR/../../../../
$PROJECT_DIR/../../../../luos_engine/tool_services
$PROJECT_DIR/../../../../luos_engine/network
$PROJECT_DIR/../Apps
lib
debug_tool = stlink
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-F410RB/lib/Led/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "led.h"
#include "gpio.h"

static void Led_MsgHandler(service_t *service, msg_t *msg);
static void Led_MsgHandler(service_t *service, const msg_t *msg);

void Led_Init(void)
{
Expand All @@ -17,7 +17,7 @@ void Led_Init(void)

void Led_Loop(void) {}

static void Led_MsgHandler(service_t *service, msg_t *msg)
static void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-F410RB/lib/Led/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"licence": "MIT",
"dependencies": {
"luos/luos_engine": "^2.6.3"
"luos/luos_engine": "^3.0.0"
}
}
}
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/NUCLEO-F410RB/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
12 changes: 8 additions & 4 deletions 1_First_Service/Solution/NUCLEO-F410RB/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,24 @@ lib_ldf_mode =off
build_unflags = -Os
build_flags =
-O1
-include node_config.h
-D GATEFORMAT=TinyJSON
-D ROBUSHAL=STM32F4
-DUSE_HAL_DRIVER
-DUSE_FULL_LL_DRIVER
-DLUOSHAL=STM32F4
-D LUOSHAL=STM32F4
-D PIPEMODE=SERIAL
-D PIPEHAL=NUCLEO-F4
lib_deps =
Luos_engine@^2.9.2
lib_deps =
luos_engine@^3.0.0
robus_network
Led
Blinker_App
Pipe
Gate
lib_extra_dirs =
$PROJECT_DIR/../../../../
$PROJECT_DIR/../../../../luos_engine/tool_services
$PROJECT_DIR/../../../../luos_engine/network
$PROJECT_DIR/../Apps
lib
debug_tool = stlink
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-G431KB/lib/Led/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "led.h"
#include "gpio.h"

static void Led_MsgHandler(service_t *service, msg_t *msg);
static void Led_MsgHandler(service_t *service, const msg_t *msg);

void Led_Init(void)
{
Expand All @@ -17,7 +17,7 @@ void Led_Init(void)

void Led_Loop(void) {}

static void Led_MsgHandler(service_t *service, msg_t *msg)
static void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-G431KB/lib/Led/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"licence": "MIT",
"dependencies": {
"luos/luos_engine": "^2.6.3"
"luos/luos_engine": "^3.0.0"
}
}
}
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/NUCLEO-G431KB/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
12 changes: 8 additions & 4 deletions 1_First_Service/Solution/NUCLEO-G431KB/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,24 @@ lib_ldf_mode =off
build_unflags = -Os
build_flags =
-O1
-include node_config.h
-D ROBUSHAL=STM32G4
-D GATEFORMAT=TinyJSON
-DUSE_HAL_DRIVER
-DUSE_FULL_LL_DRIVER
-DLUOSHAL=STM32G4
-D LUOSHAL=STM32G4
-D PIPEMODE=SERIAL
-D PIPEHAL=NUCLEO-G431
lib_deps =
Luos_engine@^2.9.2
lib_deps =
luos_engine@^3.0.0
robus_network
Led
Blinker_App
Pipe
Gate
lib_extra_dirs =
$PROJECT_DIR/../../../../
$PROJECT_DIR/../../../../luos_engine/tool_services
$PROJECT_DIR/../../../../luos_engine/network
$PROJECT_DIR/../Apps
lib
debug_tool = stlink
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-L432KC/lib/Led/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "led.h"
#include "gpio.h"

static void Led_MsgHandler(service_t *service, msg_t *msg);
static void Led_MsgHandler(service_t *service, const msg_t *msg);

void Led_Init(void)
{
Expand All @@ -17,7 +17,7 @@ void Led_Init(void)

void Led_Loop(void) {}

static void Led_MsgHandler(service_t *service, msg_t *msg)
static void Led_MsgHandler(service_t *service, const msg_t *msg)
{
if (msg->header.cmd == IO_STATE)
{
Expand Down
4 changes: 2 additions & 2 deletions 1_First_Service/Solution/NUCLEO-L432KC/lib/Led/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"licence": "MIT",
"dependencies": {
"luos/luos_engine": "^2.6.3"
"luos/luos_engine": "^3.0.0"
}
}
}
6 changes: 5 additions & 1 deletion 1_First_Service/Solution/NUCLEO-L432KC/node_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
* # Usage
* This file should be place a the root folder of your project and include
* where build flag preprocessor definitions are define in your IDE
* -include node_config.h
*
-D GATEFORMAT=TinyJSON
-DROBUSHAL=?
-D PIPEMODE=SERIAL
-D PIPEHAL=?
*
* @author Luos
* @version 0.0.0
Expand Down
Loading

0 comments on commit 30cacea

Please sign in to comment.