Arduino Due SerialUSB bug on monitor close/USB unplug
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- arduino, cpp
- Lĩnh vực
- embedded-iot
Hướng nghiên cứu
Bắt đầu với sketch Due được cung cấp và tái hiện hành vi bằng cách đóng trình giám sát nối tiếp USB native hoặc rút ra rồi cắm lại trong khi thiết bị được cấp nguồn qua Programming USB. So sánh hành vi trên Windows 10 và Linux trong khi theo dõi việc xử lý SerialUSB/native USB. Được xem là hoàn tất khi vòng lặp tiếp tục sau khi ngắt kết nối hoặc đóng trình giám sát, và trình giám sát được mở lại nhận các thông báo theo đúng thứ tự ban đầu.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Hi all,
I'm trying to develop an application where the arduino Due is continuously working (always powered), and I can connect to it using the native USB, so I can get data about the process. I have found unexpected behavior of the Due board when it is unplugged, or the serial port is closed.
For the following test I have used this Arduino Code. With this one two different problems are observed.
void setup() {
pinMode(LED_BUILTIN, OUTPUT);
SerialUSB.begin(115200);
}
void loop() {
SerialUSB.print("H");
SerialUSB.print("e");
SerialUSB.print("y");
SerialUSB.print(" ");
SerialUSB.print(":");
SerialUSB.println(")");
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(200); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(200); // wait for a second
}
I have found this issues
->If Serial monitor is closed while sending data through the native USB (SerialUSB) the main loop gets freezed, until the serial monitor is opened again. (With the test code, it can be observed that the led stops blinking).
->If unplugged the Native USB while sending data (and keep powered with the other USB), when a new monitor is opened, the received data order is changed. How can it be? The data order gets changed, and while unplugged the led stops blinking.
I also found a post where one of the bugs is mentioned:
https://forum.arduino.cc/index.php?topic=560839.0
As Sanworks_J explains this problem only appears when the computer used as serial monitor is Windows 10. I have check both problems in Linux, and in this case the board works correctly.
I have followed this Steps to in the second issue.
-->Connect both the programming USB (just for power, no data) and Native USB.
--> Upload the sketch to the board, and open the serial monitor, native USB. (Data received correctly).
--> While serial monitor is opened, unplug the Native USB (while powered with the other USB)
--> Plug the Native USB again. Close the monitor opened before(because it is stopped).
--> Open a new serial monitor, and the received data from that moment the data order is wrong.
Since that moment, the received messages are as follows.
)eH y):H
ye:
)eH y):H
ye:
When it should be:
Hey :)
Hey :)
Hey :)
I have made this test in different PCs and with different Arduino Due boards, with the same results in Win10. When used Linux it doesn't happen, but the program gets stopped when unplugged the USB, this problem remains in Linux.
Any possible solution to this issue?
Thanks in advance.
- Ngôn ngữ chính
- HTML
- Star
- 91
- Fork
- 111
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của arduino/ArduinoCore-sam
-
adc_set_resolution bugĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
arduino/ArduinoCore-sam#129 ·
-
Type: Bug
Độ khó 3/5 Nửa ngày Mức phù hợp với người mới 62/100
arduino/ArduinoCore-sam#154 ·
-
Type: Bug USB: CDC serial
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
arduino/ArduinoCore-sam#153 · 1 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
arduino/ArduinoCore-sam#151 · 5 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
arduino/ArduinoCore-sam#147 ·
Tất cả issue của arduino/ArduinoCore-sam
Issue tương tự
-
elf_loader: Xtensa ignores the addend of R_XTENSA_GLOB_DAT / R_XTENSA_JMP_SLOT (C++ vtables)Có thể đã có người làm @diplfranzhoepfinger đã nhận hôm nay. Đang mởelf_loader
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
espressif/esp-iot-solution#813 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
zephyrproject-rtos/zephyr#124160 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
GalusPeres/HomeTiles#142 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
openhab/openhab-addons#22135 ·
Maintainer thường phản hồi trong vòng 1 ngày