saniljhaveri / avr-project-ide

Automatically exported from code.google.com/p/avr-project-ide
0 stars 0 forks source link

Can't access COM ports above COM4 - Improper Windows COM port file descriptors for avrdude #44

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Select a COM port above COM4 in "AVRDUDE Tool", e.g. COM10
2. "Write File + Verify", Select file, OK
3. Error: "avrdude: ser_open(): can't open device "COM10": The system
cannot find the file specified."

You need to use file descriptors to correctly access serial ports in
Windows, i.e. //./COMx or \\.\COMx

Suggestion: in AvrDudeWindow.cs - s|overrides += "-P |overrides += "-P //./|g

i.e. replace the "-P " to "-P //./" (two places - GetOverrides(), and
btnInteractive_Click())

The Arduino IDE uses proper file descriptors for the COM ports:

(from AvrdudeUploader.java):
private boolean uploadViaBootloader(String buildPath, String className)
{
.
.
.
    commandDownloader.add("-P" + (Base.isWindows() ? "\\\\.\\" : "") +
Preferences.get("serial.port"));
.
.
.

}

b

Original issue reported on code.google.com by rogue.bh...@gmail.com on 25 Dec 2009 at 6:14

GoogleCodeExporter commented 8 years ago
thanks, i didn't know about this until now

alpha 67 will replace the dropdown with a textbox, you made me research and 
realize 
the complex ways people might want to define ports, such as usb:xx:xx and other 
weird 
stuff

also will auto-change port to "avrdoper" if the field is blank and the avrdoper 
is 
selected, because "For the USB programmer "AVR-Doper" running in HID mode, the 
port 
must be specified as avrdoper."

references: http://www.nongnu.org/avrdude/user-manual/avrdude_4.html

Original comment by frank.zhao.main@gmail.com on 25 Dec 2009 at 8:05