I haven't found task scan to be helpful. Using the default task stack. Tried using OSDumpTasks(), but got lots of compile errors rebuilding the system library for debug. Tried to restore to a non-debug, now my application compiles but I get many link errors. And each time a rebuild there are a different number of errors. First 31 link errors, then 12 file not found errors, etc.
Removed the installation, and restored the tools from a backup. Everything compiles and links again. But priority 54 no longer works. Since the reason for this was to be able to use threads beyond the small sandbox of 46-50, the following function was written. It's used after all Netburner tasks are created. So far, it seems to work.
Code: Select all
BYTE CreateTask(void (* task)(void *taskfunc), void *data, void *stacktop, void *stackbot)
{
for (BYTE priority=MAIN_PRIORITY-1; priority>1; priority--)
if (OSTaskCreate(task, data, stacktop, stackbot, priority) == OS_NO_ERR)
return priority;
return 64; // Legal priorities are 1-63.
}