Add New Tasking I/F and rework GPIO, UART, etc to support it
As with the last commit this rolls up the follwowing, but include the various
review comments on the PR.
- **Documentation changes**. I've added the taks FAQ as a stub new Extension
developer FAQ, and split the old FAQ into a Lua Developer FAQ and a Hardware
FAQ.
- **Tasking I/F**. New `app/task/Makefile`, `app/task/task.c`,
`app/include/task/task.h` and `app/Makefile` as per previous commit. Cascade
changes to `app/driver/uart.c`, `app/include/driver/uart.h`,
`app/user/user_main.c` and `app/modules/node.c`
- **GPIO Rework** to `app/modules/gpio.c` and `pin_map.[hc]`, `platform.[hc]`
in `app/platform`
- **Other Optimisations** Move the `platform_*_exists()` from
`app/platform/common.c` to static inline declarations in `platform.h` as
this generates faster, smaller code. Move lgc.a routines out of iram0.
2016-02-17 18:13:17 +01:00
|
|
|
#ifndef _TASK_H_
|
|
|
|
#define _TASK_H_
|
|
|
|
/*
|
2020-04-27 02:13:38 +02:00
|
|
|
** The task interface is now part of the core platform interface.
|
2019-07-18 18:02:02 +02:00
|
|
|
** This header is preserved for backwards compatability only.
|
2020-04-27 02:13:38 +02:00
|
|
|
*/
|
2019-07-18 18:02:02 +02:00
|
|
|
#include "platform.h"
|
|
|
|
|
2020-04-27 02:13:38 +02:00
|
|
|
#define TASK_PRIORITY_LOW PLATFORM_TASK_PRIORITY_LOW
|
|
|
|
#define TASK_PRIORITY_MEDIUM PLATFORM_TASK_PRIORITY_MEDIUM
|
|
|
|
#define TASK_PRIORITY_HIGH PLATFORM_TASK_PRIORITY_HIGH
|
2019-07-18 18:02:02 +02:00
|
|
|
|
|
|
|
#define task_post(priority,handle,param) platform_post(priority,handle,param)
|
|
|
|
#define task_post_low(handle,param) platform_post_low(handle,param)
|
|
|
|
#define task_post_medium(handle,param) platform_post_medium(handle,param)
|
|
|
|
#define task_post_high(handle,param) platform_post_high(handle,param)
|
|
|
|
|
|
|
|
#define task_handle_t platform_task_handle_t
|
|
|
|
#define task_param_t platform_task_param_t
|
|
|
|
#define task_callback_t platform_task_callback_t
|
|
|
|
#define task_get_id platform_task_get_id
|
Add New Tasking I/F and rework GPIO, UART, etc to support it
As with the last commit this rolls up the follwowing, but include the various
review comments on the PR.
- **Documentation changes**. I've added the taks FAQ as a stub new Extension
developer FAQ, and split the old FAQ into a Lua Developer FAQ and a Hardware
FAQ.
- **Tasking I/F**. New `app/task/Makefile`, `app/task/task.c`,
`app/include/task/task.h` and `app/Makefile` as per previous commit. Cascade
changes to `app/driver/uart.c`, `app/include/driver/uart.h`,
`app/user/user_main.c` and `app/modules/node.c`
- **GPIO Rework** to `app/modules/gpio.c` and `pin_map.[hc]`, `platform.[hc]`
in `app/platform`
- **Other Optimisations** Move the `platform_*_exists()` from
`app/platform/common.c` to static inline declarations in `platform.h` as
this generates faster, smaller code. Move lgc.a routines out of iram0.
2016-02-17 18:13:17 +01:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|