How to start gdb with --interpreter=mi

I am writing a TUI frontend for gdb, I know other application just attach to existing gdb with the machine interface. I am pretty sure the VSCode extension of platformio does something similar to spawn debug session.

I tried a lot of figureout how start pltformio cli debugger with mi enabled. All I can find is pio debug --interface=gdb -x .pioinit .

Can you help me with this, how to start platformio debug with mi or atlest tell me how does VS is able to interface with the undelaying debugger.

Thank you :slight_smile:

Nevermind its just pio debug --interface=gdb --interpreter=mi2 -x .pioinit found at Github Issue