1
0
mirror of https://github.com/thooge/esp32-nmea2000-obp60.git synced 2025-12-14 06:23:07 +01:00

add registerRequestHandler to the API with examples

This commit is contained in:
andreas
2024-11-14 18:15:12 +01:00
parent 506dd7ea9f
commit 538f643fbf
9 changed files with 133 additions and 4 deletions

View File

@@ -7,10 +7,10 @@ class GwSynchronized{
public:
GwSynchronized(SemaphoreHandle_t *locker){
this->locker=locker;
xSemaphoreTake(*locker, portMAX_DELAY);
if (locker != nullptr) xSemaphoreTake(*locker, portMAX_DELAY);
}
~GwSynchronized(){
xSemaphoreGive(*locker);
if (locker != nullptr) xSemaphoreGive(*locker);
}
};