From 230c18d18490310e8a7f98d4487c9be26071b868 Mon Sep 17 00:00:00 2001 From: dernasherbrezon Date: Sun, 1 Dec 2024 10:42:31 +0000 Subject: [PATCH] reduce interrupt latency --- test/test_app/main/sx127x_fixture.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/test_app/main/sx127x_fixture.c b/test/test_app/main/sx127x_fixture.c index 3e67bcb..254bdae 100644 --- a/test/test_app/main/sx127x_fixture.c +++ b/test/test_app/main/sx127x_fixture.c @@ -18,10 +18,13 @@ static const char *TAG = "sx127x_test"; static SemaphoreHandle_t xBinarySemaphore; -static BaseType_t xHigherPriorityTaskWoken = pdFALSE; void IRAM_ATTR handle_interrupt_fromisr(void *arg) { + BaseType_t xHigherPriorityTaskWoken = pdFALSE; xSemaphoreGiveFromISR(xBinarySemaphore, &xHigherPriorityTaskWoken); + if (xHigherPriorityTaskWoken == pdTRUE) { + portYIELD_FROM_ISR(); + } } void handle_interrupt_task(void *arg) {