Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Any kind of network support, fix #428 #435

Merged
merged 150 commits into from
Sep 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
150 commits
Select commit Hold shift + click to select a range
edcda13
Add the IO folder and source compilation.
nicolas-rabault Apr 3, 2023
c03ace3
Move msg_alloc from Robus to IO
nicolas-rabault Mar 23, 2023
090de1a
Move topic pub/sub management from Robus to IO
nicolas-rabault Mar 23, 2023
525651c
Create filter and luos_io files
Salem-Tho Jan 5, 2023
7496508
Add an engine level configuration file
Salem-Tho Jan 5, 2023
f5fcbc2
Rename and move the robus `config.h` file into `robus_config.h`
nicolas-rabault Mar 23, 2023
5ee1459
Move struct and configurations from Robus to IO
nicolas-rabault Mar 23, 2023
a1ebc8c
Move public timestamp functions into public Luos_engine.h
nicolas-rabault Mar 30, 2023
48d530e
Add an error in case of inclusion of luos.h
nicolas-rabault Mar 23, 2023
f752b60
Clean luos_engine.h and remove unused `Luos_SetExternId`
nicolas-rabault Mar 23, 2023
be861f9
Group all topic things on a pub_sub.c file on engine/core
nicolas-rabault Mar 28, 2023
fbba385
Group all streaming functions on streaming.c/.h
nicolas-rabault Mar 31, 2023
35ab161
Update Timestamp functions API
nicolas-rabault Mar 30, 2023
31b3cdd
Move general_stats_t from luos_engine.h to service_structs.h
nicolas-rabault Mar 28, 2023
7704b7a
Remove useless node_state_t struct
nicolas-rabault Mar 28, 2023
2b3338c
Remove dynamic baudrate management
nicolas-rabault Mar 28, 2023
0053566
Group all node functions on a node.c.h
nicolas-rabault Mar 31, 2023
c6bf09c
Create a script to compile all examples as fast as possible
nicolas-rabault Mar 31, 2023
f44d0bc
Make inspector use local Pipe during compilation
nicolas-rabault Mar 31, 2023
b45d472
Remove filters disableabilty and verbose mode.
nicolas-rabault Mar 31, 2023
938eb48
Group all filter functions in a filter file
nicolas-rabault Mar 31, 2023
9d6e04f
Remove all context usage on msg_alloc
nicolas-rabault Apr 3, 2023
7a41ddd
Create Service files
nicolas-rabault Apr 4, 2023
49619b9
Group all services function into service file.
nicolas-rabault Apr 6, 2023
358549d
Update .gitignore
nicolas-rabault Apr 4, 2023
ae237a6
Remove useless Luos_EmptyNode() function
nicolas-rabault Apr 4, 2023
8147a44
Small code improvement
nicolas-rabault Apr 4, 2023
664d284
Add type filtering on filter file
nicolas-rabault Apr 4, 2023
6812c05
Remove the redundant ll_service_number from robus context
nicolas-rabault Apr 4, 2023
000575a
Remove useless baudrate variable
nicolas-rabault Apr 4, 2023
07b8b3e
Move ll_service_t into Service_t, only one struct remain now.
nicolas-rabault Apr 5, 2023
9e1e024
Move robus init and loop things into IO
nicolas-rabault Apr 6, 2023
8944f80
Move topology management to LuosIO
nicolas-rabault Apr 6, 2023
7534573
Create a phy.h/c files defining phy structs
nicolas-rabault Apr 6, 2023
ab2035e
Move back rx and tx init into robus
nicolas-rabault Apr 6, 2023
dce8765
Manage phy instantiation
nicolas-rabault Apr 6, 2023
e3825c7
Move reception filtering into filter except for Robus exceptions
nicolas-rabault Apr 11, 2023
e4b83ff
Fix timestamp msg reception computation
nicolas-rabault Apr 11, 2023
f7439b1
Reshape reception and almost completely shortcut msg_tasks
nicolas-rabault Apr 12, 2023
b245d60
Assert if buffer full only on RX. TX can wait to load the buffer agai…
nicolas-rabault Apr 14, 2023
43a42b5
Fix addressing generation at detection start.
nicolas-rabault Apr 17, 2023
5f118f3
Fix double detection process occurring at the same time, fix #229
nicolas-rabault Apr 17, 2023
083b3b6
Fix collision management
nicolas-rabault Apr 18, 2023
5619724
[Gate] Add a small check if a service is excluded during detection.
nicolas-rabault Apr 18, 2023
b279fdf
Remove verbose mode
nicolas-rabault Apr 17, 2023
107c9a2
Do not allow RX dropping during reception
nicolas-rabault Apr 18, 2023
2d2ae1d
Fix data dropping occurring during re-init
nicolas-rabault Apr 18, 2023
a0ec64c
Fix multi-node detection
nicolas-rabault Apr 19, 2023
5c1a2c5
RX CRC optimization
nicolas-rabault Apr 19, 2023
2f3a122
Improve RX/TX comment on Robus
nicolas-rabault Apr 19, 2023
aaa6e43
Remove useless compiled files on SAMD21XPLAINED example
nicolas-rabault Apr 26, 2023
1e817d2
Move CRC_SIZE definition from Alloc to robus config
nicolas-rabault Apr 19, 2023
b9144c2
Engine TX is passed to LuosIO RX normal process
nicolas-rabault Apr 18, 2023
6a8f4c7
Improve unit tests organization
nicolas-rabault May 3, 2023
efd61c8
Add filter unit test
nicolas-rabault May 3, 2023
2610c1c
Add luos_phy unit test
nicolas-rabault May 3, 2023
1863887
Add luos_io unit test
nicolas-rabault May 5, 2023
a34d44d
Improve UNIT_TEST_RUN macro to correctly manage function name passing…
nicolas-rabault May 5, 2023
24753d3
Improve pub_sub unit tests
nicolas-rabault May 5, 2023
04aa844
Remove useless main.h Od tests files
nicolas-rabault May 29, 2023
fafe882
Improve timestamp unit tests
nicolas-rabault May 31, 2023
2062564
Improve routing table unit tests
nicolas-rabault May 31, 2023
df9d4a3
Add streaming unit test
nicolas-rabault May 31, 2023
1953b65
Add service unit test
nicolas-rabault Jun 1, 2023
02b1f2a
Add node unit test
nicolas-rabault Jun 1, 2023
b157634
Remove unused Luos_SetFilterState function
nicolas-rabault Jun 1, 2023
91cbec5
Fix some warnings
nicolas-rabault Jun 5, 2023
da5e7be
Move compilation error using `example_build.py` to err.log file
nicolas-rabault Jun 5, 2023
9c053e4
Fix some windows unit_test compilation optimization mistakes
nicolas-rabault Jun 6, 2023
c82d9c6
Improve luos_engine unit test
nicolas-rabault Jun 6, 2023
6405a1b
Exclude some test for windows because it fail to execute it
nicolas-rabault Jun 6, 2023
e9910d0
Enable test coverage report
nicolas-rabault Jun 5, 2023
51f8a9f
Minor code cleanup.
nicolas-rabault Jun 9, 2023
15819d3
Fix a missing node init in case of detection start message reception
nicolas-rabault Jun 9, 2023
2566b11
[Gate]Update data_manager to avoid to avoid hazardous function access…
nicolas-rabault Jun 9, 2023
a435647
Secure job removal
nicolas-rabault Jun 9, 2023
5eebf1d
Fix a memory leak in case of dead target
nicolas-rabault Jun 9, 2023
4399fb0
Separate allocation and referencing of the allocation avoiding memory…
nicolas-rabault Jun 9, 2023
89fc79d
Move data_ptr in alloc if there is no space for at least a header.
nicolas-rabault Jun 12, 2023
ba1cce5
Secure job.phy_data initialization avoiding data-race during the crea…
nicolas-rabault Jun 12, 2023
eb234a4
Avoid potential job removal when system have been reseted during a tr…
nicolas-rabault Jun 12, 2023
8b3d34a
Fix phy_data protection
nicolas-rabault Jun 12, 2023
4621de7
Avoid assert in case of corrupted message reception. Properly trash it.
nicolas-rabault Jun 12, 2023
5032229
Fix daisy chained detection infinite loop due to msg_dispatch recursi…
nicolas-rabault Jun 12, 2023
b63d8c3
!fix corrupted messages
nicolas-rabault Jun 12, 2023
c174d48
Modify job management to avoid any job pointer movement allowing to s…
nicolas-rabault Jun 13, 2023
2000d4b
Clear auto-refresh when we clear service IDs.
nicolas-rabault Jun 13, 2023
4323a23
Modify aloc slots management avoiding pointer movement and limiting I…
nicolas-rabault Jun 15, 2023
89ba9a0
Secure detection start occuring durring a transmission
nicolas-rabault Jun 16, 2023
db15778
Secure job and alloc slot management from dataraces and reduce IRQ of…
nicolas-rabault Jun 16, 2023
db96274
bootloader cleanup
nicolas-rabault Jun 16, 2023
ae73554
Separate Robus and Update detection allowing up to 254 phy with 254 p…
nicolas-rabault Jun 20, 2023
713ff72
Simplify bootloader to make it a standard service and be less intrica…
nicolas-rabault Jun 26, 2023
dbf29d9
Rename `bootloader_core` into `luos_bootloader`
nicolas-rabault Jun 26, 2023
baaa76a
Fix some typo
nicolas-rabault Jul 4, 2023
5f7044a
Change IRQ management allowing phy to reference specific IRQ manageme…
nicolas-rabault Jul 4, 2023
5973869
Make Robus an independant package
nicolas-rabault Jul 4, 2023
dc6f258
Modify master detection to be non-blocking. This allows networks to m…
nicolas-rabault Jul 5, 2023
8c7a6de
Add a Pure Arduino Luos HAL
nicolas-rabault Jul 10, 2023
ca15742
Secure Pipe using Serial for STM32G4 clock configuration
nicolas-rabault Jul 13, 2023
c1f8950
Optimize freeRTOS example to fit in RAM
nicolas-rabault Jul 17, 2023
0718163
Create a serial_network
nicolas-rabault Jul 4, 2023
c3ddb9b
OK serial test with Native gate and L0 button
nicolas-rabault Jul 7, 2023
5a721da
OK serial test with native gate and G474 and G431 button
nicolas-rabault Jul 11, 2023
d60e27e
OK serial test with Native gate and STM32L4 button
nicolas-rabault Jul 11, 2023
60f86af
OK serial test with Native gate and STM32F4 button
nicolas-rabault Jul 11, 2023
418b417
OK serial test with Native gate and Arduino button and led, fix #440
nicolas-rabault Jul 10, 2023
c4c7094
Improve Luos configuration parameters
nicolas-rabault Jul 18, 2023
e74f10a
Hide uselees routing function to users
nicolas-rabault Jul 18, 2023
80100f4
Improve Robus configuration flags naming
nicolas-rabault Jul 19, 2023
9815418
Add a serial_hal_config.h file
nicolas-rabault Jul 19, 2023
6ed4ed2
Improve luos_phy.h public interface and adapt robus and Serial
nicolas-rabault Jul 19, 2023
54d2280
!fix multi-phy
nicolas-rabault Aug 28, 2023
2383731
Improve C++ compatibility by making it natively compilable in a C++ env
nicolas-rabault Aug 28, 2023
1a0bf00
Remove networks from coverage, networks are very difficult to unit te…
nicolas-rabault Aug 2, 2023
085e496
Fix format
nicolas-rabault Aug 2, 2023
07c4998
Remove Inspector because we don't maintain it anymore.
nicolas-rabault Aug 3, 2023
9bac6bf
Make a clean BAUDRATE configuration for networks
nicolas-rabault Aug 28, 2023
8d2b30e
Improve native timestamping precision
nicolas-rabault Aug 4, 2023
c641f20
Enable multi-phy capabilities
nicolas-rabault Aug 11, 2023
45d11d1
Add a print for native assert
nicolas-rabault Aug 25, 2023
288875b
Add a trace print on Gate segfault to catch it one day perhaps.
nicolas-rabault Aug 25, 2023
b4034ba
Improve ST Serial reception by removing RX IRQ and improve function n…
nicolas-rabault Aug 25, 2023
1dae135
Remove telemetry
nicolas-rabault Aug 25, 2023
db34245
Manage multi-message in one Serial burst
nicolas-rabault Aug 25, 2023
a9af943
Allow synchronized nodes to manage timestamping without any different…
nicolas-rabault Aug 25, 2023
e25326c
[OD] rename the `_private` var into `raw` to explicitely allow users …
nicolas-rabault Aug 28, 2023
1e96760
Fix some OD warnings on `Controller_motor` example
nicolas-rabault Aug 28, 2023
82001f8
Add a user_context pointer on services and apply it on DXL example
nicolas-rabault Aug 28, 2023
1802b42
Fix Serial HAL for Native on Linux and windows, fix #442
nicolas-rabault Aug 29, 2023
f0de043
Improve compilation messaging presentation
nicolas-rabault Aug 31, 2023
38bc651
Remove some useless reset on detetion and increase some timing allowi…
nicolas-rabault Aug 31, 2023
e98e990
Fix the detection flag init
nicolas-rabault Aug 31, 2023
44c03ff
Fix and remove deprecated unit test
nicolas-rabault Aug 31, 2023
3174317
Fix some code format
nicolas-rabault Aug 31, 2023
43c9a08
Fix a typo
nicolas-rabault Sep 5, 2023
c152eaa
Secure Robus initialization by setting Callback before enabling the h…
nicolas-rabault Sep 5, 2023
7b83495
[Gate] Allow user to put custom conversion on project lib
nicolas-rabault Sep 5, 2023
c36ddac
Fix assert infinite re-entrance on Gate
nicolas-rabault Sep 11, 2023
bf0ac48
Avoid asserts appening sometime during the reset_detection
nicolas-rabault Sep 11, 2023
31943f2
Clean Native Serial HAL
nicolas-rabault Sep 11, 2023
85c0800
Secure potential RX segfault if the RX buffer is smaller than the rec…
nicolas-rabault Sep 11, 2023
6f958b4
Fix Gate compilation on windows
nicolas-rabault Sep 12, 2023
7fb6737
Fix a small datarace on RX
nicolas-rabault Sep 12, 2023
b32fa7c
Improve serial Loop on ST MCU
nicolas-rabault Sep 12, 2023
3c3e8ce
Fix Serial
nicolas-rabault Sep 12, 2023
23428f6
Fix Native Gate node_config
nicolas-rabault Sep 12, 2023
25f9ee3
Fix a Robus reception byte count mistake making big messages potentia…
nicolas-rabault Sep 14, 2023
a74df88
[SERIAL] Fix STM HAL DMA received size computation datarace in case o…
nicolas-rabault Sep 14, 2023
bd5778f
[SERIAL] Secure messy RX interpretation
nicolas-rabault Sep 14, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
11 changes: 11 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,24 @@ jobs:
# Run Unit tests
platformio test -vvv

