Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

USB compatibility with Windows #742

Closed
gdibble opened this issue May 16, 2016 · 35 comments
Closed

USB compatibility with Windows #742

gdibble opened this issue May 16, 2016 · 35 comments

Comments

@gdibble
Copy link

gdibble commented May 16, 2016

I'm teaching 100 60 kids on Node.js/Tessel2 in a few weeks and can only get Windows laptops for all the kids. Mac works great but I can't arrange that many OSX systems. I've built out projects for the students, but the dark ☁️ cloud is nothing happens w/o working systems for coding.

Having a lot of trouble with Windows. t2-cli reports it isn't installing the usb drivers. Of course this is the same issue others report - the cli just reports "Detected a Tessel that may be booting. No Tessels found."
I read all the threads over the weekend and tried everything here from the custom/old usb branches and firmware (thanks for those, jon) to WinUSB driver install, node x86 and x64 v4.2.6, v4.4.4, v5.1.0, v6.1.0, etc etc etcetera.

That was on a Win10 box over the weekend. Today I'm sitting here with a colleague trying the same things with Win7. Not luck yet 😿

If there's a secret recipe for Windows or an unreleased update to help, please post anything.

@gdibble
Copy link
Author

gdibble commented May 18, 2016

I've extensively tested this on win7 and win10, node 0.10.3-x86, 0.12.0-x86, 4.2.6-x64, 4.4.4-x64, 5.5.0-x64 and 6.2.0-x64
https://gist.github.com/tcr/992978a5dbe5bff2e18f495c5c0973c3
Same error as the others (see below)

Seems to be the proper DFU id per referece in link above - -d 1209:7551
image

Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
No DFU capable USB device available
child_process.js:507
    throw err;
    ^

Error: Command failed: dfu-util-static.exe -a0 -d 1209:7551 -D firmware-winusb.bin
Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
No DFU capable USB device available

    at checkExecSyncError (child_process.js:464:13)
    at execSync (child_process.js:504:13)
    at Object.<anonymous> (C:\Users\Gabriel\Downloads\Tessel 2\t2-windows-fix\driver-install.js:8:13)
    at Module._compile (module.js:413:34)
    at Object.Module._extensions..js (module.js:422:10)
    at Module.load (module.js:357:32)
    at Function.Module._load (module.js:314:12)
    at Function.Module.runMain (module.js:447:10)
    at startup (node.js:139:18)
    at node.js:999:3

@gdibble
Copy link
Author

gdibble commented May 20, 2016

🎉 Good news!

We got our windows 7 and windows 10 laptops detecting the Tessel 2 and running blinkie.
Here's what we did:

  1. Install LTS v4.4.4 from http://nodejs.org
  2. Get the zip file https://gist.github.com/tcr/992978a5dbe5bff2e18f495c5c0973c3
  3. Run node driver-clean.js
  4. Plug in Tessel 2
  5. Get Zadig - http://zadig.akeo.ie/ and run it, which should show the Tessel 2; simply click the install WinUSB button w/o changing anything - If you go to Device Manager, you should now notice that the three Tessel devices which previously had an ❗ are now ok w/ the WinUSB driver
  6. Run cmd as Administrator
  7. Run npm i -g t2-cli
  8. Run t2 list which should show the USB connection
  9. Do the rest... http://tessel.github.io/t2-start/
  10. Rejoice 💃 💃 🎊 💃 💃 🍻 etcetera 😉

@rwaldron
Copy link
Contributor

Dude... This is heroic!

@johnnyman727
Copy link
Contributor

This is really fantastic, thanks @gdibble. Tagging @tcr so he's aware.

@dcustodio
Copy link

Thank you @gdibble ,finally got my tessel working!

@gdibble
Copy link
Author

gdibble commented May 20, 2016

(: Thanks everyone --- @dcustodio that makes me happy

@Coder2012
Copy link

Coder2012 commented May 20, 2016

Everything was fine up to step 8 and it said No tessels detected.

I unplugged the tessel2 and plugged it back in and it just installed the drivers itself, amazing! @gdibble I love you man!!!

@gdibble
Copy link
Author

gdibble commented May 23, 2016

🎉 on a side note: one goodie of many more coming soon ... tessel-toggle-power

@gdibble
Copy link
Author

gdibble commented May 25, 2016

@rwaldron @johnnyman727 @dcustodio @Coder2012 hey thanks guys, i'm so happy to have helped

@wmmihaa
Copy link

wmmihaa commented May 25, 2016

Not working for me :(
I get:
INFO Searching for nearby Tessels...
WARN Detected a Tessel that may be booting.
WARN No Tessels Found.

I also gave this (https://gist.github.com/tcr/992978a5dbe5bff2e18f495c5c0973c3) option a try but it failed too.

@wmmihaa
Copy link

wmmihaa commented May 26, 2016

I got it working after installing the driver (using Zadig) in DFU mode.

@gdibble
Copy link
Author

gdibble commented May 27, 2016

Nice job @wmmihaa! Would you mind posting some details: Version of Windows, Version of Node.js, sequential steps to your success?

I am hoping we can use successes to 1) correlate the key steps, 2) help others.

Here's what we did on 15 or more Windows 7 systems today for the class - and just to note, I verified that Node.js LTS 4.4.5 works fine as well,
Same steps as above were rougly prior-applied, so we verified each:

  • If T2 usb connected but unsuccessful t2 list:
  • unplug, run aformentioned node driver-clean.js
  • run zadig, plug in, click Install WCID driver btn
  • t2 list 👍

@wmmihaa
Copy link

wmmihaa commented May 27, 2016

@gdibble I ran it on Win10 x64 with node 4.4.5. I could not get it working using Zadig after connecting the board. I could install the driver, but when running t2 list all I got was a message saying it might be booting up.

I then tried the same process but starting the board in DFU mode and success :)

