Example #1
0
/*! @brief Executed automaticaly at exit 
 * 
 *  This function is executed whenever the program finished, so
 *  its good to do some finalization code here.
 */
void f_atexit(void)
{
 close_network();
 fflush(stdout);
 write_log_fmt("Closing app\n");
 close_log();
}
Example #2
0
static void deinit(void) 
{
  APP_LOG(APP_LOG_LEVEL_DEBUG, "deinit started");

  tick_timer_service_unsubscribe();

  window_destroy(window);

  time_layer_destroy();
  date_layer_destroy();
  weather_layer_destroy();
  debug_layer_destroy();
  battery_layer_destroy();

  free(weather_data);

  close_network();
}