Digistump Forums
The DigiX => DigiX Support => Topic started by: Kaeltis on January 16, 2014, 01:46:38 pm
-
I'm having a weird issue with the serial port.
After uploading a sketch with serial output enabled, the serial monitor doesn't show anything at all,
I can only get it to work by deleting the DigiX COM port from the device manager, unplugging the DigiX and plugging it in again, but only until I upload a new sketch.
I'm using the DigiX Hardware files and DigiX Drivers on Windows 8.1 x64
Also, the WiFi module aswell only seems to work together with
//DigiX trick - since we are on serial over USB wait for character to be entered in serial terminal
while(!Serial.available()){
Serial.println("Enter any key to begin");
delay(1000);
}
in setup() and this procedure. As soon as I remove the "DigiX trick", it doesn't respond anymore (using the "ServerExample" or the arduino_to_thingspeak example) except for it's builtin webinterface.
-
The first issue I've seen too with Arduino IDE 1.5.5 in general (not DigiX specific) - and for that reason don't have a fix, it just went away the next day - do you see it with other boards in the same IDE if you have others?
For the DigiX try putting a delay say delay(1000); (or more) at the start where the Serial waiting was - the wifi module might not be starting fully before you try to talk to it.
-
I added a delay of 5000ms to setup, now it works, thanks :)
I'll try an old Arduino Mega 2560 later and see how that behaves.
Edit: no serial issues with the Mega 2560, maybe it's caused by the whole flash erasing, writing and board reseting process the newer boards use.
-
Do you have a second machine you can test the serial thing on? I see no way it could be the device - but it'd be nice to confirm if it was the IDE/computer.
-
Old MacBook Pro (late 2007) with OS X Mavericks - Serial working perfectly, can upload sketches and directly access the Serial Monitor to get the output.
Same PC as Windows 8.1 with Linux Mint 16 x64 - similar serial problems as on windows
Gonna try Win 7 x64 on a different Machine later
Edit: exactly the same serial problems there.
-
This is just strange - obviously not a hardware issue, serial works for me on many win8, win8.1, and win7 machines.... is there a common program on these machines that could be interfering? that's all I can think of...
-
I have no clue, especially as there are similar problems in a clean linux environment. :-\
Are you using Beta 1.5.5 or 1.5.5-R2?
I'll do a clean windows install the next couple of days, maybe things behave different then.
Just to make sure, when installing the IDE, is this the correct order for a x64 system?
- Download and install/extract the Arduino beta IDE (1.5.5-R2)
- Install the drivers from the Arduino IDE "drivers" folder (dpinst-amd64.exe)
- Extract the DigiX hardware folder to "Documents\Arduino"
- Run the DigiX "Install Drivers - 64bit.bat" file
- Run the Arduino IDE, select COM Port and Board "Digistump DigiX (standard)", programmer is AVRISP mkII
One thing i noticed, when you go to "<arduino installation folder>\hardware\tools" and run "listComPorts.exe" the program shows all COM ports but then crashes with the following message:
(http://i.imgur.com/mva0Air.png)
(it shows the DigiX COM port for just a moment after i click the OK button)
Maybe its caused by the german language of my OS? Can anyone confirm that?
-
I can confirm, that it is running under german versions of
- Windows 7 Ultimate x64,
- Windows 7 Personal x64,
- Vista Business x64,
- Windows 7 Personal 32,
- Windows XP 32
It runs as well under several Ubuntus 32/64 10.04, 12.04, 13.10 and OpenSuse 13.1
-
Do you get that error message when running listComPorts?
-
no, i receive a complete list without any error!
-
So this might be the possible cause of the problem, can anyone tell me why this is happening?
-
https://github.com/arduino/Arduino/issues/1573
-
Strange, so this should already be fixed? So why is it still broken? :o
-
the MD5 sum of my listcomports.exe is:
5330b7080dde031656c83c3a8cdd93c7 listcomports.exe
if you have no windows version of md5sums, you can get it there:
http://support.microsoft.com/kb/841290 (http://support.microsoft.com/kb/841290)
-
Thanks, have the same checksum here
also tried compiling the most recent version from git - same error
(https://github.com/todbot/usbSearch)
-
I haven't tried 1.5.5-R2 yet - gogol are you using 1.5.5 or 1.5.5-R2?
-
@digistump: I have on one box a 1.5.5R2 and verified the md5-checksum: Its just the same!
@Kaeltis:
- What does listcomports.exe respons, if you disconnect the DigiX?
- Can you disconnect more COM-Ports?, What is the result than?
The usual way, searching the internet for "windows" "80010005" and perhaps "VBS"
leads to many type mismatch-errors.
I expect, that you have an device, where an NULL error is returned instead of some information, listcomports expects.
I really hate the way Arduino has implemented the solution with the two different VID/PID entries, depending in which state the DUE/DigiX is.
When a program is running, the DigiX has "2341:003E" and an associated COM-Port, e.g. COM10. When you now try to upload a new sketch, the only thing COM10 is used, is to trigger an erase followed by an reset, so that the CPU is starting in SAM-BA mode. In that case the VID/PID pair is: 03EB:6124, where Atmel is the owner of 03EB. For example on two of my boxes the DigiX is recognized as LEGO NXT brick in firmware update mode, because i have installed the LEGO-driver there.
As Windows reserves for each device an unique device name, 03EB:6124 will be recognized as e.g. COM14. That will change, when it is connected next time to another USB port!
So Arduino searches with listcomports.exe the devices, and takes the first one, it finds which has the VID/PID 03EB:6124.
Awful. When I tried to compare some issues between real DUE and two DigiX, my sketch went several times to the wrong device, when I have not disconnected the others before :-(
So I really like, what I am seeing in JTAG possibilities: http://digistump.com/board/index.php/topic,1275.0.html (http://digistump.com/board/index.php/topic,1275.0.html)
Here each device is tied to one serial port, which will even not go away, when the DigiX reboots! So it is very stable to the programming host!
Furthermore you need no fancy USB-serial port checking in the firmware, as the Original DUE firmware does every loop. You are able to reprogram a running device without any problem.
When you wish to use the USB port for your own programs, the port is 100% yours, you have not to take care, what to core firmware does.
Maybe the one or other will join, working on that way.
-
I deleted all COM ports from the device manager but it's still crashing ???
(http://i.imgur.com/gWR6tgq.png)
I also tried disconnecting all USB devices with the same result.
-
I have the same problem like Kaeltis. I also get the same error msg in listcomports.exe
Im using arduino 1.5.5 and your addon file 0.7
-
@balin:
That is just a problem with listcomports.exe and your specific hardware/software situation. The digistump addons don't play any role at this time.
I expect, that
@Kaeltis: I don't see a recent change in the github repository! So it looks like, that someone@arduino fixed something, but has not put it back to that repo.
If you have a chance to see the change, which was made for 1.5.4r2, you might see similar code situations, which need also an fix!
-
This is the change that should have fixed this:
https://github.com/todbot/usbSearch/commit/d78dc8150a8ad15c0a59e6b4610385c86618bbf7
-
Well, its not just listcomport... i cant get the digix to answer me on the serial usb port. I uploaded a sketch and get no answer on the com port.
When i try the serial0 port i get a answer but i tried the serverexample and after i send a key its just says Starting and nothing happens.
-
This is the change that should have fixed this:
https://github.com/todbot/usbSearch/commit/d78dc8150a8ad15c0a59e6b4610385c86618bbf7
Thanks! I have overseen, that this is so old! However, that shows, that really NULL was causing that issue.
What happens, when you enter "mode" on the command line?
With DigiX plugged in and with Digix not connected?
Looking to the code
dhGetValue(L"%s", &name, objDevice, L".Name");
dhGetValue(L"%s", &pnpid, objDevice, L".PnPDeviceID");
if(verbose>1) printf("'%s'.\n", name);
if( name != NULL && ((match = strstr( name, "(COM" )) != NULL) ) { // look for "(COM23)"
// 'Manufacturuer' can be null, so only get it if we need it
dhGetValue(L"%s", &manu, objDevice, L".Manufacturer");
port_count++;
char* comname = strtok( match, "()");
printf("%s - %s - %s\n",comname, manu, pnpid);
dhFreeString(manu);
}
dhFreeString(name);
dhFreeString(pnpid);
I would write it as:
dhGetValue(L"%s", &name, objDevice, L".Name");
if(verbose>1) printf("'%s'.\n", name);
if( name != NULL && ((match = strstr( name, "(COM" )) != NULL) ) { // look for "(COM23)"
// 'Manufacturuer' can be null, so only get it if we need it
dhGetValue(L"%s", &manu, objDevice, L".Manufacturer");
dhGetValue(L"%s", &pnpid, objDevice, L".PnPDeviceID");
port_count++;
char* comname = strtok( match, "()");
printf("%s - %s - %s\n",comname, manu, pnpid);
dhFreeString(manu);
dhFreeString(pnpid);
}
dhFreeString(name);
it seems, that they decided, to query only the manufacturer, when the devicename matches "COM"-ports. By reading the comment, it looks like, that there are devices out, which may have no manufacturer entry.
So I think, that querying pnpid should go inside the conditional part as well, as its not needed outside. However, if that is the problem, I have no clue.
I just remembered a tool, I found longer time ago, which lists com-ports on several ways: http://www.naughter.com/enumser.html
what is that tool telling?
-
I recompiled the code with your modification, but it still throws the same error.
I don't know much about C, but it only compiles if i remove "-std=c99" from the makefile (even the original code from github), so the code seems to violate some ISO standards.
(http://i.imgur.com/osTStQf.png)
mode - no DigiX:
(http://i.imgur.com/wFTUqvq.png)
mode - with DigiX:
(http://i.imgur.com/eqXbbeF.png)
EnumSer - no DigiX:
CreateFile method reports
COM1
QueryDosDevice method reports
COM1
GetDefaultCommConfig method reports
COM1
Device Manager (SetupAPI - GUID_DEVINTERFACE_COMPORT) reports
COM1 <Kommunikationsanschluss>
Device Manager (SetupAPI - Ports Device information set) reports
COM1 <Kommunikationsanschluss>
EnumPorts method reports
COM3
COM4
COM1
COM2
COM5
COM6
COM7
COM8
COM9
COM10
COM11
WMI method reports
COM1 <Kommunikationsanschluss (COM1)>
ComDB method reports
CEnumerateSerial::UsingComDB failed, Error:5
Registry method reports
COM1
EnumSer - with DigiX:
CreateFile method reports
COM1
COM4
QueryDosDevice method reports
COM1
COM4
GetDefaultCommConfig method reports
COM1
COM4
Device Manager (SetupAPI - GUID_DEVINTERFACE_COMPORT) reports
COM1 <Kommunikationsanschluss>
Device Manager (SetupAPI - Ports Device information set) reports
COM1 <Kommunikationsanschluss>
COM4 <Bossa Program Port>
EnumPorts method reports
COM3
COM4
COM1
COM2
COM5
COM6
COM7
COM8
COM9
COM10
COM11
WMI method reports
COM1 <Kommunikationsanschluss (COM1)>
COM4 <Bossa Program Port (COM4)>
ComDB method reports
CEnumerateSerial::UsingComDB failed, Error:5
Registry method reports
COM1
COM4
-
Almost clueless.
The only thing, I can imagine, is to reduce the printf statement like:
printf("%s \n",comname);and remove the two dhGetValue statements.
When the error still exists, it must be something in the disphelper-library.
On my systems, where the program works, the output of EnumSer is similar. Especially I receive the same error
UsingComDB failed, Error:5
CreateFile method reports
COM1
COM2
COM12
QueryDosDevice method reports
COM1
COM2
COM12
GetDefaultCommConfig method reports
COM1
COM2
COM12
Device Manager (SetupAPI - GUID_DEVINTERFACE_COMPORT) reports
COM1 <Kommunikationsanschluss>
COM2 <USB-SERIAL CH340>
Device Manager (SetupAPI - Ports Device information set) reports
COM1 <Kommunikationsanschluss>
COM2 <USB-SERIAL CH340>
COM12 <Bossa Program Port>
EnumPorts method reports
COM1
COM2
COM4
COM5
COM6
COM7
COM8
COM9
COM10
COM11
COM12
COM13
COM14
COM15
COM16
COM17
COM18
COM19
COM20
COM21
COM22
COM23
COM3
WMI method reports
COM1 <Kommunikationsanschluss (COM1)>
COM12 <Bossa Program Port (COM12)>
ComDB method reports
CEnumerateSerial::UsingComDB failed, Error:5
Registry method reports
COM1
COM2
COM12
-
I started stripping parts from the code,
FOR_EACH(objDevice, colDevices, NULL) {
char* name = NULL;
char* match;
dhGetValue(L"%s", &name, objDevice, L".Name");
/*
if( name != NULL && ((match = strstr( name, "(COM" )) != NULL) ) { // look for "(COM23)"
port_count++;
char* comname = strtok( match, "()");
printf("%s \n",comname);
}
*/
dhFreeString(name);
} NEXT(objDevice);
This STILL throws that error, but only until i remove
dhGetValue(L"%s", &name, objDevice, L".Name");
So it seems to be this line/method thats causing the problems.
Maybe we need to check "objDevice" before we hand it to that method, to make sure it can handle it, just checking for != NULL doesn't seem to work.
I guess objDevice has to be "instanceof" IDispatch but i really don't know enough about C xD (so this idea might be totally wrong)
-
OK, but without that line, you can't identify, what is an COM-Port.
Do you have Powershell installed on your system?
This script should do the same enumeration:
$colItems = get-wmiobject -class "Win32_PnPEntity" -namespace "root\CIMV2" -computername "."
foreach ($objItem in $colItems) {
if ( $objItem.Name -like "*COM*" ) {
write-host "Name: -" $objItem.Name "-"
write-host "PNP Device ID: " $objItem.PNPDeviceID
write-host
}
}
-
Seems to work perfectly:
(http://i.imgur.com/FRbx8MA.png)
Posted an "official" issue, maybe someone there knows how to fix this.
https://github.com/arduino/Arduino/issues/1818 (https://github.com/arduino/Arduino/issues/1818)
Edit: Oh great, the "listComPorts.exe" can't be the cause of my problem because it's disabled and just a leftover :-\
-
I have no further idea.
Edit: The interesting question is, if that problem is the same, causing your communication problem, or if there are two independent problems.
-
i cant get the serialusb(serial) working either. So i just use Serial0 for all of my tests and have no problem with it. Maybe you can use this one in the meantime as well for your testing.
And just make sure when you use the wifi module, that the wifi module has the same Baudrate set then you use in wifi.begin(115200); ! This was the fault, why i couldnt get the ServerExample running.
-
Oh well, maybe digistump has some more ideas, but still, thank you very much for your help gogol.
@balin what do you mean with Serial0? Just Serial?
-
(http://i.imgur.com/PxC7pcS.jpg)
no these pins are accessable through the Serial0 command so i just replaced all Serial commands with the Serial0 and used USB to RS232 TTL UART Konverter Module.
The Konverter looks something like that: (http://deih.merchantrunglobal.com/ImageHosting/ViewImage.aspx?GlobalID=1004&MerchantID=11352&ImageID=1702&DisplaySize=-1)
-
Thats a really good idea, even have one of those here ;D
Settings for Board/Programmer/... are all the same?
-
yes i changed nothing else. used digix standart leave programmer where it was and just replaced the Serial commands.
-
This is the converter i have got here:
(http://i.imgur.com/pLKYnRF.png)
So i just connect GND to GND, 5V to 5V, TX to TX, RX to RX and RESET to RESET?
Whats with that unlabeled pin? Does the 5V work with the 3.3V DigiX?
(dont want to fry anything)
-
i only used rx (rx to rx) and tx (tx to tx) the konverter should get the power over usb maybe connect gnd (gnd to gnd) also ^^.
-
Are you uploading the sketch directly or via the converter? cant get it to work oO
-
im uploading the sketch over the usbserial port.
but to get debug infos and so on im using the Serial0 port, cause my serialusb dont work.
-
You should not connect this adapter direct to the board, as that has true 5V on RX and TX, because RX and TX are PINs from 8U2
http://arduino.cc/en/Main/USBSerial (http://arduino.cc/en/Main/USBSerial)
If you have the level-shifter, that should do it, maybe digistump will tell something to it!
That adapter, balin showed, has 3.3V on the serial communication lines.
Those adapters use an CP2104 (which is the successor of the CP2102), there are other adapters out, using the FT232R, Maxim and other companies have also some of those out.
The cheap (slow) adapters are available via ebay aliexpress and others for about $2-$4.
If you wish to spent little more money, have a look at the FT232H http://digistump.com/board/index.php/topic,1127.0.html
That device works a multiple devices in one. Its a normal USB-Serial to TTL (like the cheap adapters above) and also and HIGH-speed-serial protocol adapter, speaking native I2C, SPI, JTAG and others.
The big difference between the CORE-USB-to-serial-TTL adapters and the Arduino-Adapter is as following:
The CORE adapters are just a TTL-based UARTs, running the TTL-level protocol on the pins:
(http://commons.wikimedia.org/wiki/File:RS-232_timing.png)
I hope, that the few german words in the picture above are understandable for all readers.
The Arduino-Adapter works different: The 8U2 (or 16U2 ...) connects with the built-in USB interface and simulates an virtual COM-Port on top of the USB protocol.
This happens over the Abstract Control Model (ACM) , which is defined in the USB Communication Device Class (CDC). Electrical communication is here USB.
On the atmel-CPU is a program running like a proxy: It accepts data from the virtual USB-COM-Port and output that to the serial port (which is therefore 5V) and via versa.
The proxy-program has some specialities: For example, when it discovers that the virtual com port is opened and closed with 9600 baud, it triggers the reset of the SAM3X.
The 16U2 on the Arduino DUE works slightly different, as this triggers not only RESET but also ERASE.
Those Arduinos, which have an FTDI-chip on board, are triggering the reset via the DTR-signal, which is connected via an 100nF capacitor to the reset-line, which is itself pulled high via an resistor.
To avoid the native port programming, you have the following possibilities:
Use an cheap USB-TTL-serial adapter. In that case you have to press ERASE/RESET before each upload yourself
Use something like the above mentioned 8u2/16u2 solution. Make sure that the 8u2/16u2 are running with 3.3V and adapt the Arduino-Firmware.
Unfortunatley the ERASE-Pin is not connected to any breakout-PIN (http://digistump.com/board/index.php/topic,1216.msg5818.html#msg5818 (http://digistump.com/board/index.php/topic,1216.msg5818.html#msg5818))
The third possibility is working via JTAG, which is one task, I am working currently on (http://digistump.com/board/index.php/topic,1275.0.html (http://digistump.com/board/index.php/topic,1275.0.html))
-
Ouh damn i didnt look on the voltage. but gogol is right this one uses 5V on rx tx lvl
-
The FT232H sounds awesome but also awfully complicated as i don't want to break anything and have no knowledge about JTAG at all.
Maybe digistump (or someone else) can find a solution so I can just use the native USB port or maybe you could create a noob-tutorial in the future on how to use the FT232H with the DigiX/Digispark.
For now i'll just wait until my new SSD arrives and see if it works with a fresh windows installation.
-
tell me if the native serial over usb port is working then. cant get it to work on my side either...
-
After a complete reinstallation of Win 8.1 x64 I still have the same problems, also, "listComPorts.exe" is still crashing.
-
Do you have the chance, to boot a linux rescue system from CD/DVD/USB-stick on that box?
-
Given the reply here: https://github.com/arduino/Arduino/issues/1818 - that you noted it seems listComPorts.exe doesn't play a part in this because it is not in use by the IDE (we don't do anything different than the Due Native Port when it comes to the USB stuff - we only changed the VID/PID)
So it seems like the root of this is the Arduino IDE COM port enumeration code - does that sound right? - which leaves me at a loss because I can't reproduce this issue to even try to fix it (tried 3 machines running 8.1).
-
@gogol
i tried x64 Ubuntu but the compiler seems broken there because of some missing 32bit librarys, gonna try x86 Ubuntu later.
@digistump
is there anything I can do to help fixing this problem?
-
Still nothing new? :(
Can barely use it without Serial debugging.
-
just to reiterate:
you are able to upload code. That means, that at least in SAM-BA mode the COM-port seems to work.
Which board are you selecting: The DigiX or the native Arduino DUE?
I would recommend for testing purposes to stay with the Arduino DUE variant, as that should be 100% compatible, and we make sure, that the problem has nothing to do with the digistump extensions.
When a sketch is running, and the board is in Arduino mode, is it possible to reset the board, by opening a 1200 8N1 serial connection?
Next try: Is it possible to emulate a keyboard with a simple sketch? Will your host recognize the DigiX as working keyboard?
To the problems with listComPorts.exe: Is that failing when the DigiX is in DigiX/Arduino mode AND/OR when it is in SAM-BA mode?
Do you have another DigiX/Arduino Due you can borrow for a test?
-
I always used the DigiX Setting before, for further testing i'll be using "Arduino Due (Native USB Port)".
Btw. I'm using the MicroUSB cable of my Kindle Touch which is working perfectly with the Kindle and also worked with the DigiX on a MacBook.
Yes, the board resets by opening a 1200 8N1 serial connection.
Using this sketch my mouse pointer jumps up and down just fine (sending keyboard key presses to the computer also works):
void setup() {
Mouse.begin();
}
void loop() {
Mouse.move(0, -40);
delay(1000);
Mouse.move(0, 40);
delay(1000);
}
listComPorts.exe fails, even if not a single USB device is plugged in.
I don't know anyone with a DigiX/Due :-\
Thank you so much for still trying to help me :) i hope we can find the problem ;D
One more thing i noticed, with this sketch
int led = 13;
void setup() {
pinMode(led, OUTPUT);
SerialUSB.begin(9600);
}
void loop() {
digitalWrite(led, HIGH);
SerialUSB.println("1");
delay(1000);
digitalWrite(led, LOW);
SerialUSB.println("0");
delay(1000);
}
The onboard LED blinks, but as soon as i open the serial monitor the LED keeps its current state and stops blinking, even if i close the monitor again, so the DigiX seems "locked up" in it's current state.
Connecting with a Terminal program (HTerm) doesn't cause this (but with the terminal program i can reset the board with 1200 8N1, so i suppose the program is working).
Without the SerialUSB parts, opening the serial monitor also doesn't cause the "lock up"
-
That's very interesting!
I assume, that the program is not longer running, but being stuck somewhere in the serial CDC stack.
The erase/flash however still works, because that is triggered via interrupt in ./hardware/arduino/sam/cores/arduino/USB/CDC.cpp (http://digistump.com/board/index.php/topic,1297.msg5844.html#msg5844).
The curious thing is here, that only parts of the USB-stack (I assume something like flow-control) is broken, as the the CORE USB functionality is given (SAM-BA upload works).
As parts of the Arduino stack are also working (HID mouse, erase/reset event), the problem seems to be deeper.
Its almost for sure no general Arduino<->Windows 8 problem, as I assume, that others might report that as well. However, as most Arduino DUE users are using the programming port, there is no such big pressure, to track the errors down. (Assuming, that this problem only occurs between the SAM-USB-stack and Windows, as the programming port of the DUE uses the AVR-USB-stack)
As you had the DigiX running on a MacBook, I assume, that it worked there ?
Which would be another valuable piece of the puzzle!
I recapitulate (correct me, when some assumptions are wrong)
- DigiX connected to PC with Windows 8.1 x64
- DigiX can be programmed via USB
- ERASE/RESET works, when COM is connected with 1200 8N1
- HID mouse examples are running, mouse is detected
- extended blink-sketch, which is outputting the LED state between blinking via SerialUSB.println() is stuck, as soon, as terminal program connects
- sketch is still stuck, when terminal-program is detached
- sketch is running again, after reset
- ERASE/RESET via 1200 8N1 connection is recognized even in stuck state!
Some more observations? Something wrong?
Where are the USB gurus?
-
Yes, on the MacBook everything worked perfectly
Some additions:
- I'm not sure if the DigiX is shows up as a Mouse in Device Manager (didn't find anything obvious, only DigiX/Due in COM-Ports), but the mouse example was working.
- The DigiX only gets stuck with the Arduino Built-in Serial Monitor, HTerm doesn't get it stuck but gets no Data output from the DigiX as well
- When pressing the onboard RESET button, the sketch works fine again after being stuck
- Interestingly, when pressing the RESET button (DigiX is on COM5), windows makes the "device disconnected" sound and the DigiX stops being shown in the Arduino software unter "Ports", but it's still shown in the Device Manager as COM5. After reseting I also can't reprogram it without reconnecting it physically, arduino always shows the Error "Board at COM5 is not available" (altough its still shown in device manager as COM5).
Everything else is correct.
(http://i.imgur.com/5qHm6ax.png)
-
Having the DigiX<->MacBook combination running, we can almost exclude hardware issues. One try could be external power to the DigiX before USB connection, to make sure, that its not a voltage/power issue.
Its strange, that the COM-Port is not disappearing; that may be related to the listComPorts.exe problem.
What happens, if you connect the DigiX in Arduino-state with running sketch, than you press ERASE and RESET? Is than the SAM-BA comport appearing and the Arduino COM-port disapperaring?
The SerialUSB library seems to have at least optimization potential: http://forum.arduino.cc/index.php?PHPSESSID=a7oct56k8taij56pn0717u7184&topic=143871.msg1533427#msg1533427
You might want to try the discussed alternative files (even when the initial problem there was RX).
Edit:
You should see in in the device manager an USB-Input Device ("USB-Eingabegerät") with the Arduino VID_2341 PID_003E. That should disappear in SAM-BA mode and while RESET is pressed!
-
Yes, ERASE and then RESET removed the Due (COM5) and shows Bossa Program Port (COM4)
I'll try with external power later, as soon as i find my power supply
Edit: yes, the mouse shows up with that hardware ID, while i press RESET it's removed
Edit2: Can't find a suitable power supply atm :\
-
I just noticed more weirdness.
I programmed the DigiX as "Due (Native USB Port)" on COM6 with this Sketch:
void setup() {
SerialUSB.begin(9600);
}
void loop() {
int sensorValue = analogRead(A0);
SerialUSB.println(sensorValue);
delay(1);
}
and got, as i expected, no output in the Serial Monitor.
I then changed all "SerialUSB." to "Serial." and switched the Board Setting to "Digistump DigiX (standard)".
After flashing the program, clicking on the Serial Monitor gave me the error "Board at COM6 is not available".
The COM Port changed from COM6 to COM8, which should be normal as the boards USB-ID thing changed by switching to "DigiX-Mode".
I then selected COM8 in the Arduino IDE and clicked Serial Monitor again (without unplugging the board or anything else) and voila, i got Serial output from the DigiX.
After physically reconnecting the DigiX i'm again getting no output, nothing else changed.
Edit: this is not repeatable, i think this just happened because Windows detected the DigiX as a new device when changing from Due-Mode to DigiX-Mode.
My conclusion: It works every time Windows detects it as a new Device (either by changing the USB-ID or deleting it from device manager) but only until it resets or gets reconnected. But why?
Both the Arduino serial monitor and an external serial programm are working with this method.
The Arduino serial monitor in particular is NOT the cause of this issue, it seems to be a general problem with the Serial connection.
Maybe it's because of the way Windows handles unsigned drivers? When installing the DigiX driver i had to enable unsigned driver mode in the Win8.1 boot menu.
-
I can't believe, that this is an general Windows 8.x problem. Otherwise I expect more reports, as well in the Arduino-forum.
There are changes in the Windows USB stack, but not related to those modules/functions the DigiX/Due uses.
http://msdn.microsoft.com/en-us/library/windows/hardware/ff538820%28v=vs.85%29.aspx
http://msdn.microsoft.com/en-us/library/windows/hardware/hh406292%28v=vs.85%29.aspx
However I would check with external power provided to the DigiX before making USB connection. At least disabling WiFi.
I have one computer, where the DigiX is unstable while plugged only to USB with Wifi up.
@All readers: If you are using the DigiX with Windows 8 / 8.1 can you try the second sketch from this post: https://digistump.com/board/index.php/topic,1277.msg5939.html#msg5939
Can you report back, if it is working for you, and which version of Windows 8.x (x32/x64) you are using.
-
I have seen a couple of similar issues on Win7 64. Some I attribute to the multiple USB serial devices I plug in and out. Several Leonardos, DigiX's, Dues etc. Most issues seem to relate to the two phase enumeration. One device enumeration when the board is programmed (Atmels ID?) and the other when the serial monitor port enumerates. I am up to COM44. You should check the registry HKLM\HARDWARE\DEVICEMAP\SERIALCOM to see how you device enumerates. You may want to re-install USB drivers for the ports seen in the registry. I have also had issues with USB hubs, are you using a hub? Lastly, be sure to always plug in to the same USB connector on your computer/hub. It makes COM port numbers consistent when you plug in multiple devices. I also have SAM-BA 2.12 and Atmel studio installed. They may have updated the USB drivers, I can't tell you for sure.
-
I'm using always the same usb port directly on my motherboard and only got the DigiX in "SERIALCOMM"
(http://i.imgur.com/11nY3ru.png)
Just installed the new Arduino 1.5.6-r2 BETA but it didn't fix the problem.
-
O M G i can't believe it, i FINALLY found the cause of my problem!
I tried to use my TI MSP430 Launchpad with Energia, but got an error when trying to upload code: No unused FET found.
I searched for a possible fix and found this thread: http://e2e.ti.com/support/microcontrollers/msp430/f/166/p/290981/1015186.aspx
I disabled the "Logitech Gaming Software" i'm using for my G19s and my G700 and the error was gone.
Being curious, I plugged in my DigiX and finally everything worked, including the Serial Monitor.
(listComPorts.exe still crashes, but doesn't matter as it's not used by the Arduino Software)
Serial output stops in the second i'm enabling the LGS, so it's definitely the cause.
Thank you so much everyone for helping me :)
I'm adding the LGS as a potential cause of problems to a troubleshooting section in the wiki, hope thats ok.