@gdibble
Copy link
Author

gdibble commented Jun 1, 2016

#awesome feedback, thx @wmmihaa

@gdibble
Copy link
Author

gdibble commented Jun 1, 2016

btw our 2nd Nodejs class + #NodeBots w/ Tessel 2 went awesome
This bright student's feedback really sums it up: "I think my favorite part about the workshops was the platform, or rather the way you presented them. You kinda said "Here's what you need to do, we will help you get there." It allowed kids to work at their own pace, regardless of previous computer science experience. I myself took away not only the actual coding we learned, but also how to apply it to real situations. I actually had never taken a formal computer science class, and the program familiarized me with node, and "real life" applications for computer science in general."

Here's all the code that they worked on and we made public to share with others doing the same:
https://github.com/gdibble/caa-nodeTraining

image

@johnnyman727
Copy link
Contributor

@gdibble super glad to hear that!

With regards to this issue, I think we should keep it open until we have a one line command to run to restore "tainted" computers that have the old drivers.

@johnnyman727
Copy link
Contributor

I'm going to close this because it's unlikely we'll have the time to build a temporary command to fix Windows machines with old device drivers. If anyone is still hitting this, please follow the instructions posted above to fix.

@dcustodio
Copy link

not sure if the problems are old drivers, I had the exact same issue with a brand new windows 10.

@gdibble
Copy link
Author

gdibble commented Aug 10, 2016

Closing reduced visibility of these steps to almost zero

@johnnyman727
Copy link
Contributor

@gdibble how so? Would you be content with me locking the thread and adding a comment with the link at the bottom?

@gdibble
Copy link
Author

gdibble commented Aug 12, 2016

@johnnyman727 I only say that because those of us who use github often understand to search closed issues and we are familiar with finding things which may be hidden or obscured by the issue-status/etc. Unfortunately ppl unfamiliar with github or searching the web may not be as lucky to find the closed issue. I'm just thinking of reaching as many ppl who may need help. ;)

@jandrieu
Copy link
Contributor

This mostly worked. But then I upgraded the firmware with t2 update going from 0.11 to 0.13.

Now t2 list crashes loading USB:

C:\Users\Joe\Documents\Software\Tessel>t2 list
INFO Searching for nearby Tessels...
ERR! Detected CLI crash { [Error: LIBUSB_TRANSFER_STALL] errno: 4 } Error: LIBUSB_TRANSFER_STALL
ERR!     at Error (native)
INFO Crash Reported: http://crash-reporter.tessel.io/crashes?fingerprint=-0x21dc75d3
-

However, reinstalling the USB drivers with Zadig seemed to fix it. I guess that makes sense, but it would be useful to have that documented somewhere. I was hoping the firmware upgrade would have some fixes for the Windows issues and was sad it momentarily made it worse.

@gdibble
Copy link
Author

gdibble commented Aug 19, 2016

Hi Jon,
I'm just looking out for those who need help
Hope you have a Happy Friday

On Fri, Aug 19, 2016 at 3:53 AM Joe Andrieu notifications@github.com
wrote:

This mostly worked. But then I upgraded the firmware with t2 update going
from 0.11 to 0.13.

Now t2 list crashes loading USB:

C:\Users\Joe\Documents\Software\Tessel>t2 list
INFO Searching for nearby Tessels...
ERR! Detected CLI crash { [Error: LIBUSB_TRANSFER_STALL] errno: 4 } Error: LIBUSB_TRANSFER_STALL
ERR! at Error (native)

INFO Crash Reported: http://crash-reporter.tessel.io/crashes?fingerprint=-0x21dc75d3

However, reinstalling the USB drivers with Zadig seemed to fix it. I guess
that makes sense, but it would be useful to have that documented somewhere.
I was hoping the firmware upgrade would have some fixes for the Windows
issues and was sad it momentarily made it worse.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#742 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/AA3WXkqYkOwEXiwmKEpwDem_psIfOecdks5qhYsagaJpZM4IfuOb
.

