I assume pdb is the Python debugger. That’s most likely running your system’s native Python interpreter, and will not work with MicroPython. You would need to research a MicroPython equivalent, and I’m not sure that one exists, as MicroPython programs are generally not complex enough to require a full, sophisticated debugger.
Yes, you are right pdb is Python debugger from my Raspberry Pi system in which I’m trying to run code. I suppose I could try to run and debug my LVGL application with standard Python? How to tell Python about my LVGL library in this situation?
Your script does not wait so it exists immediately.
You can either add an infinite loop at the end, or run it with micropython -i which runs the script and then opens the interactive REPL instead of exiting.
As @embeddedt already mentioned - you cannot use pdb (or any other Python tool) with Micropython.
As far as I know there is no Micropython debugger. sys.settrace is implemented so it’s possible to get a trace of the run. But Micropython core is inherently missing the ability to query/reflect local variables so a true debugger cannot be implemented for now.