![](/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: call_box_manager.h
- Revision:
- 119:ee6a53069455
- Parent:
- 117:e9facba9db27
- Child:
- 121:ee02790d00b7
--- a/call_box_manager.h Fri Apr 24 13:54:24 2015 +0000 +++ b/call_box_manager.h Thu Apr 30 15:42:41 2015 +0000 @@ -10,14 +10,14 @@ #include "parallelcpld.h" #include "utils.h" -#define __SLEEP_TIME__ 45 +const uint8_t __SLEEP_TIME__ = 45; extern Timer timer_refresh; extern Timer timer_aging; extern Timer timer_sync_refresh; -#define TIME_TO_REFRESH 1 -#define TIME_TO_WAKE_UP 2 +const uint8_t TIME_TO_REFRESH = 1; +const uint8_t TIME_TO_WAKE_UP = 2; /** * @Synopsis Busca por um determinado Call_box no vetor de Call_box usando como chave de busca o ramal. @@ -61,14 +61,20 @@ * @endcode */ -int refresh( Vector * v_cb, uint8_t * data, uint8_t * write_buffer, Call_Box * cb ); +int refresh ( Vector * v_cb ); -#define init_refresh(){ timer_refresh.start(); } -#define init_aging(){ timer_aging.start(); } -#define init_sync_refresh(){ timer_sync_refresh.start(); } +inline int init_refresh () +{ + timer_refresh.start(); + return ( 0 ); +} + +inline int init_sync_refresh () +{ + timer_sync_refresh.start(); + return ( 0 ); +} -void registry_aging( Vector * v_cb, uint8_t * data, uint8_t * write_buffer ); - -void wake_all_up( Vector * v_cb, uint8_t * data, uint8_t * write_buffer ); +void wake_all_up ( Vector * v_cb ); #endif \ No newline at end of file