Default Task Prios?
Posted: Mon Nov 24, 2008 8:49 am
Here's a general question... There are quite a few "default" NB task priorities declared for tasks which provide basic system utilities that I like to use as essential system resources: TCP, FTP, HTTP, Ethernet, etc. However, their default prios don't leave too much room for user-related tasks above them, and so I find I often wind up moving the NB default tasks below MAIN_PRIO down by an offset of 30 which then moves the default prios between FTP and ENC_TASK (48 to 36) respectively to (18 and 6) respectively. This then frees up a much bigger user task priority area (from 19 to 49). The default prio setup leaves prios from 0 to 35 unoccupied. But is there good reason to have tasks running at prios below the system TCP, Ethernet, FTP defaults? If so, I'm interested in what they might be. If not, why wouldn't the defaults be moved much lower to free up this middle block of task prio space for user tasks?
FYI, I often define my user task prios in a file called Tasks.h which includes commented indicators of the system defaults to see where everything sits in one consolidated place.
FYI, I often define my user task prios in a file called Tasks.h which includes commented indicators of the system defaults to see where everything sits in one consolidated place.
Code: Select all
//TASKS listed in order of priority where LOWER NUMBER = HIGHER priority:
//----------------------------------------------------------------------_-
//IDLE task is set at lowest priority (63) // NB System
////LOWER priority than main above this line------------------------------
// #define MAIN_PRIO (50) // NB System
// #define FTP_PRIO (48) // NB System
// #define HTTP_PRIO (45) // NB System
// #define PPP_PRIO (44) // NB System
// #define TCP_PRIO (40) // NB System
// #define IP_PRIO (39) // NB System
// #define ETHER_SEND_PRIO (38) // NB System
// #define WIFI_TASK_PRIO (37) // NB System
// #define ENC_TASK_PRIORITY (36) // NB System