![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Modularizando o src
Dependencies: EALib EthernetInterface_vz mbed-rtos mbed
Fork of header_main_colinas_V0-20-09-14 by
Diff: sip_manager.cpp
- Revision:
- 81:3656f00ab3db
- Parent:
- 74:81c47fff88a5
- Child:
- 82:f55d13babca0
diff -r 61d61c9eb75c -r 3656f00ab3db sip_manager.cpp --- a/sip_manager.cpp Tue Dec 16 19:34:30 2014 +0000 +++ b/sip_manager.cpp Tue Dec 30 12:37:40 2014 +0000 @@ -1,12 +1,12 @@ #include "sip_manager.h" int sip_manager( Vector * v_cb ){ - static int index = 0; + static int sip_index = 0; if( v_cb != NULL ){ if( v_cb->size() > 0 ){ - if( index >= v_cb->size() ) index = 0; + if( sip_index >= v_cb->size() ) sip_index = 0; }else return 0; - Call_Box * cb = (Call_Box * )v_cb->get_element( index ); + Call_Box * cb = (Call_Box * )v_cb->get_element( sip_index ); /* Retorna = 0 :: ok < 0 :: tive problemas @@ -14,11 +14,11 @@ */ int returned_value = 0; + //FIXME pensar em ouvir todos os cbx que estiverem em ligacao apenas, sao poucos if( cb->status == cb_on_call || cb->status == cb_idle ){ - //debug_msg(""); returned_value = cb->listen_SIP_server(); } - index++; + sip_index++; return( returned_value ); } return( -1 );