Search found 8 matches

by l0ud
Wed Oct 30, 2019 12:45 am
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

Re: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

Now it seems to be working correctly without any modifications in ChibiOS source on master branch.
by l0ud
Mon Sep 30, 2019 9:20 pm
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

Re: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

Thanks for confirming issue. I've made a quick workaround in _usb_suspend function.
for (i = 0; i <= (unsigned)USB_MAX_ENDPOINTS; i++) {
if (usbp->epc&#91;i&#93; != NULL) {
osalSysLockFromISR();
if (usbp->epc&#91;i&#93;->in_state != NULL) {
usbp->transmitting &= ~(1 << (i));
osalThreadResumeI ...
by l0ud
Mon Sep 30, 2019 10:41 am
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

Re: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

I connected my board at work to a PC with windows 10 with USB analyzer between. It crashed after resume too. I'm not sure about exact reason, because I don't have a debugger here.

However, on analyzer I can see there is ongoing IN transaction (with corresponding NAK-s because there are no midi ...
by l0ud
Fri Sep 27, 2019 10:29 pm
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

Re: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

It doesn't seem to reenumerate any devices at all. I can leave openocd st-link session open and after resume it just go on like it was before sleep. Also, I don't see any dmesg messages about reenumeration, except when my device is connected. In that case I see multiple URB errors and then failed ...
by l0ud
Fri Sep 27, 2019 5:47 pm
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

Re: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

There is no USB_EVENT_RESET after host sleep nor after resume. The only reset event I got happens directly after connecting USB cable first time. Maybe there is reset after wakeup, but firmware is already crashed on assertion so I couldn't catch it.
by l0ud
Thu Sep 26, 2019 10:15 pm
Forum: Bug Reports
Topic: [F103] USB_RAW: Assertion "already receiving" after PC sleep and resume
Replies: 11
Views: 38223

[F103] USB_RAW: Assertion "already receiving" after PC sleep and resume

Hi,
I've build USB-MIDI adapter with two endpoints based on USB-RAW example. I have 2 threads for USB processing: one for receiving data in a loop, one for sending when there is a need to do that.
Everything works without problems until I put the computer to sleep while the device is connected. It ...
by l0ud
Thu Nov 30, 2017 11:31 pm
Forum: ChibiOS/HAL
Topic: STM32F1 Getting SD_BREAK_DETECTED even if LIN is disabled
Replies: 3
Views: 3272

Re: STM32F1 Getting SD_BREAK_DETECTED even if LIN is disabled

Well, I'm not getting any event after SD_BREAK_DETECTED. I said I needed to use chIQResetI() because it was the only method to recover from serial error I've managed to find on forum, I cannot find anything in the doccumentation either - maybe there is some more elegant way?

If I force my bt driver ...
by l0ud
Thu Nov 30, 2017 1:24 am
Forum: ChibiOS/HAL
Topic: STM32F1 Getting SD_BREAK_DETECTED even if LIN is disabled
Replies: 3
Views: 3272

STM32F1 Getting SD_BREAK_DETECTED even if LIN is disabled

Hi. I'm using serial driver and so far I'm pretty happy with it. However there is one thing that confuses me.
I'm communicating with BT module that requires reset during initialization. After triggering RESET, it holds TX line low for some time, which I think is interpreted as LIN break. After that ...