summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Halbert <halbert@halwitz.org>2020-01-27 17:10:56 -0500
committerDan Halbert <halbert@halwitz.org>2020-01-27 17:10:56 -0500
commite21580b67fb476ac89955407af01cf6406b3b388 (patch)
treee58c763143af9a322c09ac8947a03a19054d926d
parent7c11a5ad6d59d6a87eec4cfb6ed4728d0c06761b (diff)
PacketBuffer.packet_size was returning bool instead of int
-rw-r--r--shared-bindings/_bleio/Characteristic.c2
-rw-r--r--shared-bindings/_bleio/PacketBuffer.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/shared-bindings/_bleio/Characteristic.c b/shared-bindings/_bleio/Characteristic.c
index 2b1dc1f78..e55191f7c 100644
--- a/shared-bindings/_bleio/Characteristic.c
+++ b/shared-bindings/_bleio/Characteristic.c
@@ -49,7 +49,7 @@
//| as part of remote Services.
//|
-//| .. method:: add_to_service(service, uuid, *, properties=0, read_perm=`Attribute.OPEN`, write_perm=`Attribute.OPEN`, max_length=20, fixed_length=False, initial_value=None)
+//| .. method:: add_to_service(service, uuid, *, properties=0, read_perm=Attribute.OPEN, write_perm=Attribute.OPEN, max_length=20, fixed_length=False, initial_value=None)
//|
//| Create a new Characteristic object, and add it to this Service.
//|
diff --git a/shared-bindings/_bleio/PacketBuffer.c b/shared-bindings/_bleio/PacketBuffer.c
index f9f171870..3ed295f01 100644
--- a/shared-bindings/_bleio/PacketBuffer.c
+++ b/shared-bindings/_bleio/PacketBuffer.c
@@ -163,13 +163,13 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_1(bleio_packet_buffer_deinit_obj, bleio_packet_bu
//| .. attribute:: packet_size
//|
-//| Maximum size of each packet in bytes. This is the minimum of the Characterstic length and
+//| Maximum size of each packet in bytes. This is the minimum of the Characteristic length and
//| the negotiated Maximum Transfer Unit (MTU).
//|
STATIC mp_obj_t bleio_packet_buffer_get_packet_size(mp_obj_t self_in) {
bleio_packet_buffer_obj_t *self = MP_OBJ_TO_PTR(self_in);
- return mp_obj_new_bool(common_hal_bleio_packet_buffer_get_packet_size(self));
+ return MP_OBJ_NEW_SMALL_INT(common_hal_bleio_packet_buffer_get_packet_size(self));
}
STATIC MP_DEFINE_CONST_FUN_OBJ_1(bleio_packet_buffer_get_packet_size_obj, bleio_packet_buffer_get_packet_size);