TactilityC: Fix radio specific exports, touch up radio HAL
This commit is contained in:
parent
73e1535d14
commit
19aac5fbdb
@ -87,14 +87,14 @@ void tt_hal_radio_free(RadioHandle handle);
|
||||
* @param[in] handle the radio driver handle
|
||||
* @return the name of the radio
|
||||
*/
|
||||
const char* const tt_hal_radio_get_name(RadioHandle handle);
|
||||
const char* tt_hal_radio_get_name(RadioHandle handle);
|
||||
|
||||
/**
|
||||
* Get the description for the radio driver object.
|
||||
* @param[in] handle the radio driver handle
|
||||
* @return the description for the radio
|
||||
*/
|
||||
const char* const tt_hal_radio_get_desc(RadioHandle handle);
|
||||
const char* tt_hal_radio_get_desc(RadioHandle handle);
|
||||
|
||||
|
||||
/**
|
||||
@ -200,14 +200,14 @@ RadioTxId tt_hal_radio_transmit(RadioHandle handle, RadioTxPacket packet, RadioT
|
||||
* @param[in] callback function to call on reception of a packet
|
||||
* @return the identifier for the subscription
|
||||
*/
|
||||
RadioRxSubscriptionId radio_subscribe_receive(RadioHandle handle, RadioOnReceiveCallback callback);
|
||||
RadioRxSubscriptionId tt_hal_radio_subscribe_receive(RadioHandle handle, RadioOnReceiveCallback callback);
|
||||
|
||||
/**
|
||||
* Unsubscribe for any received packet that the radio driver object receives.
|
||||
* @param[in] handle the radio driver handle
|
||||
* @param[in] id the identifier for the subscription
|
||||
*/
|
||||
void radio_unsubscribe_receive(RadioHandle handle, RadioRxSubscriptionId id);
|
||||
void tt_hal_radio_unsubscribe_receive(RadioHandle handle, RadioRxSubscriptionId id);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@ -46,12 +46,12 @@ extern "C" {
|
||||
delete wrapper;
|
||||
}
|
||||
|
||||
const char* const tt_hal_radio_get_name(RadioHandle handle) {
|
||||
const char* tt_hal_radio_get_name(RadioHandle handle) {
|
||||
auto wrapper = static_cast<DeviceWrapper*>(handle);
|
||||
return wrapper->name.c_str();
|
||||
}
|
||||
|
||||
const char* const tt_hal_radio_get_desc(RadioHandle handle) {
|
||||
const char* tt_hal_radio_get_desc(RadioHandle handle) {
|
||||
auto wrapper = static_cast<DeviceWrapper*>(handle);
|
||||
return wrapper->description.c_str();
|
||||
}
|
||||
@ -128,7 +128,7 @@ extern "C" {
|
||||
});
|
||||
}
|
||||
|
||||
RadioRxSubscriptionId radio_subscribe_receive(RadioHandle handle, RadioOnReceiveCallback callback) {
|
||||
RadioRxSubscriptionId tt_hal_radio_subscribe_receive(RadioHandle handle, RadioOnReceiveCallback callback) {
|
||||
auto wrapper = static_cast<DeviceWrapper*>(handle);
|
||||
return wrapper->device->subscribeRx([callback](tt::hal::Device::Id id, const tt::hal::radio::RxPacket& ttPacket) {
|
||||
if (callback) {
|
||||
@ -143,7 +143,7 @@ extern "C" {
|
||||
});
|
||||
}
|
||||
|
||||
void radio_unsubscribe_receive(RadioHandle handle, RadioRxSubscriptionId id) {
|
||||
void tt_hal_radio_unsubscribe_receive(RadioHandle handle, RadioRxSubscriptionId id) {
|
||||
auto wrapper = static_cast<DeviceWrapper*>(handle);
|
||||
wrapper->device->unsubscribeRx(id);
|
||||
}
|
||||
|
||||
@ -11,6 +11,7 @@
|
||||
#include "tt_hal_gpio.h"
|
||||
#include "tt_hal_i2c.h"
|
||||
#include "tt_hal_touch.h"
|
||||
#include "tt_hal_radio.h"
|
||||
#include "tt_kernel.h"
|
||||
#include "tt_lvgl.h"
|
||||
#include "tt_lvgl_keyboard.h"
|
||||
@ -266,6 +267,23 @@ const esp_elfsym elf_symbols[] {
|
||||
ESP_ELFSYM_EXPORT(tt_hal_touch_driver_supported),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_touch_driver_alloc),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_touch_driver_free),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_alloc),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_free),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_name),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_desc),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_state),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_set_modulation),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_modulation),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_set_parameter),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_parameter),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_get_parameter_unit_str),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_can_transmit),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_can_receive),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_start),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_stop),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_transmit),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_subscribe_receive),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_radio_unsubscribe_receive),
|
||||
ESP_ELFSYM_EXPORT(tt_hal_touch_driver_get_touched_points),
|
||||
ESP_ELFSYM_EXPORT(tt_kernel_delay_millis),
|
||||
ESP_ELFSYM_EXPORT(tt_kernel_delay_micros),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user