File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,10 @@ void autoreset_disable() {
5454    autoreset_enabled  =  false;
5555}
5656
57+ inline  bool  autoreset_is_enabled () {
58+     return  autoreset_enabled ;
59+ }
60+ 
5761void  autoreset_start () {
5862    autoreset_delay_ms  =  AUTORESET_DELAY_MS ;
5963}
Original file line number Diff line number Diff line change @@ -37,5 +37,6 @@ void autoreset_start(void);
3737void  autoreset_stop (void );
3838void  autoreset_enable (void );
3939void  autoreset_disable (void );
40+ bool  autoreset_is_enabled (void );
4041
4142#endif   // __MICROPY_INCLUDED_ATMEL_SAMD_AUTORESET_H__ 
Original file line number Diff line number Diff line change @@ -259,7 +259,7 @@ bool start_mp(void) {
259259    #ifdef  AUTORESET_DELAY_MS 
260260    if  (cdc_enabled_at_start ) {
261261        mp_hal_stdout_tx_str ("\r\n" );
262-         mp_hal_stdout_tx_str ("Auto-soft reset is on. Simply save files over USB to run them.\r\n" );
262+         mp_hal_stdout_tx_str ("Auto-soft reset is on. Simply save files over USB to run them or enter REPL to disable .\r\n" );
263263    }
264264    #endif 
265265
@@ -330,10 +330,14 @@ bool start_mp(void) {
330330        if  (!cdc_enabled_before  &&  mp_cdc_enabled ) {
331331            if  (cdc_enabled_at_start ) {
332332                mp_hal_stdout_tx_str ("\r\n\r\n" );
333+             }
334+ 
335+             if  (!cdc_enabled_at_start  &&  autoreset_is_enabled ()) {
336+                 mp_hal_stdout_tx_str ("Auto-soft reset is on. Simply save files over USB to run them or enter REPL to disable.\r\n" );
333337            } else  {
334-                 mp_hal_stdout_tx_str ("Auto-soft reset is on. Simply save files over USB to run them .\r\n" );
338+                 mp_hal_stdout_tx_str ("Auto-soft reset is off .\r\n" );
335339            }
336-             mp_hal_stdout_tx_str ("Press any key to enter the REPL and disable auto-reset . Use CTRL-D to soft reset.\r\n" );
340+             mp_hal_stdout_tx_str ("Press any key to enter the REPL. Use CTRL-D to soft reset.\r\n" );
337341        }
338342        if  (cdc_enabled_before  &&  !mp_cdc_enabled ) {
339343            cdc_enabled_at_start  =  false;
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments