remote program button?

Status
Not open for further replies.

spencoid

Well-known member
This afternoon I programmed my teensy 3.2 as always. I am running win 10 on a notebook computer because i need to be able to take it out to the shop where my Teensy controlled still lives. I am using the Arduino IDE (which i am not thrilled with) because i am lazy and do not want to learn anything i don't have to. I use automatic mode and every time i click the upload button in the IDE menu bar, that is what happens as it always has. Occasionally something goes a little wrong and i need to press the button on the Teensy but that is rare.

Microsoft kept bugging me to update win 10 with a major update and (stupidly) i did. I figured i would try it on the notebook and not my "important" computer. All kinds of strange things happened until i rebooted several times. Won't go into details but there were some major issues but they all went away after 4 reboots. Ah the mysteries of windowz!!! All of a sudden my touchpad worked well as it never did (i hated, hated hated, this touchpad, absolutely the worst ever, for about 5 years) before so i was thinking all was right in the world.

Now i can not upload a program to the Teensy automatically and have to press the upload button every time. This is only the case on the "updated" computer. Still works fine on the one that is not updated.

The problem is that the Teensy is deep inside a waterproof box to keep it safe from the heat alcohol etc of a still. I needed to get it working as i am constantly updating the code. I tried grounding the reset pad on the back of the board thinking i could install a remote switch but this only re-starts the Teensy and does not cause the new program to load. With the upload switch being surface mounted i could not figure out where it is connected.

So i drilled a hole in my nice enclosure and made a plastic thingy to press the switch. Not my idea of a good solution but that is all i have for now.

There must be a better solution. Can a remote version of the program button be added? Where do i connect it?

What might have changed with the update? Seriously this was not an issue right before the update and is right after. One thing that might be new is that i get a bunch of warnings about "invalid library found in ..." after the compilation but before that the verbose output identifies all the same libraries in other locations that it does not have a problem with. If i press the program button, all goes well in spite of this so i doubt that is really the problem.
 
Just had a thought. I bet this is some sort of stupid protection that windows is providing. It won't let the IDE communicate with the teensy through the USB port now for some reason only microsoft would know. I tried turning off the firewall but that did not make any difference.
 
If you look at the 3.2 pinout, you will see 5 pins in the back of the Teensy (A14/DAC, Program, Ground, 3.3v, and Vbat). If you connect program and ground pins to wires that run to a switch, you can do the program button at a distance. As you noted the reset pad under the Teensy just restarts it, but it doesn't enter programming mode.
 
thanks, i managed to miss that on the chart. i am used to looking at the long rows of pins and never thought of looking at the end :) hopefully the windows upade problem will sort out b ut at least in can remotely program my teensy without a plunger
 
you can also trigger the programming via software, attached button, or even send a string to the serial so it puts itself in program mode, then flash it
 
you can also trigger the programming via software, attached button, or even send a string to the serial so it puts itself in program mode, then flash it

i installed a remote button and it works but i would still like to get the automatic programming working the way it was before updating windows. any ideas where to look for what might be preventing automatic mode? i already tried turning off the firewall.
 
i installed a remote button and it works but i would still like to get the automatic programming working the way it was before updating windows. any ideas where to look for what might be preventing automatic mode? i already tried turning off the firewall.

AFAIK, Firewall is not relevant for USB.
As you can see from searching this forum, there a multiple reasons for nor being able to upload automatically.
mostly it is a not running USB event handler (i.e. ISR running at higher priority, usb crashed, disabling interrupts)

Best is to search for issue by using simple blink or hello world program to see if automatic programming is working.
To really help we need example sketch AND setting or IDE Tools for the failing case.
 
remote program button

Install the latest beta.

https://forum.pjrc.com/threads/44937-Teensyduino-1-37-Beta-4

Notice on this earlier beta, one of the changes is "Fix auto-reboot on Windows 10 rev 1703 (Creator's Update)"

That fixed it. I did not see this listed when i searched. I thought about updating teensyduino but had done so recently and did not think there was a fix for a very new windows update yet. It is the "Creator Update" that got installed. No idea why Microsoft was so hot on installing it, bugging me very day, in on one computer but not on my main one.

Thanks Paul for fixing things as usual. I was recently looking at some cheap little arduinos thinking they might be useful and they sure are cheap but I pretty quickly decided I do not need the headache. Teensies might cost a little more but the support you get and the additional features are more than worth the few dollars that I might not live long enough to spend anyway.
 
