On the Publisher side
Code: Select all
{
{
void* buffer = malloc(10);
memcpy(buffer, "Hello", 0, 1024);
res = esp_event_post(SIGMA_EVENT,
SIGMA_HELLO_EVENT_ID,
buffer,
0,
portMAX_DELAY);
}
Code: Select all
res = esp_event_handler_instance_register(SIGMA_EVENT,
SIGMA_HELLO_EVENT_ID,
myEventHandler1,
args,
instance);
res = esp_event_handler_instance_register(SIGMA_EVENT,
SIGMA_HELLO_EVENT_ID,
myEventHandler2,
args,
instance);