- if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get install -y lcov
lcov -d .pio/build/native/ -c -o lcov.info
lcov --remove lcov.info '*/usr/*' '*/Platforms/*' '*/bootloader/*' '*/.pio/*' '*/HAL/*' '*/test/*' '*/network/*' -o lcov.info

- if: matrix.os == 'ubuntu-latest'
name: Coveralls
uses: coverallsapp/github-action@v2

unit-tests:
name: Unit tests
needs: tests-run
runs-on: ubuntu-latest
steps:
- run: echo "Tests succeed!"


code-format:
name: Code format
runs-on: ubuntu-latest
Expand Down
86 changes: 33 additions & 53 deletions .github/workflows/pio_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:
pio package publish --owner luos --non-interactive
cd ../..

deploy_inspector:
deploy_pipe:
needs: check_valid_tag
runs-on: ubuntu-latest
steps:
Expand All @@ -123,64 +123,44 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install platformio
- name: publish inspector tool
- name: publish pipe driver
env:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PIO_TOKEN }}
run: |
# ***** Inspector publication *****
cd tool_services/inspector
mkdir examples

# Arduino
mkdir examples/Arduino
mkdir examples/Arduino/serial
cp -r ../../examples/projects/Arduino/inspector_serialcom/* examples/Arduino/serial/

# l0
mkdir examples/l0
mkdir examples/l0/serial
cp -r ../../examples/projects/l0/inspector_serialcom/* examples/l0/serial/

# NUCLEO-F072RB
mkdir examples/NUCLEO-F072RB
mkdir examples/NUCLEO-F072RB/serial
cp -r ../../examples/projects/NUCLEO-F072RB/inspector_serialcom/* examples/NUCLEO-F072RB/serial/

# NUCLEO-F401RE
mkdir examples/NUCLEO-F401RE
mkdir examples/NUCLEO-F401RE/serial
cp -r ../../examples/projects/NUCLEO-F401RE/inspector_serialcom/* examples/NUCLEO-F401RE/serial/

# NUCLEO-F410RB
mkdir examples/NUCLEO-F410RB
mkdir examples/NUCLEO-F410RB/serial
cp -r ../../examples/projects/NUCLEO-F410RB/inspector_serialcom/* examples/NUCLEO-F410RB/serial/

# NUCLEO-G431KB
mkdir examples/NUCLEO-G431KB
mkdir examples/NUCLEO-G431KB/serial
cp -r ../../examples/projects/NUCLEO-G431KB/inspector_serialcom/* examples/NUCLEO-G431KB/serial/

# NUCLEO-G474RE
mkdir examples/NUCLEO-G474RE
mkdir examples/NUCLEO-G474RE/serial
cp -r ../../examples/projects/NUCLEO-G474RE/inspector_serialcom/* examples/NUCLEO-G474RE/serial/
# ***** Pipe publication *****
cd tool_services/pipe
# We don't publish examples with this one.

# NUCLEO-L432KC
mkdir examples/NUCLEO-L432KC
mkdir examples/NUCLEO-L432KC/serial
cp -r ../../examples/projects/NUCLEO-L432KC/inspector_serialcom/* examples/NUCLEO-L432KC/serial/
pio package pack
pio package publish --owner luos --non-interactive
cd ../..

# STM32F4-discovery
mkdir examples/STM32F4-discovery
mkdir examples/STM32F4-discovery/serial
cp -r ../../examples/projects/STM32F4-discovery/inspector_serialcom/* examples/STM32F4-discovery/serial/
deploy_robus:
needs: check_valid_tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: "3.x"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install platformio
- name: publish robus network
env:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PIO_TOKEN }}
run: |
# ***** Robus network publication *****
cd network/robus_network
# We don't publish examples with this one.

pio package pack
pio package publish --owner luos --non-interactive
cd ../..

deploy_pipe:
deploy_serial:
needs: check_valid_tag
runs-on: ubuntu-latest
steps:
Expand All @@ -193,14 +173,14 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install platformio
- name: publish pipe driver
- name: publish robus network
env:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PIO_TOKEN }}
run: |
# ***** Pipe publication *****
cd tool_services/pipe
# ***** Serial network publication *****
cd network/serial_network
# We don't publish examples with this one.

pio package pack
pio package publish --owner luos --non-interactive
cd ../..
cd ../..
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
**/.gitignore
*.out
*.log
*.info
*.profraw
cov/*
/examples/projects/NUCLEO-G431KB/button/.mxproject
/examples/projects/NUCLEO-G431KB/button/Button.gpdsc
/examples/projects/NUCLEO-L432KC/button/Button.gpdsc
Expand All @@ -31,4 +34,7 @@
/examples/projects/SAMD21XPLAINED/bootloader/firmware/luos_bootloader_samd21j18a.X/build/
/examples/projects/SAMD21XPLAINED/bootloader/firmware/luos_bootloader_samd21j18a.X/.generated_files/
/examples/projects/SAMD21XPLAINED/bootloader/firmware/luos_bootloader_samd21j18a.X/dist/
examples/projects/ESP32/button/sdkconfig.esp32dev
examples/projects/ESP32/led/sdkconfig.esp32dev
tool_services/pipe/WS/ARDUINO/arduinoWebSockets/
mongoose/
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,3 @@ Luos proposes organized and effective development practices, guaranteeing develo

* → Try on your own with the [get started](https://www.luos.io/tutorials/get-started)
* → Consult the full [documentation](https://www.luos.io/docs)

## Disclaimer
Using Platformio, this library compilation send some anonymous information to Luos allowing to improve Luos_engine experience.
To disable the telemetry please add "-DNOTELEMETRY" as a compilation flag on your platformio.ini file.
190 changes: 190 additions & 0 deletions engine/HAL/ARDUINO/luos_hal.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,190 @@
/******************************************************************************
* @file luosHAL
* @brief Luos Hardware Abstration Layer. Describe Low layer fonction
* @MCU Family ATSAMD21
* @author Luos
* @version 0.0.0
******************************************************************************/
#include "luos_hal.h"

#include <stdbool.h>
#include <string.h>

// MCU dependencies this HAL is for family Atmel ATSAMD21 you can find

/*******************************************************************************
* Definitions
******************************************************************************/
#define DEFAULT_TIMEOUT 30
#define TIMEOUT_ACK DEFAULT_TIMEOUT / 4
/*******************************************************************************
* Variables
******************************************************************************/

// timestamp variable
uint64_t start_offset;
/*******************************************************************************
* Function
******************************************************************************/
static void LuosHAL_SystickInit(void);
static void LuosHAL_FlashInit(void);

/////////////////////////Luos Library Needed function///////////////////////////

/******************************************************************************
* @brief Luos HAL general initialisation
* @param None
* @return None
******************************************************************************/
void LuosHAL_Init(void)
{
// Systick Initialization
LuosHAL_SystickInit();

// Flash Initialization
LuosHAL_FlashInit();

// start timestamp
LuosHAL_StartTimestamp();
}
/******************************************************************************
* @brief Luos HAL general disable IRQ
* @param Enable : Set to "True" to enable IRQ, "False" otherwise
* @return None
******************************************************************************/
_CRITICAL void LuosHAL_SetIrqState(bool Enable)
{
}
/******************************************************************************
* @brief Luos HAL general systick tick at 1ms initialize
* @param None
* @return Tick Counter
******************************************************************************/
static void LuosHAL_SystickInit(void)
{
}
/******************************************************************************
* @brief Luos HAL general systick tick at 1ms
* @param None
* @return Tick Counter
******************************************************************************/
_CRITICAL uint32_t LuosHAL_GetSystick(void)
{
return millis();
}