@johnnyman727
Copy link
Contributor

@jandrieu sorry that you ran into that. My suspcision is that it wasn't the firmware update itself that caused the USB issue. Can't help very much on investigating at the moment.

@gdibble I understand and I appreciate the feedback. I'll keep this open for now since folks are still encountering it.

@johnnyman727 johnnyman727 reopened this Aug 19, 2016
@Arrow7000
Copy link

I followed all the instructions but then got the below error when trying to run node driver-install.js

Just to confirm, this is the reset button? I couldn't find a diagram anywhere online so went for the only button I could see. However it still apparently didn't enable DFU mode. Maybe there's another reset button somewhere, extraordinarily well hidden?

Any help would be appreciated.

img_2685 1


 C:\Users\Aron\Google Drive\My files\Downloads\t2-windows-fix\t2-windows-fix>node driver-install.js
note: make sure t2 is in dfu-util mode (hold down the reset button while plugging in)

Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
No DFU capable USB device available
child_process.js:507
    throw err;
    ^

Error: Command failed: dfu-util-static.exe -a0 -d 1209:7551 -D firmware-winusb.bin
Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
No DFU capable USB device available

    at checkExecSyncError (child_process.js:464:13)
    at execSync (child_process.js:504:13)
    at Object.<anonymous> (C:\Users\Aron\Google Drive\My files\Downloads\t2-windows-fix\t2-windows-fix\driver-install.js:8:13)
    at Module._compile (module.js:409:26)
    at Object.Module._extensions..js (module.js:416:10)
    at Module.load (module.js:343:32)
    at Function.Module._load (module.js:300:12)
    at Function.Module.runMain (module.js:441:10)
    at startup (node.js:139:18)
    at node.js:968:3

@johnnyman727
Copy link
Contributor

@Arrow7000 did the blue LED start blinking at 1Hz when you plugged it in with the button pressed firmly? That would indicate that it is in DFU mode.

@reconbot
Copy link
Member

That is the reset button.

@Sygyzmundovych
Copy link

Hi. Another n00b struggling with new T2 on Win10 64bit here :-/
The #742 (comment) procedure did not help. But the one from https://forums.tessel.io/t/tessel-2-driver-issues-on-windows-10/2238/157 helped to get T2 visible. Although what is confusing is that originally fresh T2 was seen in Windows 10 as a "USB Composite Device" with 3 interfaces. Now it is visible as single "Tessel DFU" after running thru above fix steps. Is that Ok?

@gdibble
Copy link
Author

gdibble commented Aug 31, 2016

@Sygyzmundovych It should be. I've seen that as well.

@rlramirez77
Copy link

So I may be able to help myself and others, what does the perpetual 'Detected a Tessel that may be booting' when running t2 list mean? Is it a USB comm error essentially?

@johnnyman727
Copy link
Contributor

@rlramirez77 as you may know, there are two processors on Tessel. One is the MediaTek which runs Linux (and Node when you deploy a JS project). The other is the SAMD21 which handles the module ports and USB communications. The SAMD21 boots relatively fast (on the order of milliseconds or less) but has to wait for Linux on the MediaTek to fully boot and open a SPI channel to it. The MediaTek sends commands (like 'turn this GPIO high') to the SAMD21 over this channel and the SAMD21 relays USB comms to the MediaTek (like 'what is the name of this Tessel).

The 'Detected a Tessel that may be booting' means that the SAMD21 has initialized but it is still waiting for that SPI channel to the MediaTek to open up. It usually takes 20-30 seconds for this to happen after power is supplied.

@rlramirez77
Copy link

@johnnyman727 I did know/assume much of that in your 1st paragraph; it is not an uncommon architecture currently. What I did not know is two-fold from your reply:

  1. That the USB communication is making it as far as the SAMD21, +1 for that, and
  2. That the uC thinks the MT App processor does not appear to have fully booted.

On 2. it seems to me that a bad Linux boot/flash state might explain my dilemma - it certainly is not being patient enough. I was trying to get a USB host attached BLE adapter working on the T2 before it became unusable, so I may have stepped in it by myself :-) I am more than willing to purchase a new T2 and am confident now that it would work as it should, but also assume you and the other Devs would like to know what the root cause is. My T2 is a paperweight :-)

First, I'll see if I can at least SSH back into the T2 over ETH. If not, can J401 or another header be used to attached a Segger to re-flash the uC; and/or sideload the appropriate build of OpenWRT?

Russ

@johnnyman727
Copy link
Contributor

@rlramirez77 it would be great if you could make a reproducible case for that but if not, no worries.

Your SAMD21 can actually overwrite the flash memory of the MediaTek. You can try using t2 restore to put the factory image back on. That command does not use the same SPI channel for communication to the MediaTek.

@rlramirez77
Copy link

@johnnyman727 That worked far too well - no more brick, thanks!

@kairos666
Copy link

@johnnyman727 Thanks a ton! worked like a charm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests