Force Teensy to reboot and load program via USB

Status
Not open for further replies.
Hello,

is there a possibility to force the teensy to restart via usb, although the message "Teensy did not respond to a USB-based request to automatically reboot. Please press the PROGRAM MODE BUTTON on your Teensy to upload your sketch." appears? I did built my teensy into a case and I definetely want to avoid to re-open that case.

Restarting PC, changing USB-Port, switching to an other PC didn't help.

Hope someone might have a helping advice.

Greetings
Jonas
 
thanks, but I have a Teensy 3.2 and TyQt seems to not support them. It doesn't show up in the programm gui, when I connect it to my computer..
 
okay, well it doesn't show up in TyQt unfortunately. The teensy itself seems to work, the program I uploaded before is running without problems, but I cant't upload any new program. Do you maybe have some further advice or do you think I have to open the case and press that program button?
 
Last edited:
okay, well it doesn't shop up in TyQt unfortunately. The teensy itself seems to work, the program I uploaded before is running without problems, but I cant't upload any new program. Do you maybe have some further advice or do you think I have to open the case and press that program button?

Do you have any indication that Teensy is running after power cycle? I assume you have USB enabled. Does PC makes nose after power cycle?
If yes, you should be able to reprogram, if program crashes (also if PC looses connection to teensy) only way is to press button (or short prog line to ground)
In that case, I'm afraid you have to open the case.
 
Teensy is running after power cycle. But the problem remains. Yes, USB enabled, USB type is MIDI. What do you mean by "PC makes nose after power cycle"? A restart of the PC doesn't help. But the PC seems to recognise and accept the teensy, it is listed in the device manager with no driver problems or something else indicated.
 
No, unfortunately no second teensy aviable.. Well no, I think I had USB type MIDI, but it might have been USB type MIDI + Serial. I didn't upload the previous sketch, a friend of mine did..
 
Last edited:
Teensy is running after power cycle. But the problem remains. Yes, USB enabled, USB type is MIDI. What do you mean by "PC makes nose after power cycle"? A restart of the PC doesn't help. But the PC seems to recognise and accept the teensy, it is listed in the device manager with no driver problems or something else indicated.

(power cycle of teensy) but you said it is running, then change cable.
If teensy shows up ad HID device or Com device and Teensyduino is set for proper Teensy, then it should reprogram.
 
Last edited:
cable changed -> nothing changed..
Yes, the teensy shows up as HID device and works fine as a MIDI controller in my DAW. It's really strange, that it's not possible to reprogram it then.
 
cable changed -> nothing changed..
Yes, the teensy shows up as HID device and works fine as a MIDI controller in my DAW. It's really strange, that it's not possible to reprogram it then.

At this point, IMO, the programming is not clear.
what is your setup versions of Arduino, Teensyduino, etc. try to compile a simple blink program from Arduino ide, with proper settings of USB type and processor
why?
we have to use the simplest program to know what may going on.

Your OP did not say anything on what type of program you tried to download.
 
Arduino 1.6.9, Teensyduino 1.29

Can't upload the simplest program because the teensy doesn't respond to the usb-based request to reboot..
USB type MIDI, Board Teensy 3.2/3.1, CPU 96MHZ optimized (overclock).

The program thats currently running on the teensy seems to be a MIDI + Serial USB-Type program because the teensy appears as a HID and a Serial device in my device manager.. Might that be a reason for my problem?
 
Arduino 1.6.9, Teensyduino 1.29

Can't upload the simplest program because the teensy doesn't respond to the usb-based request to reboot..
USB type MIDI, Board Teensy 3.2/3.1, CPU 96MHZ optimized (overclock).

The program thats currently running on the teensy seems to be a MIDI + Serial USB-Type program because the teensy appears as a HID and a Serial device in my device manager.. Might that be a reason for my problem?

No, that should not inhibit a reprograming request. (you mean reprogram and not reboot, right).

what happens if you run form terminal the attached program (PC only,in zip file)
teensyloader_cli -l
this lists all hid and com devices
and
teensyLoader_cli -mmcu=mk20dx256 -v blink_31.hex
downloads a blink program
 

Attachments

  • teensy_loader_cli_05-11-15.zip
    45.6 KB · Views: 109
Thanks, but no success again.. This shows up after trying to program it with the blink program:

Code:
Device Instance: 1
  DeviceRegistryProperty: acquired
  Key type: REG_MULTI_SZ
    property: USB\VID_16C0&PID_0485&REV_0200&MI_00
    property: USB\VID_16C0&PID_0485&MI_00

found_hid
 vid = 0x06CB, pid = 0x7407 ser = 9999
no Teensy

found_hid
 vid = 0x045E, pid = 0x0805 ser =
no Teensy

found_hid
 vid = 0x06CB, pid = 0x7407 ser = 9999
