Installing the USB Driver on Windows & Serial Debugging

Actually the Arduino IDE does perform an Arduino AutoReset each time the a sketch is about to be uploaded or Serial Monitor gets started.
This is achieved by pulling DTR to LOW, which fortunately happens implicitly when an USB-Serial connection gets initiated (at least for Linux, MacOS and in my case on a Win8 tablet, too).
I don’t know if the Core would react to this the same way, but it might be a feature for future Core designs if not already implemented.

I’ve installed the driver as i’m meant to, but whenever i go to putty and try to open the port (while it’s flashing blue) i just get a beep from my pc suggesting its not going to let it happen but nothing pops up to say why.

I had the same issue and kind of just gave up on it for the moment… but I’m really wishing I had Serial debugging over USB right about now.

Just got it working with Arduino. It appeared to be easy and i dont have a clue what im doing, just here to tinker! I’d give up on Putty and download arduino and do as above.

I don’t have a problem flashing new firmware with a Putty console connected. However, if you leave the console open, you’ll have a hard time getting reconnected! If I close the Putty console BEFORE the core completely reboots, I’m fine. If, however, the Spark serial com port is initialized while the old console is still open, (I suspect this is what you’re talking about), then you are indeed a bit stuck.

One workaround is to open the device manager (I’m in Win7), right click the Spark Serial COM port and select “Disable”. You’ll hear the USB “fail” tone (I think three low tones?). Then right click and select “Enable”. You should hear the USB connection tone (low high). I am then able to reconnect with Putty without having to reset the Spark.

Dave O

1 Like

I’ll have to try that @dorth , but I couldn’t even get Putty to work with my FTDI friend (TTL Serial) device hooked to the TX pin and GND on the Core. It works perfectly in the Arduino IDE’s serial monitor, but Putty just makes a computer “beep” anytime I try to open a serial port. I think I spent about 30mins this morning messing with it, and searching the web. I couldn’t really find a good reason why it just “beeps” and doesn’t connect. The Arduino IDE is ok, but that’s kind of more memory hogging than I want for just a serial monitor.

In my opinion… Serial debugging over USB should be a fairly high priority to get working well for everyone… because once you go a little beyond dead simple programs, you need visibility of your code variables and execution state to figure out why something isn’t working. I’ve always loved real time debugging ability that about the Arduino provides, something even the fancy expensive Microchip dev tools can’t do. Even if you set up a UART on your PIC uC, the Real ICE and ICD3 and MPLAB IDE can’t handle monitoring the data, even though it’s already connected to the computer via USB.

2 Likes

Any workaround for people on Win 8/8.1? Since the driver isn’t digitally signed, can’t use it unless you disable the verification.

Just disable it, its not that hard to do, takes 10seconds really.

If you trust the author, The Spark Team… then proceeding with an unsigned driver is not a big deal. Just click Install This Driver Software Anyway. It’s only $300 - $400 dollars to get a driver signed so eventually I would think they would be signed but in this early stage it’s probably not wise to spend the money.

10 secs? Could you elaborate how?
The method I found required 2 reboots.

@BDub Yep - I know it’s a waste of money getting the drivers signed, just looking to see if there is a workaround - didn’t feel like 2 reboots in the middle of work.

Oh you’re on Win8… sorry I’m staying far away from 8 at the moment. Win 7 Ultimate all the way! Hopefully @Narom will chime in with his tricks.

Probably embellishing a bit, but i’ve got an SSD, booting to desktop takes me 6 seconds.

But in metro, type advanced startup options, click restart, then just press i think was number 7 to boot without driver enforcement,boots back in and then just install the .inf file.

1 Like

@DBub: I’m totally with you. I think there are (besides debugging) a lot of scenarios where you have a laptop connected for Serial.print-logging with beta firmware running, but you want to do remote flashing without running to the core to reset it after flashing, and/or even restart putty or Hyperterminal for logging.

All I am getting with the Spark plugged into USB in listening mode is “Unknown Device” on the USB controller instead of anything looking like a Spark device. The root problem of this being that Windows 7 64 will not look at the spark driver at all. Have tried numerous times with numerous ports and numerous resets on the Spark.