I was able to upload files without using the button after updating to the latest beta teensyduino. The first program I uploaded with the new teensyduino would run for a couple of minutes and then freeze. So I added a bunch of serial print statements to try to narrow it down. Without all the gorey details, the problem is with the serial communication. If i comment out "serial begin" and all serial prints, the program seems to run indefinitely as it did before. If i include serial begin, the program runs for about 2 minutes (some times less) and then freezes. My serial writes are very few, occurring in a loop that only runs once per second. The sketch is quite long and not the easiest thing to digest. I can try to reduce it to a minimum that exhibits problem but that will take a lot of effort and it will be a while before i have time to do that.

I compiled the program on my other computer that has not been upgraded win 10 wise and also not the new teensyduino. I copied the hex file to the updated computer and loaded it with the teensy loader version 1.37 beta 4 or at least i think i did. I selected the file that was compiled on the not updated computer with "file" "open hex file" and them pressed the program button. The program does not run and freezes after less than two minutes. I then compiled the program with the serial stuff commented out and uploaded that and it works fine.

So my conclusion is that there is something wrong with the new beta loader. I can try to make a simple version of a program that demonstrates the problem but i am hoping that my explanation will point to the problem with the loader without having to do that. I don't know anything about how this all works internally but my guess is that the loader is setting some strange mode in the teensy when loaded with the beta loader. Another bit of strangeness is that when loaded with the new loader and serial stuff in the sketch (not commented out) the LCD display flutters as if something has taken over the program . I am using a i2C LCD and have been very careful about clearing the display only when necessary as I know this takes a lot of time and messes up the display. This is not what is screwing up the display. I have changed nothing in the code other than commenting out (or not) the serial stuff.

Please let me know what other information i can provide. If i really need to provide code i will try to edit the code to the minimum that produces the problem but really want to avoid this. I can also provide the complete mess but I would not like to try to make sense out of it. I doubt that anyone can make sense out of this, but here is the code, simplified a little. I removed a bunch of pages of parameter setting display modes and tried to order the subroutines in a sensible way. This all worked fine before the updates. The main loop selects between display pages each of which has different settings and options. The two pages that i left in use all the various subroutines timers etc.


Code:
#include <DallasTemperature.h>
#include <OneWire.h>
#include <LiquidCrystal_I2C.h>
#include <EEPROM.h> 
#include <elapsedMillis.h>    // was working without this so maybe it is already included 
LiquidCrystal_I2C lcd(0x27,20,4);  // set the LCD address to 0x27 for a 16 chars and 2 line display

OneWire  ds(3);  // on pin 3
int localKey = 0;
int pwm = 50;
int pwm_out;
int percent_on;
int run_pwm;
int reflux_on_time = 1;
int reflux_off_time = 9;
int old_reflux_on_time;
int heater_on_time = 5;
int heater_off_time = 5;
int old_heater_on_time;
int cooling_temp_limit = 70;
int old_cooling_temp_limit;
volatile int flow_count;
int flow_count_threshold = 100;   // minimum number of flow counts to not trip overheat condition
float temp1 = 70;
float temp2 = 70;
float set_temp = 70;
int old_set_temp = set_temp;      // should be float ???
float preheat_temp = 70;
int old_preheat_temp = preheat_temp;      // should be float ???
float show_pwm_percent;
float tempC1;
byte addr[8];
float celsius, fahrenheit;
boolean reflux_on = false;
boolean heater_on;
boolean do_serial = false;
boolean over_heat = false;
boolean no_flow = false;
boolean pre_heat = false;
int address = 0; //EEPROM address to start reading from
int sense_thresh0 = 1700;
int sense_thresh1 = 1700;
int sense_thresh2 = 1700;
int sense_thresh3 = 1700;
int touch_read15 = touchRead(15); 
int touch_read16 = touchRead(16); 
int touch_read0 = touchRead(0); 
int touch_read1 = touchRead(1); 
int key_delay = 1500;
int repeat_delay = 500;
int temp_update_interval = 1000;
int mode = 0;
int old_pwm = pwm;
float sense_factor = 1.4;
unsigned int flow_check_interval = 1000;
elapsedMillis temp_check_time = 0;
elapsedMillis button_time = 0;
elapsedMillis reflux_time = 0;
elapsedMillis heater_check_time = 0;

unsigned long previousMillis = 0;
const long interval = 1000;
int check_count;

