stdio over USB needs DTR signal to be activated from terminal program #921

Closed
opened 2022-07-14 05:15:42 -05:00 by RobertK66 · 5 comments
RobertK66 commented 2022-07-14 05:15:42 -05:00 (Migrated from github.com)

I think, this is no bug but a feature ;-).
But at least, IMHO it would be worth a note in the documentation. (Chapter 4.4 in 'Getting started ...')

I wasted some time in debugging my Windows 11 - USB driver Stack and tried to understand your documented issues with the 'USB Enumeration workaround' .....

In the end, I found that using the HTerm terminal program is my issue! This terminal software does not set DTR signal on connect per default! Also my own code using NET Serial Port needed the line:

Port.DtrEnable = true;

to be added in order to work. Using putty iso HTerm worked out of the box.
( But once you know the problem, there is a button fot DTR in HTerm 😄 ... )

I think, this is no bug but a feature ;-). But at least, IMHO it would be worth a note in the documentation. (Chapter 4.4 in 'Getting started ...') I wasted some time in debugging my Windows 11 - USB driver Stack and tried to understand your documented issues with the 'USB Enumeration workaround' ..... In the end, I found that using the HTerm terminal program is my issue! This terminal software does not set DTR signal on connect per default! Also my own code using NET Serial Port needed the line: ` Port.DtrEnable = true;` to be added in order to work. Using putty iso HTerm worked out of the box. ( But once you know the problem, there is a button fot DTR in HTerm 😄 ... )
lurch commented 2022-07-14 05:21:50 -05:00 (Migrated from github.com)

This was also discussed recently in #906 - I've not been following it very closely, but it seems to be more of a tinyusb thing than a pico-sdk thing? https://github.com/hathach/tinyusb/issues/1548 🤷

This was also discussed recently in #906 - I've not been following it very closely, but it seems to be more of a tinyusb thing than a pico-sdk thing? https://github.com/hathach/tinyusb/issues/1548 :shrug:
RobertK66 commented 2022-07-14 05:32:18 -05:00 (Migrated from github.com)

Ok, Thx for pointing me there.
I am not sure, if "DTR" is considered part of 'Flow Control' but I also didn't expect the behaviour it currently shows....

Ok, Thx for pointing me there. I am not sure, if "DTR" is considered part of 'Flow Control' but I also didn't expect the behaviour it currently shows....
RobertK66 commented 2022-07-14 13:27:12 -05:00 (Migrated from github.com)

Note (to others having problems to get this up and running):
I still need the
TUD_OPT_RP2040_USB_DEVICE_ENUMERATION_FIX=1
to make the com port working on my Windows 11 Notebook. If I leave this to default or 0, then the COM port shows up in device manager but is 'not connectable' (Hterm hangs on connect).

Note (to others having problems to get this up and running): I still need the `TUD_OPT_RP2040_USB_DEVICE_ENUMERATION_FIX=1` to make the com port working on my Windows 11 Notebook. If I leave this to default or 0, then the COM port shows up in device manager but is 'not connectable' (Hterm hangs on connect).
lurch commented 2022-07-14 16:12:01 -05:00 (Migrated from github.com)

Whether you need the USB_DEVICE_ENUMERATION_FIX or not depends which other USB devices you have connected at the same time. And it's also not needed if you're using a board using RP2040 B2, e.g. Raspberry Pi Pico W.

Whether you need the USB_DEVICE_ENUMERATION_FIX or not depends which other USB devices you have connected at the same time. And it's also not needed if you're using a board using RP2040 B2, e.g. Raspberry Pi Pico W.
kilograham commented 2022-08-10 09:17:26 -05:00 (Migrated from github.com)

merged into develop

merged into develop
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-raspberrypi/pico-sdk#921
No description provided.