mirror of
https://github.com/micropython/micropython.git
synced 2025-08-30 06:20:40 +02:00
extmod/modbluetooth: Fix so it builds in peripheral-only mode.
This commit is contained in:
committed by
Damien George
parent
43ceadac55
commit
3c7ca2004c
@@ -836,10 +836,12 @@ STATIC void ringbuf_extract(ringbuf_t *ringbuf, mp_obj_tuple_t *data_tuple, size
|
||||
// Note the int8_t got packed into the ringbuf as a uint8_t.
|
||||
data_tuple->items[j++] = MP_OBJ_NEW_SMALL_INT((int8_t)ringbuf_get(ringbuf));
|
||||
}
|
||||
#if MICROPY_PY_BLUETOOTH_ENABLE_CENTRAL_MODE
|
||||
if (uuid) {
|
||||
ringbuf_get_uuid(ringbuf, uuid);
|
||||
data_tuple->items[j++] = MP_OBJ_FROM_PTR(uuid);
|
||||
}
|
||||
#endif
|
||||
// The code that enqueues into the ringbuf should ensure that it doesn't
|
||||
// put more than bt->irq_data_data_alloc bytes into the ringbuf, because
|
||||
// that's what's available here in bt->irq_data_bytes.
|
||||
|
Reference in New Issue
Block a user