Modularizando o src
Dependencies: EALib EthernetInterface_vz mbed-rtos mbed
Fork of header_main_colinas_V0-20-09-14 by
Diff: prompt.cpp
- Revision:
- 63:0d95da692bb4
- Parent:
- 62:07e5bdc9f8f7
- Child:
- 64:5b011d5707d2
diff -r 07e5bdc9f8f7 -r 0d95da692bb4 prompt.cpp --- a/prompt.cpp Tue Oct 28 11:32:06 2014 +0000 +++ b/prompt.cpp Tue Oct 28 12:44:45 2014 +0000 @@ -33,7 +33,19 @@ bool main_test = false; bool flood_silence = false; bool list = false; +bool r_stats; bool rx = false; +bool tx = false; +bool stats = false; + +uint16_t boot_counter = 0; +uint16_t registry_counter = 0; +uint16_t invite_counter = 0; +uint16_t audio_counter = 0; +uint16_t telemetry_counter = 0; +uint16_t cb_bye_counter = 0; +uint16_t prompt_counter = 0; +uint16_t flood_counter = 0; uint8_t test_debug = 1; #define PVERSION 5 // Sempre atualizar a versao do prompt @@ -713,11 +725,25 @@ files('s'); } - if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "rx" ) ){ + else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "rx" ) ){ miss_match = false; rx = true; } + else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "tx" ) ){ + miss_match = false; + tx = true; + } + + else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "stats" ) ){ + miss_match = false; + stats = true; + } + else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "reset_stats" ) ){ + miss_match = false; + r_stats = true; + } + else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "format" ) ){ miss_match = false; pc.printf("\n\rFormatando o sistema de arquivos... espere o sistema reiniciar\n\r"); @@ -840,13 +866,12 @@ reset_cks = true; } - - + /*replaced by ls else if( xstrmatch( (uint8_t*)debug_buf, (uint8_t*) "status" ) ){ miss_match = false; cb_status = true; } - + */ else if( xmemmatch( (uint8_t*)debug_buf, (uint8_t*) "flood ", 6 ) ){ if (xmemmatch( (uint8_t*)(debug_buf+6), (uint8_t*) "on", 2 ) ){ miss_match = false; @@ -1324,6 +1349,7 @@ udp_server.sendTo( udp_client, debug_buf, strlen( debug_buf ) ); } } + /* pc.printf("status - lista resumida de cbx registrados na header\n\r"); if( from_eth ){ snprintf( debug_buf,__PROMPT_ETH_BUFFER_SIZE__, "showcb - lista resumida de cbx registrados na header\n\r" ); @@ -1333,6 +1359,7 @@ udp_server.sendTo( udp_client, debug_buf, strlen( debug_buf ) ); } } + */ pc.printf("cks - exibe estatisticas de check sum\n\r"); if( from_eth ){ snprintf( debug_buf,__PROMPT_ETH_BUFFER_SIZE__, "cks - exibe estatisticas de check sum\n\r" );