int pwm_table[] = 
    {0,10,15,20,25,30,35,40,45,50,55,60,65,70,75,80,85,90,95,100,100,100  // a few extra incase index is wrong
};

// Data wire is plugged into port 11 on the Arduino
#define ONE_WIRE_BUS 3  // was 2 on controller no 1

OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);
DeviceAddress thermometer1, thermometer2;

void setup(void) {
    sense_thresh0 = sense_factor * touchRead(15);
    sense_thresh1 = sense_factor * touchRead(16);  
    sense_thresh2 = sense_factor * touchRead(0);
    sense_thresh3 = sense_factor * touchRead(1);    
//    Serial.begin(9600);
    delay(1000);
//    print_serial();
    lcd.init();                      // initialize the lcd 
    lcd.init();
    lcd.backlight();
    lcd.setCursor(2,0);
    lcd.print("Hello");
    lcd.setCursor(5,1);
    lcd.print("Temp");
    lcd.setCursor(8,2);
    lcd.print("Controller");  
    lcd.setCursor(1,3);
    lcd.print("restoring setings");    
    delay(1000);
    lcd.clear();
  
    address = 0; //EEPROM address to start reading from
    int value;    
    EEPROM.get( address, value );
    if ((value < 50) || (value > 125)){ // screwed up or not programmed values so restore defaults
        EEPROM.put(address, set_temp);  
        address = 10;
        EEPROM.put(address, pwm);
        address = 20;
        EEPROM.put(address, reflux_on_time);
        address = 30;
        EEPROM.put(address, cooling_temp_limit);
        address = 40;
        EEPROM.put(address, preheat_temp);        
  }    
    get_parameters();
    
    pinMode(11, OUTPUT);   // ssr control pin
    pinMode(21, OUTPUT);   // reflux control pin
    pinMode(13, OUTPUT);
    pinMode(14, INPUT_PULLUP);   // flow sensor, not sure if pullup is needed, probalby not
    attachInterrupt(digitalPinToInterrupt(14), count_flow, CHANGE);
    
    sensors.begin();
    sensors.getAddress(thermometer1, 0);
    sensors.getAddress(thermometer2, 1);
    sensors.setResolution(thermometer1, 12);
    sensors.setResolution(thermometer2, 12); 
    sensors.setWaitForConversion(false);  // makes it async
    sensors.requestTemperatures();
    sensors.setWaitForConversion(true);
    temp1 = sensors.getTempC(thermometer1);       
    temp2 = sensors.getTempC(thermometer2);       
    do_relays();  
}
void loop(void) {
    if (mode >1) mode = 0;
    switch (mode) {
      case 0:
        screen0();
        break;
      case 1:
        screen1();
        break;                    
      default:
        break;
    }
}  
void do_relays (){
    check_flow();
    do_reflux();
    control_heater_relay(); // this just turns relay on and off on timmer schedule
    get_temps();
    check_overtemp();
    if (set_temp > temp1){
        int diff = int (set_temp - temp1);
        if (diff < 0) diff = 0;
        if (diff >= 20) {
          run_pwm = pwm;
        }
        else{
          run_pwm = (pwm_table[diff] * (pwm/10)) / 10;  // currently this is the same as the following but table can be changed
          if (run_pwm > pwm) run_pwm = pwm;
        }
        if (run_pwm < 0) run_pwm = 0;
        if (run_pwm > 100) run_pwm = 100;
        if (run_pwm >= 1 && run_pwm < 10) run_pwm = 10; // should probably round all run_pwms up but need to figure out how
        if (run_pwm > pwm)  run_pwm = pwm;  // not likely but ...
         
        if (over_heat == true) run_pwm = 0;   // this is a little hidden and should be made more clear   
        
        heater_on_time = int (run_pwm/10);  // change this to run_pwm to change to tenths of a second instead of seconds
        heater_off_time = 10 - heater_on_time;   // change this to 100 - heater_on_time if above line is changed     
    }
    else{
       run_pwm = 0;
       heater_on_time = 0;
       heater_off_time = 10;
    }    
}
void screen0(){  // this displays data only, no changes can be made
    lcd.clear();
    while (mode == 0){
        get_temps();
        display_temp();
        lcd.setCursor(15, 3);
        if (reflux_on == true){
              lcd.print("R-ON  ");
        }
        else{
              lcd.print("R-OFF");
        }        
//        lcd.print("SCR1");            
        do_relays ();   
        check_flow;
        if (touchRead(1) > sense_thresh3) please_wait();              
    }
}  
 void screen1() {   // add a while loop 
    lcd.clear();
    while (mode ==1){
        if (touchRead(1) > sense_thresh3) please_wait();
        check_buttons();
        get_temps();
        do_relays ();
        display_temp();      
        lcd.setCursor(9, 3);
        lcd.print("set TMP/PWM");             
    }
 } 
void control_heater_relay(){
    if (heater_on_time >0){
         if (heater_on == true){
//            if ((heater_check_time / 1000) > heater_on_time ){    // change to / 100 to match change below?
            if ((heater_check_time / 100) > heater_on_time ){    // change to / 100 to match change below?   
                heater_check_time = 0;
                heater_on = false;
                digitalWrite(11, LOW); 
                digitalWrite(LED_BUILTIN, HIGH); 
            }    
        }
        else{
            if ((heater_check_time / 100) > heater_off_time){
                heater_check_time = 0; 
                heater_on = true;
                if (no_flow == false){
                  digitalWrite(11, HIGH);
                }
                else digitalWrite (11,LOW);
                digitalWrite(LED_BUILTIN, LOW);                  
            }        
        }   
    }
    else{
          digitalWrite(11, LOW); 
          digitalWrite(LED_BUILTIN, HIGH);   
          heater_on = false;
    }  
}
void check_overtemp(){
    if((temp2 > cooling_temp_limit) and (mode != 3)){
          lcd.clear();
          lcd.setCursor(0, 0); 
          lcd.print("Shutdown over temp         ");        
          lcd.setCursor(0, 1);  
          lcd.print("use mode 3 change");    
          lcd.setCursor(0, 2); 
          lcd.print("overheat setting");        
          lcd.setCursor(0, 3);  
          lcd.print("or cool condenser ");    
          over_heat = true;        
          delay(100);
          run_pwm = 0;
          heater_on_time = 0;
          heater_off_time = 10;
          digitalWrite(11, LOW);
          if (touchRead(1) > sense_thresh3) please_wait();
    }
    else over_heat = false;
}
void do_reflux(){
    if (reflux_on_time >0){
         if (reflux_on == true){
            if ((reflux_time / 1000) > reflux_on_time ){
                reflux_time = 0;
                reflux_on = false;
                digitalWrite(21, HIGH); 
                digitalWrite(LED_BUILTIN, HIGH); 
            }    
        }
        else{
            if ((reflux_time / 1000) > reflux_off_time){
                reflux_time = 0; 
                reflux_on = true;
                digitalWrite(21, LOW);    
                digitalWrite(LED_BUILTIN, LOW);                  
            }        
        }   
    }
    else{
          digitalWrite(21, HIGH); 
          digitalWrite(LED_BUILTIN, HIGH);   
          reflux_on = false;
    }
}
void check_flow(){
   unsigned long currentMillis = millis();
   if (currentMillis - previousMillis >= interval) {    // check counter every second
      check_count ++;
      if (check_count > 1000) check_count =0;
      if (do_serial) print_serial();
      previousMillis = currentMillis;
      if (flow_count  < flow_count_threshold){
        if (mode != 4){
            no_flow = true;
        }
      }
      else {
            no_flow = false;
      }
      flow_count = 0;  
     }
}
void get_temps(){
    if (temp_check_time > temp_update_interval){
        sensors.setWaitForConversion(false);  // makes it async
        sensors.requestTemperatures();
        sensors.setWaitForConversion(true);
        temp1 = sensors.getTempC(thermometer1);  
        temp2 = sensors.getTempC(thermometer2);    
        temp_check_time = 0;
    }
}
void count_flow(){
    flow_count ++;
}
void check_buttons(){
  if (touchRead(15) > sense_thresh0){    
    if (set_temp >= .5) set_temp  -= .5;
    display_temp();      
    delay(key_delay);
    touch_read15 = touchRead(15); 
    while (touchRead(15) > sense_thresh0){
        set_temp  -= 5;
        if (set_temp <= 0) set_temp = 0;
        touch_read15 = touchRead(15);
        do_relays ();
        delay(repeat_delay);
        display_temp();  
    }
    if (old_set_temp != set_temp){
        address = 0;
        EEPROM.put(address, set_temp);
        old_set_temp = set_temp;
      }
//      if (do_serial) print_serial();
  }
  else if (touchRead(16) > sense_thresh1){       
    if (set_temp <= 124.5) set_temp  += .5;
    do_relays ();
    display_temp();      
    delay(key_delay);
    touch_read16 = touchRead(16); 
    while (touchRead(16) > sense_thresh1){
          set_temp  += 5;
          if (set_temp >125) set_temp  = 125;
          touch_read16 = touchRead(16);
          do_relays ();
          delay(repeat_delay);
          display_temp();  
      }
      if (old_set_temp != set_temp){
          address = 0;
          EEPROM.put(address, set_temp);
          old_set_temp = set_temp;  
        }    
//        if (do_serial) print_serial();
     }  
     else if (touchRead(0) > sense_thresh2){   
        pwm += 10;
        if (pwm > 100)pwm = 10;
        do_relays ();
        display_temp();      
        delay(key_delay);
        touch_read0 = touchRead(0); 
        while (touchRead(0) > sense_thresh2){
            pwm += 10;
            if (pwm > 100)pwm = 10;
            touch_read0 = touchRead(0);
            delay(repeat_delay);
            do_relays ();
            display_temp();  
      }
      if (old_pwm != pwm){
        address = 10;
        EEPROM.put(address, pwm);
        old_pwm = pwm;
      }
//      if (do_serial) print_serial();
   }
}
void please_wait(){ 
        lcd.clear();
        lcd.setCursor(0, 0);  // position first then line number
        lcd.print("Switching to Page ");
        int mode_plus_one = mode + 1;
        if (mode_plus_one == 5) mode_plus_one = 0;
        lcd.print (mode_plus_one);
        lcd.setCursor(0, 1);
        lcd.print("Please Wait          ");
        lcd.setCursor(0, 2);  
        lcd.print("                   ");     
        lcd.setCursor(0, 3);  
        lcd.print("                        ");                                  
        mode ++;
        delay(key_delay);
        lcd.clear();
} 
void display_temp(){ 
    if (over_heat == false){
        lcd.setCursor(0, 0);
        lcd.print("Set C");
        lcd.print(set_temp,1);
        lcd.print(" F");
        float fsettemp = (DallasTemperature::toFahrenheit(set_temp)); // Converts tempC to Fahrenheit
        lcd.print(fsettemp,1); 
        
        lcd.setCursor(0, 1); 
        lcd.print("Temp 1 C");   
        lcd.print(temp1,1);
        float ftemp1 = (DallasTemperature::toFahrenheit(temp1)); // Converts tempC to Fahrenheit
        lcd.print(" F");   
        lcd.print(ftemp1,1);
        lcd.print("  "); // clear last two digits in case temp lost one digit
    
        lcd.setCursor(0, 2); 
        lcd.print("Temp 2 C");   
        lcd.print(temp2,1);
        float ftemp2 = (DallasTemperature::toFahrenheit(temp2)); // Converts tempC to Fahrenheit
        lcd.print(" F");   
        lcd.print(ftemp2,1);
        lcd.print("  "); // clear last two digits in case temp lost one digit
    
        lcd.setCursor(0, 3);  
        if (no_flow == false){
            lcd.print("         ");
            lcd.setCursor(0, 3); 
            lcd.print("                        ");
            lcd.setCursor(0, 3);
            lcd.print(pwm);    
            lcd.print("/");
            lcd.print(run_pwm);    
            if (mode != 1){
                if (heater_on){
                lcd.print(" on ");
                }
                else{
                    lcd.print(" off ");
                }  
            }  
        }
        else{
             lcd.setCursor(0, 3);   
             lcd.print("NO FLOW");     
        }
    }
} 
void get_parameters(){
    address = 0;
    EEPROM.get(address, set_temp);  
    if ((set_temp< 10) || (set_temp > 125)){ 
        set_temp = 70;
    }
    address = 10;    
    EEPROM.get(address, pwm); 
    if ((pwm< 0) || (pwm > 100)){
        pwm = 100;
    }   
    address = 20;    
    EEPROM.get(address, reflux_on_time);  
     if ((reflux_on_time< 0) || (reflux_on_time> 10)){
        reflux_on_time = 0;
    }         
    address = 30;    
    EEPROM.get(address, cooling_temp_limit);   
    if ((cooling_temp_limit< 0) || (cooling_temp_limit > 250)){
        cooling_temp_limit = 0;
    }      
    address = 40;    
    EEPROM.get(address, preheat_temp);   
    if ((preheat_temp < 0) || (preheat_temp > 100)){
        preheat_temp = 100;
    }         
}  
void print_serial(){
  Serial.print("check_count  ");
  Serial.println(check_count);  
  Serial.print("mode  ");
  Serial.println(mode);    
  Serial.print("run pwm  ");
  Serial.println(run_pwm);
  Serial.print("set_temp  ");
  Serial.println(set_temp);
  Serial.print("reflux_on_time  ");
  Serial.println(reflux_on_time);
  Serial.print("cooling_temp_limit  ");
  Serial.println(cooling_temp_limit);
  Serial.print("preheat_temp  ");
  Serial.println(preheat_temp);
}
 
if i use serial + midi instead of just serial the program works. i have had it running for hours after making this change. there is some mighty strange stuff in win 10. i should keep a separate computer for arduino stuff and stick to what works.

i modified my control box so i can easily take the teensy out and program it on the machine that it likes better but of course i don't need to do that now :)
 
If i really need to provide code i will try to edit the code to the minimum that produces the problem but really want to avoid this.

I gave your code (msg #10) a try, but after installing the 2 missing libraries using Arduino's library manager, I get a compile error from the LiquidCrystal_I2C lib. Seems you're using a different copy than Arduino's library manager installs.

Sorry, this is more than I can do to run your code, especially since it's unlikely to have similar timing when I run it here on a bare Teensy without the I2C display and 1-wire sensors you are using.

Since I couldn't get your program to run, I'm trying this simple code instead.

capture.png


Edit: it's been running for several minutes on Win 10 rev 1703 without crashing. Looks like something about the combination of stuff you're using may be problematic.

This update it to let you know I am *not* investigating further until a reproducible test program is posted. Any test program must clearly state *exactly* which libs it needs, if using anything not installed by Teensyduino. Please, if you post a test program, please compile it on a different computer (or a clean virtual machine) to make sure it compiles with a stock install of Arduino and Teensyduino. If any libs or other install is needed to get exactly the same HEX file, please use the clean install to check you've clearly stated all required pieces.

Please also try running on a bare Teensy with no other hardware connected. If the program won't reproduce without extra hardware, of course that also needs to be clearly stated. Please also post a photo.

Yes, I know this is more work for you. But please understand I can not put more time into chasing an elusive problem without clear info about all the stuff I need to do to reproduce it.
 
Last edited:
i just thought it might be a known issue like the problem with the program button and the win 10 update. i understand that this program requires a lot of stuff that one would not have around and that it would take a lot of time to try to reproduce etc etc. if use midi plus serial i get better results and also if i use serial monitoring just for testing and disable it when running the program it works better too.

it seems there is some issue with the serial port with the new win update so i will try to reduce the program to something that demonstrates it without the display and the temp sensors. however i sort of think that the problem is caused by the serial communication interacting wiht all the other stuff that is going on.

since it is working reasonably well now if i disable serial, it may be a long time before i get a chance to do more testing that might lead to finding the real source of the problem. just to be sure, i rewired the whole mess with good connectors, careful soldering, a better power supply to make sure i t was not a loose connection or voltage problem. might have more information once i successfully make a batch of gin.
 
I don't want to open a new topic because is more or less related...
I want to add capability at my teensy to update firmware via USB using the command line loader.

Teensy will be in a case and I would like to have an option to go tu update mode without opening the case.
Is there any way to do that? automatically recognize? calling a function? something?

Thanks
Lorenzo
 
If things work right the bootloader mode should trigger by the command line loader code
https://www.pjrc.com/teensy/loader_cli.html
Setting a very unusual baud rate on the serial internface (can't remember the exact figure) which sends the board into the load state.

Note this only works if the Teensy is running code and has functional USB (not asleep, hung or running a crazy clock rate) in which case you need the hardware button to de-brick it (can be avoided by not doing bad things in code to start with).
 
If things work right the bootloader mode should trigger by the command line loader code
https://www.pjrc.com/teensy/loader_cli.html
Setting a very unusual baud rate on the serial internface (can't remember the exact figure) which sends the board into the load state.

Note this only works if the Teensy is running code and has functional USB (not asleep, hung or running a crazy clock rate) in which case you need the hardware button to de-brick it (can be avoided by not doing bad things in code to start with).

thanks for the info, I will give it a try
 
Status
Not open for further replies.
Back
Top