internal mutex
This commit is contained in:
parent
fdf32d8503
commit
0b1ca17351
4 changed files with 125 additions and 69 deletions
|
@ -35,14 +35,14 @@ class ESPMegaDisplay
|
|||
void unregisterPageChangeCallback(uint16_t handle);
|
||||
uint16_t registerPayloadCallback(std::function<void(uint8_t, uint8_t*, uint8_t)> callback);
|
||||
void unregisterPayloadCallback(uint16_t handle);
|
||||
void takeSerialMutex();
|
||||
bool takeSerialMutex();
|
||||
void giveSerialMutex();
|
||||
SemaphoreHandle_t serialMutex;
|
||||
bool beginUpdate(size_t size);
|
||||
bool writeUpdate(uint8_t* data, size_t size);
|
||||
void endUpdate();
|
||||
protected:
|
||||
size_t otaBytesWritten;
|
||||
SemaphoreHandle_t serialMutex;
|
||||
uint8_t currentPage;
|
||||
uint8_t rx_buffer_index;
|
||||
char rx_buffer[256];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue