Skip to content

LVGL and BLE on ESP32 #109

@lixas

Description

@lixas

Hello

I have an issue, that i can not use BLE in my LVGL micropython application. As and example i took advanced demo application as my starting point, for slightly modified ILI9341 and XPT2046. Built an UI that i like, and then i tried to implement BLE scanning functionality. And i failed at this point...

I was able to narrow down my issue to bare minimum:

import ubluetooth
import lvesp32          # <-- This breaks BLE scanner irq

def bt_irq(event, data):
    print(event, data)

ble = ubluetooth.BLE()
ble.active(True)
ble.irq(handler=bt_irq)
ble.gap_scan(0, 30000, 30000)

if lvesp32 is commented out- everything works as expected and i do see BLE advertisement packets. If i import lvesp32 later, when my BLE scanner is running- it stops like in second or so and no more data is shown. Importing lvesp32 is enough to kill/hang/stop BLE scanning process.

What I do need in my final application is read BLE advertisements packets, extract data and show in on LVGL interface on ILI9341 display.

I built firmware on my own computer for generic ESP32 (no external PSRAM)
MicroPython v1.9.4-2805-g46e9073b2 on 2020-09-01; ESP32 module with ESP32

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleThis will not be worked on

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions