Seems ridiculous to me that a sub $100 computer and SSD run the code just fine and a $1500 laptop with much fancier HW can't. Have to say productivity will suffer.
...
I am wondering if I just have a bad usb controller, or one that is not fully compliant with the standards - or even a counterfeit device.
Forgive me, as I haven't kept up with every message (been really distracted by supply chain issues), but is this problem confined to just 1 laptop computer?
Regarding Arduino CLI:
Oof, looks like a bit of work to get that going, but it's doable. One quick question, is it effectively a complete new install unto its own? (Independent of any existing installation?)
When you originally worked on this Paul, how did you test for usb compatibility? This is multi-platform, so I am sure you had to go through a lot of work. Is there a usb3 compatibility test anywhere?
Today Teensyduino support for Arduino CLI is compile only. So you could use Arduino CLI instead of a makefile (I believe that was the question I tried to answer with
msg #48) and then use teensy_loader_cli to do the upload.
Eventually I will integrate the teensy_loader_cli code into teensy_post_compile which is called by Arduino CLI. It will not get major changes. If teensy_post_compile isn't working on your PC, you can expect the same behavior from future teensy_post_compile used by Arduino CLI.
Regarding USB compatibility testing, I mainly test Teensy with 2 computers, my Linux desktop machine (a generic white box build with Intel Coffee Lake generation processor) which has all USB3 ports, but both USB2 and USB3 hubs (I regularly use both), and with a 2015 Macbook Air which has USB3 ports. I test Windows 10 by rebooting that Macbook Air to a Bootcamp partition. These are the primary "tier 1" machines I use for most testing. Typically Teensy is used directly with a USB3 port on the Macbook Air, or with a hub plugged into a USB3 on the desktop PC.
I have a group of "tier 2" machines, a 2011 Macbook Pro with USB2 ports, a Raspberry Pi 4, Jetson Nano, and "trashcan" 2013 Mac Pro. I really don't pay much attention to which of these has USB3 vs USB2 ports. The 2011 Macbook has a bootcamp partition with saved images for Windows 7 and Windows 10. Those windows partitions also have the USB-IF command compliance test program. I rarely test with these 2nd tier machines, unless someone reports a specific problem. But I do make a point to run the USB-IF compliance test after editing the USB code.
I also have a
Beagle 480 USB protocol analyzer. Again, I rarely go to the trouble to use it, unless a specific problem is reported, or when I'm specifically working on the USB code. The protocol analyzer software has extensive decoding for most higher level USB protocols and I do watch for it to flag anything as an error.
Every Teensy model has been tested with all these machines many times over the years. I've dealt with all sorts of USB quirks and issues. But I've never had the sort of crashing problems you're reporting. We've had a pretty large user base for Teensy over many years, large enough to run into all sorts of pretty obscure issues, but this crashing problem really sounds unique. If this is limited to just 1 PC, that's a pretty strong indication something is probably wrong with your PC hardware that needs to be repaired or replaced.