Connecting OpenMV to RaspberryPi interrupts main.py execution

Hi,

I created script which reads barcode and sends it’s value to PC via USB virtual comm port.
Script works well if I connect camera to PC running Windows or old Slackware Linux.
But if I connect camera to RaspberryPi (Raspbian) or PC with Linux Mint main.py autostart is stopped.
Looks like Raspbian/Linux Mint sends to camera something that stops main.py execution while initialising kernel drivers.
Does anyone have similar problem solved?

You need to turn off ctrl c as an interrupt to the usb vcp port. See the usb vcp class and set the interrupt char.

Thanks for response!
I a also have disabled interrupt

usb.setinterrupt(-1)

, so this is not a case.

But Your response pointed me to recheck all I do, and I found that in my case problem is very simple: I missed error handling when using

decode("utf-8")

function. Script crashes when in driver initialising time receives un-decodable Unicode.

Problem solved!

Thank You!