久久久久久久999_99精品久久精品一区二区爱城_成人欧美一区二区三区在线播放_国产精品日本一区二区不卡视频_国产午夜视频_欧美精品在线观看免费

標題: bc26 NBiot模塊原理圖pcb源碼 [打印本頁]

作者: zhangsmart1101    時間: 2024-8-21 15:27
標題: bc26 NBiot模塊原理圖pcb源碼


  1. #include "main.h"
  2. #include "usart.h"
  3. #include "timer.h"
  4. #include "BC26.h"
  5. #include "led.h"
  6. #include "SMP.h"
  7. #include "systempz.h"
  8. GPIO_InitTypeDef GPIO_InitStructure;
  9. static __IO uint32_t TimingDelay;
  10. extern int err;
  11. //***與服務(wù)器進行交互,模塊可以通過UDP方式傳數(shù)據(jù)到服務(wù)器端,服務(wù)器也可以支持下發(fā)數(shù)據(jù)到設(shè)備端進行顯示打印*****************/
  12.         /* Private function prototypes -----------------------------------------------*/
  13.         void Delay(__IO uint32_t nTime);
  14. /** @addtogroup Template_Project
  15.   * @{
  16.   */

  17. /**
  18.   * @brief  Main program.
  19.   * @param  None
  20.   * @retval None
  21.   */
  22. int main(void)
  23. {
  24.     if (SysTick_Config(SystemCoreClock / 1000))//設(shè)置24bit定時器 1ms中斷一次
  25.     {
  26.         /* Capture error */
  27.         while (1);
  28.     }
  29.     LED_Init();
  30.     uart1_init(115200);
  31.     uart2_init(115200);
  32.     uart3_init(115200);
  33.     printf("\r\n ############  ############\r\n ############("__DATE__ " - " __TIME__ ")############");
  34.     ////////液晶屏的顯示驅(qū)動//////
  35.     GPIO_Configuration();
  36.     printf("INIT EINK EINK GPIO\r\n");
  37.     MYRESET();                   // 電子紙控制器硬件復(fù)位
  38.     printf("EINK LCD RESET..\r\n");
  39.     READBUSY();
  40.     printf("EINK BUSY READ..\r\n");
  41.     INIT_SSD1673();
  42.     printf("EINK DISPLAY BMP PICTURE OK\r\n");
  43.     ////////////////

  44.     Uart1_SendStr("init stm32L COM1 \r\n"); //打印信息
  45.     //Uart2_SendStr("init stm32L COM2 \r\n"); //和NBIOT連接
  46.     Uart3_SendStr("init stm32L COM3 \r\n"); //用于其他TTL或者485
  47.     while(BC26_Init());
  48.     BC26_PDPACT();
  49.     BC26_ConUDP();

  50.     while (1)
  51.     {
  52.         BC26_Senddata("15","123\r\n");//發(fā)數(shù)據(jù)
  53.         Delay(1000);
  54.         BC26_RECData();
  55.         GPIO_ToggleBits(GPIOC,GPIO_Pin_3);//翻轉(zhuǎn)LED  
  56.         
  57.     }
  58. }




  59. /**
  60.   * @brief  Inserts a delay time.
  61.   * @param  nTime: specifies the delay time length, in milliseconds.
  62.   * @retval None
  63.   */
  64. void Delay(__IO uint32_t nTime)
  65. {
  66.     TimingDelay = nTime;

  67.     while(TimingDelay != 0);
  68. }

  69. /**
  70.   * @brief  Decrements the TimingDelay variable.
  71.   * @param  None
  72.   * @retval None
  73.   */
  74. void TimingDelay_Decrement(void)
  75. {
  76.     if (TimingDelay != 0x00)
  77.     {
  78.         TimingDelay--;
  79.     }
  80. }
  81. #ifdef  USE_FULL_ASSERT

  82. /**
  83.   * @brief  Reports the name of the source file and the source line number
  84.   *         where the assert_param error has occurred.
  85.   * @param  file: pointer to the source file name
  86.   * @param  line: assert_param error line source number
  87.   * @retval None
  88.   */
  89. void assert_failed(uint8_t* file, uint32_t line)
  90. {
  91.     /* User can add his own implementation to report the file name and line number,
  92.      ex: printf("Wrong parameters value: file %s on line %d\r\n", file, line) */

  93.     /* Infinite loop */
  94.     while (1)
  95.     {
  96.     }
  97. }
  98. #endif

  99. /**
  100.   * @}
  101.   */
復(fù)制代碼

還未完成,僅供參考: bc26.7z (1.96 MB, 下載次數(shù): 3)





歡迎光臨 (http://www.zg4o1577.cn/bbs/) Powered by Discuz! X3.1
主站蜘蛛池模板: 色天天综合 | 欧美成年黄网站色视频 | 日韩视频一区二区 | 一区二区三区四区av | 91视频免费黄 | 91秦先生艺校小琴 | 欧美一级淫片免费视频黄 | 成人免费毛片在线观看 | 99久热| 午夜视频一区二区三区 | 亚洲iv一区二区三区 | 国产区在线| 一区二区三区影院 | 毛色毛片免费看 | 在线免费观看毛片 | 免费成人毛片 | 欧美国产精品一区二区三区 | 午夜精品影院 | 久久精品国产99国产精品 | 成人亚洲精品久久久久软件 | 亚洲电影一区二区三区 | 亚洲综合区 | 亚洲欧美日韩在线不卡 | 日韩一 | 亚洲国产成人精品久久 | 国产精品黄色 | 91干b| 亚洲一区二区三区在线 | 久久激情视频 | 超黄毛片 | 成人精品国产一区二区4080 | 日本a网站 | 欧美黑人一区 | 国产日韩欧美激情 | 人人看人人射 | 欧美亚洲另类丝袜综合网动图 | 成人国产在线观看 | 免费成人在线网站 | 一区二区三区中文字幕 | 精品一区二区电影 | 欧美一区二区三区视频在线观看 |