/******************************************************************************
* @brief Luos GetTimestamp
* @param None
* @return uint64_t
******************************************************************************/
_CRITICAL uint64_t LuosHAL_GetTimestamp(void)
{
return micros() * 1000 - start_offset;
}

/******************************************************************************
* @brief Luos start Timestamp
* @param None
* @return None
******************************************************************************/
_CRITICAL void LuosHAL_StartTimestamp(void)
{
start_offset = LuosHAL_GetSystick();
}

/******************************************************************************
* @brief Luos stop Timestamp
* @param None
* @return None
******************************************************************************/
_CRITICAL void LuosHAL_StopTimestamp(void)
{
start_offset = 0;
}

/******************************************************************************
* @brief Flash Initialisation
* @param None
* @return None
******************************************************************************/
static void LuosHAL_FlashInit(void)
{
}
/******************************************************************************
* @brief Set boot mode in shared flash memory
* @param None
* @return
******************************************************************************/
_CRITICAL void LuosHAL_SetMode(uint8_t mode)
{
}

/******************************************************************************
* @brief Save node ID in shared flash memory
* @param node_id
* @return
******************************************************************************/
_CRITICAL void LuosHAL_SaveNodeID(uint16_t node_id)
{
}

/******************************************************************************
* @brief Software reboot the microprocessor
* @param None
* @return
******************************************************************************/
void LuosHAL_Reboot(void)
{
}

#ifdef BOOTLOADER
/******************************************************************************
* @brief Get node id saved in flash memory
* @param Address
* @return node_id
******************************************************************************/
uint16_t LuosHAL_GetNodeID(void)
{
}

/******************************************************************************
* @brief Programm flash memory
* @param address : Start address
* @param size :: Data size
* @param data : Pointer to data
* @return
******************************************************************************/
void LuosHAL_ProgramFlash(uint32_t address, uint8_t page, uint16_t size, uint8_t *data)
{
}

/******************************************************************************
* @brief DeInit Bootloader peripherals
* @param None
* @return
******************************************************************************/
void LuosHAL_DeInit(void)
{
}

/******************************************************************************
* @brief DeInit Bootloader peripherals
* @param None
* @return
******************************************************************************/
typedef void (*pFunction)(void); /*!< Function pointer definition */

void LuosHAL_JumpToApp(uint32_t app_addr)
{
}

/******************************************************************************
* @brief Return bootloader mode saved in flash
* @param None
* @return
******************************************************************************/
uint8_t LuosHAL_GetMode(void)
{
}
#endif
Loading