usr.c 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. #include "usr.h"
  2. #include "system.h"
  3. #include "bsp_time.h"
  4. //Add your code here...
  5. #include "hal_ble_client.h"
  6. #include "hal_ble_host.h"
  7. #include "hal_mt.h"
  8. #include "hal_battery.h"
  9. #include "hal_led.h"
  10. #include "app_overturn.h"
  11. #include "app_charge.h"
  12. #include "app_power.h"
  13. #include "app_client.h"
  14. #include "app_host.h"
  15. #include "app_game.h"
  16. #include "app_config.h"
  17. #include "app_ota.h"
  18. #include "app_connect_manage.h"
  19. #include "app_organ.h"
  20. #include "ble_comm.h"
  21. #include "exception.h"
  22. #include "bsp_pwm.h"
  23. #include "bsp_wdt.h"
  24. #include "hal_wearshoes.h"
  25. #include "app_math.h"
  26. #include "app_losspack.h"
  27. #include "app_pair_chargerpin.h"
  28. #include "app_switchimu.h"
  29. #include "exception.h"
  30. #include "app_data_transfer.h"
  31. #include "app_safe.h"
  32. #include "bll_imu.h"
  33. #include "app_flash.h"
  34. #include "app_step.h"
  35. #include "hal_qma.h"
  36. #include "app_detectIsHost.h"
  37. #include "hal_charge.h"
  38. #include "app_Authen.h"
  39. #include "fml_adc.h"
  40. void usr1_Init(void)
  41. {
  42. slave_init(BLE_Client_Push);
  43. host_init(BLE_Host_Push);
  44. }
  45. void PRE_Init(void)
  46. {
  47. usr1_Init();
  48. PWR_Init();
  49. LED_Init();
  50. MT_Init();
  51. Flash_Initialize();
  52. Exception_Init();
  53. }
  54. void USR_Init(void)
  55. {
  56. //Add your code here...
  57. TIME_Init();
  58. fml_adc_Init();
  59. bll_imu_Init();
  60. hal_battery_init();
  61. BLE_Client_Initialize();
  62. BLE_Host_Initialize();
  63. hal_wearshoes_Init();
  64. hal_qma_Init();
  65. hal_charge_init();
  66. //APP
  67. app_detect_Init();
  68. app_client_Initialize();
  69. app_host_Initialize();
  70. app_overturn_Init();
  71. app_charge_Init();
  72. app_step_Init();
  73. app_game_Init();
  74. app_math_Init();
  75. app_ota_Init();
  76. app_connect_manage_Init();
  77. app_switchimu_Init();
  78. app_data_transfer_Init();
  79. app_safe_Init();
  80. app_Authen_Init();
  81. #if LOSSPACK_ENANBLE
  82. app_losspack_Init();
  83. #endif
  84. #if !BleNameHoldOn_ENANBLE
  85. app_pair_chargerpin_Init();
  86. #endif
  87. watchdog_init();
  88. feed_watchdog();
  89. }