Since the Android app is still yielding a “No cores found.” even after the Spark successfully connects to internet (breathing cyan), I am very stuck! Any suggestions? Thanks in advance!

@Craigjones
I know this may not sound like the idea solution, but do you have access to any other computer with a different operating system to try on?

Some other things to try:

  1. If you connect and disconnect the Core from a windows computer numerous times, its advisable to restart the PC
  2. Always make sure that you have the RGB led flashing blue - indicating that its in the smart config mode and therefore will show up on the PC as a serial port.

As far as the Android app goes, were you able to claim your core?

Thanks for the info, but have worked through everything pretty systematically (computer reboots, different computer, ensured RGB is flashing blue, reset the Spark) and always get “unknown device” under USB devices on the hardware manager.

Wasn’t able to get the core claimed with android. Its sending the network info fine and connects up to a breathing cyan status, but Android (HTC One with Android 4.3) gives “No Cores Found” even while cyan breathing; hence, trying to connect via USB.

Any other thoughts? Please don’t tell me I have to go admit failure to a friend running iWhatever :wink: Thanks again.

Bumping this thread because I’m having an issue similar where one of my cores would not connect to the cloud so I performed a factory reset on it. Now I’m trying to get a serial connection open to it so I can reenter my SSID and password - but the core only shows up as Unknown Device in the device manager. This has not happened previously.

Reboots, different usb ports, all resulting in unknown device. The core is flashing blue.

Any ideas?

Figures as soon as I ask for help I get it working. Turns out it was the USB cable.

2 Likes

@Craigjones
Were you able to resolve the issue by changing the USB cable as well?

No matter what I try on Windows 7 Professional 32-bit, I cannot get my serial over USB to work for debugging programs.

I can only make it work when the Core is in listening mode (slow blue flash).

Any time I try to use the Arduino IDE’s serial monitor or Tera Term VT, it complains that the port is in use already. Putty just dings at me and doesn’t work for squat even with my FTDI Friend. FTDI friend works on Arduino IDE serial monitor and Tera Term VT pretty well!

Another thing I noticed with the USB serial driver. When my Core is connected to USB and the spark_core.inf driver is loaded, if I plug in a USB drive my system will not recognize it until I unplug my Core. Likewise if I load the USB drive, and then plug in the core and THEN unplug the USB drive, windows will not update and show me that the USB drive has been removed until I unplug the core. It’s like the spark_core.inf driver is completely taking over the usb. What’s the deal with this?

BTW I have ditched the Spark Core cable and have been using a different one just in case that is the problem. I don’t think so though because it does work in listening mode. FWIW, my spark core cable never worked in listening mode.

I have also tried disabling the spark_core.inf driver after booting the core, opening Tera Term VT, and then re-enabling the driver. However… for some reason when I go to disable the driver, it just hangs forever with the hour glass symbol. If I disconnect the core from my computer the hour glass goes away and the driver gets disabled. So that’s not going to be a good work around for me :smile:

I have also tried delaying the beginning of Serial.begin(9600); for 20 seconds, at least I think it might work… but for the life of me today I cannot get my core re-flashed from the cloud to try it. It always hangs at some point during the programming and I get a solid magenta or LED off. After a minute it will reset itself and boot with the last known good app.

Here’s the 20s delayed app:

int counter = 0;
bool serial_enabled = false;
uint32_t lastTime = millis();
void setup()
{
  pinMode(D7,OUTPUT);
}
    
void loop() 
{
  if(millis() - lastTime > 20000) {
    Serial.begin(9600);    // open serial over USB
    serial_enabled = true; // enabled! Let's start logging!!
  }
  if(serial_enabled) { 
    Serial.print("Spark Core says Hello over USB! ");
    Serial.println(counter++);
  }
  digitalWrite(D7,HIGH);
  delay(100);
  digitalWrite(D7,LOW);
  delay(100);
}

I’d love some help getting Serial over USB working!