Add TODOs and -Os for RISC-V
This commit is contained in:
parent
e409ff75cd
commit
d9966c1724
|
@ -157,7 +157,12 @@ ifeq ($(DEBUG), 1)
|
|||
# CFLAGS += -fno-inline -fno-ipa-sra
|
||||
else
|
||||
CFLAGS += -DNDEBUG -ggdb3
|
||||
OPTIMIZATION_FLAGS ?= -O2
|
||||
ifeq ($(IDF_TARGET_ARCH),xtensa)
|
||||
OPTIMIZATION_FLAGS ?= -O2
|
||||
else
|
||||
# RISC-V is larger than xtensa so do -Os for it
|
||||
OPTIMIZATION_FLAGS ?= -Os
|
||||
endif
|
||||
# TODO: Test with -flto
|
||||
### CFLAGS += -flto
|
||||
endif
|
||||
|
|
|
@ -75,6 +75,7 @@ void common_hal_bleio_characteristic_construct(bleio_characteristic_obj_t *self,
|
|||
// mp_raise_ValueError_varg(translate("max_length must be 0-%d when fixed_length is %s"),
|
||||
// max_length_max, fixed_length ? "True" : "False");
|
||||
// }
|
||||
// TODO: Implement this.
|
||||
self->max_length = max_length;
|
||||
self->fixed_length = fixed_length;
|
||||
|
||||
|
@ -97,6 +98,7 @@ bleio_service_obj_t *common_hal_bleio_characteristic_get_service(bleio_character
|
|||
}
|
||||
|
||||
size_t common_hal_bleio_characteristic_get_value(bleio_characteristic_obj_t *self, uint8_t *buf, size_t len) {
|
||||
// TODO: Implement this.
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -105,6 +107,7 @@ size_t common_hal_bleio_characteristic_get_max_length(bleio_characteristic_obj_t
|
|||
}
|
||||
|
||||
void common_hal_bleio_characteristic_set_value(bleio_characteristic_obj_t *self, mp_buffer_info_t *bufinfo) {
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
bleio_uuid_obj_t *common_hal_bleio_characteristic_get_uuid(bleio_characteristic_obj_t *self) {
|
||||
|
@ -116,8 +119,9 @@ bleio_characteristic_properties_t common_hal_bleio_characteristic_get_properties
|
|||
}
|
||||
|
||||
void common_hal_bleio_characteristic_add_descriptor(bleio_characteristic_obj_t *self, bleio_descriptor_obj_t *descriptor) {
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
void common_hal_bleio_characteristic_set_cccd(bleio_characteristic_obj_t *self, bool notify, bool indicate) {
|
||||
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
|
|
@ -65,15 +65,17 @@ void common_hal_bleio_characteristic_buffer_construct(bleio_characteristic_buffe
|
|||
}
|
||||
|
||||
uint32_t common_hal_bleio_characteristic_buffer_read(bleio_characteristic_buffer_obj_t *self, uint8_t *data, size_t len, int *errcode) {
|
||||
|
||||
// TODO: Implement this.
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint32_t common_hal_bleio_characteristic_buffer_rx_characters_available(bleio_characteristic_buffer_obj_t *self) {
|
||||
// TODO: Implement this.
|
||||
return 0;
|
||||
}
|
||||
|
||||
void common_hal_bleio_characteristic_buffer_clear_rx_buffer(bleio_characteristic_buffer_obj_t *self) {
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
bool common_hal_bleio_characteristic_buffer_deinited(bleio_characteristic_buffer_obj_t *self) {
|
||||
|
@ -81,6 +83,7 @@ bool common_hal_bleio_characteristic_buffer_deinited(bleio_characteristic_buffer
|
|||
}
|
||||
|
||||
void common_hal_bleio_characteristic_buffer_deinit(bleio_characteristic_buffer_obj_t *self) {
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
bool common_hal_bleio_characteristic_buffer_connected(bleio_characteristic_buffer_obj_t *self) {
|
||||
|
|
|
@ -64,13 +64,15 @@ bool common_hal_bleio_connection_get_connected(bleio_connection_obj_t *self) {
|
|||
}
|
||||
|
||||
void common_hal_bleio_connection_disconnect(bleio_connection_internal_t *self) {
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
void common_hal_bleio_connection_pair(bleio_connection_internal_t *self, bool bond) {
|
||||
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
mp_float_t common_hal_bleio_connection_get_connection_interval(bleio_connection_internal_t *self) {
|
||||
// TODO: Implement this.
|
||||
while (self->conn_params_updating && !mp_hal_is_interrupted()) {
|
||||
RUN_BACKGROUND_TASKS;
|
||||
}
|
||||
|
@ -84,6 +86,7 @@ mp_int_t common_hal_bleio_connection_get_max_packet_length(bleio_connection_inte
|
|||
|
||||
void common_hal_bleio_connection_set_connection_interval(bleio_connection_internal_t *self, mp_float_t new_interval) {
|
||||
self->conn_params_updating = true;
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
||||
mp_obj_tuple_t *common_hal_bleio_connection_discover_remote_services(bleio_connection_obj_t *self, mp_obj_t service_uuids_whitelist) {
|
||||
|
@ -94,6 +97,7 @@ mp_obj_tuple_t *common_hal_bleio_connection_discover_remote_services(bleio_conne
|
|||
self->connection->remote_service_list->items);
|
||||
mp_obj_list_clear(MP_OBJ_FROM_PTR(self->connection->remote_service_list));
|
||||
|
||||
// TODO: Implement this.
|
||||
return services_tuple;
|
||||
}
|
||||
|
||||
|
|
|
@ -68,10 +68,13 @@ size_t common_hal_bleio_descriptor_get_value(bleio_descriptor_obj_t *self, uint8
|
|||
(void)conn_handle;
|
||||
}
|
||||
|
||||
// TODO: Implement this.
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void common_hal_bleio_descriptor_set_value(bleio_descriptor_obj_t *self, mp_buffer_info_t *bufinfo) {
|
||||
// TODO: Implement this.
|
||||
// Do GATT operations only if this descriptor has been registered.
|
||||
if (self->handle != BLEIO_HANDLE_INVALID) {
|
||||
// uint16_t conn_handle = bleio_connection_get_conn_handle(self->characteristic->service->connection);
|
||||
|
|
|
@ -118,7 +118,7 @@ mp_int_t common_hal_bleio_packet_buffer_readinto(bleio_packet_buffer_obj_t *self
|
|||
}
|
||||
|
||||
// Copy received data. Lock out write interrupt handler while copying.
|
||||
|
||||
// TODO: Implement this.
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -172,6 +172,7 @@ mp_int_t common_hal_bleio_packet_buffer_write(bleio_packet_buffer_obj_t *self, c
|
|||
self->pending_size += len;
|
||||
num_bytes_written += len;
|
||||
|
||||
// TODO: Implement this.
|
||||
|
||||
// If no writes are queued then sneak in this data.
|
||||
if (!self->packet_queued) {
|
||||
|
@ -270,4 +271,5 @@ bool common_hal_bleio_packet_buffer_deinited(bleio_packet_buffer_obj_t *self) {
|
|||
void common_hal_bleio_packet_buffer_deinit(bleio_packet_buffer_obj_t *self) {
|
||||
if (!common_hal_bleio_packet_buffer_deinited(self)) {
|
||||
}
|
||||
// TODO: Implement this.
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue