Skip to content

Commit b24bd50

Browse files
committed
raise task priority and make it configurable
1 parent 0a8df39 commit b24bd50

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/SnapConfig.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,3 +63,7 @@
6363
#ifndef RTOS_STACK_SIZE
6464
# define RTOS_STACK_SIZE 10 * 1024
6565
#endif
66+
67+
#ifndef RTOS_TASK_PRIORITY
68+
# define RTOS_TASK_PRIORITY 2
69+
#endif

src/api/SnapProcessorRTOS.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class SnapProcessorRTOS : public SnapProcessor {
4141

4242
protected:
4343
const char *TAG = "SnapProcessorRTOS";
44-
cpp_freertos::Task task{"output", RTOS_STACK_SIZE, 1, task_copy};
44+
cpp_freertos::Task task{"output", RTOS_STACK_SIZE, RTOS_TASK_PRIORITY, task_copy};
4545
cpp_freertos::Queue size_queue{RTOS_MAX_QUEUE_ENTRY_COUNT, sizeof(size_t)};
4646
audio_tools::SynchronizedBufferRTOS<uint8_t> buffer{0}; // size defined in constructor
4747
bool task_started = false;

0 commit comments

Comments
 (0)