no Teensy

found_hid
 vid = 0x2BF6, pid = 0xA096 ser =
no Teensy

found_hid
 vid = 0x2BF6, pid = 0xA096 ser =
no Teensy
Teensy Loader, Command Line, Version 2.1d (WMXZ)
 
Interesting - when I set USB to MIDI with Serial using Arduino 1.6.9 and Teensyduino 1.29, I always have to press the program button as upload always fails. The only difference is I'm on a Mac instead of Windows.
 
Thanks, but no success again.. This shows up after trying to program it with the blink program:

Code:
Device Instance: 1
  DeviceRegistryProperty: acquired
  Key type: REG_MULTI_SZ
    property: USB\VID_16C0&PID_0485&REV_0200&MI_00
    property: USB\VID_16C0&PID_0485&MI_00

found_hid
 vid = 0x06CB, pid = 0x7407 ser = 9999
no Teensy

found_hid
 vid = 0x045E, pid = 0x0805 ser =
no Teensy

found_hid
 vid = 0x06CB, pid = 0x7407 ser = 9999
no Teensy

found_hid
 vid = 0x2BF6, pid = 0xA096 ser =
no Teensy

found_hid
 vid = 0x2BF6, pid = 0xA096 ser =
no Teensy
Teensy Loader, Command Line, Version 2.1d (WMXZ)

OK,
it found the teensy

program looks first for com ports
it found a teensy with PID 485, which describes a MIDI.
It could not find a teensy as HID device (only other attached devices, wich is weird as I thought MIDI is HID, but I don't know anything about MIDI)

Unfortunately, the program as it stands now, ignores PID 485 for Serial ports. It looks for 483 or 487.
Consequently program thinks, there is no valid teensy and asks for button press.
This MIDI + Serial was introduced a couple of month ago, but did not get unique PID.

I'm out of town today, but will try to look into my program in about 12 h from now.
OK you always, can press button, but I'm curies to see if my theory is correct.
Solution should be trivial, but needs testing.
 
OK you always, can press button, but I'm curies to see if my theory is correct.
Or, if you are in a hurry, you can open device manager, identify comport, say com19

follow usual download procedure (i.e. from Arduino/Teensyduino)
on request press program button
open terminal program (I use PuTTYtel), open comport with Baud rate set to 134 (sic)
it should then put teensy into programming mode
you will see comport disappearing and HID coming up with PID 478
and program should start loading.
 
Or, if you are in a hurry, you can open device manager, identify comport, say com19

follow usual download procedure (i.e. from Arduino/Teensyduino)
on request press program button
open terminal program (I use PuTTYtel), open comport with Baud rate set to 134 (sic)
it should then put teensy into programming mode
you will see comport disappearing and HID coming up with PID 478
and program should start loading.

concerning OP, open terminal with 134 baud is the best way to force teensy into reboot without pressing prog button.
(as of TD 1.29 and until Paul upgrades teensy_reboot.exe)

Obviously this requires serial set in Arduino tools and therefore accessible comport (no crashed mcu)
so far this is only necessary for recently added midi + protocols (i.e all usb protocols that use CDC)
plain usb_serial is already handled in teensy_reboot.exe
 
Thanks for your time!

I'm not that into this topic, so I am struggling with understanding what to do now.. Sorry for that!

What exactly do I have to do with PuTTYtel now? Setting Baud rate to 134 is possible in the device manager as well, isn't it?
 
Thanks for your time!

I'm not that into this topic, so I am struggling with understanding what to do now.. Sorry for that!

What exactly do I have to do with PuTTYtel now? Setting Baud rate to 134 is possible in the device manager as well, isn't it?

I know, you always can open the box and press the pro button.
yes, you can set baud rate in the device manager, but this does not open the device.

what I do in PuTTtel (the only one I have) is

- open PuTTYtel
- change port to the one teensy is on and baudrate to 134 and press open. that's all.

once you connect to teensy with that baud rate, it will go into program mode.

That is how teensyduino does it. Obviously TD does more, and does something different for HID devices.
 
Last edited:
okay I got it! I used the windows cmd, PuTTY dind't work. But now it's fully programmable with Arduino/Teensyduino again.

Code:
C:\Users\Ich>powershell
Windows PowerShell
Copyright (C) 2015 Microsoft Corporation. Alle Rechte vorbehalten.

PS C:\Users\Ich> [System.IO.Ports.SerialPort]::getportnames()
COM3
PS C:\Users\Ich> $port= new-Object System.IO.Ports.SerialPort COM3,134,None,8,one
PS C:\Users\Ich> $port.open()
PS C:\Users\Ich> $port.Close()
PS C:\Users\Ich> exit

Thank you very much for your help!
 
Status
Not open for further replies.
Back
Top