I tried that already, there is no access to log_handler.
struct libusb_context is not defined, only the pointer to it.
I tried with
Code:
*mInitCout << "init enabling reception ...";
libusb_set_log_cb(getUsbContext(), nullptr, LIBUSB_LOG_CB_GLOBAL);
libusb_set_log_cb(getUsbContext(), nullptr, LIBUSB_LOG_CB_CONTEXT);
if (!enableReceiveAsyncTransfer())
in process(), but no change.
There was a new message when restarting the connection from
Code:
core.c: usbi_warn(_ctx, "device %d.%d still referenced",
and that didn't crash even if it uses the same underlying log_v function.
I leave it like that.
The problem has been the assert statement. But I tested to remove that some two years ago
(the github issue) and failed in the same way it does now. But in general the assert is what
people experience, I understood.
I'll test Hannes' version next.
Edit: Tested, it avoids the mode switching altogether. I think that is perfectly fine.
I don't expect to switch to Man mode and jog when I'm running a program. Could happen
by mistake even. If I feel a need to switch to Man I'll designate a button for that.
I have a vague memory I did that on the previous generation xhc.
Is it in a shape to go into linuxcnc repo? I think it should end up there.