319 lines
9.1 KiB
C
319 lines
9.1 KiB
C
|
|
/****************************************************************************
|
|||
|
|
** BLE.c
|
|||
|
|
**
|
|||
|
|
** Copyright (c) Siargo Ltd. 2020
|
|||
|
|
** All Rights Reserved.
|
|||
|
|
**
|
|||
|
|
** BY DMY
|
|||
|
|
**
|
|||
|
|
** <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͨѶģ<EFBFBD><EFBFBD>
|
|||
|
|
**
|
|||
|
|
**
|
|||
|
|
** <EFBFBD><EFBFBD>ʷ<EFBFBD>ļ<EFBFBD>
|
|||
|
|
** 2026-03-09 V1000
|
|||
|
|
*****************************************************************************/
|
|||
|
|
|
|||
|
|
/* Includes ----------------------------------------------------------------*/
|
|||
|
|
#include "../main/SystemInclude.h"
|
|||
|
|
/* -------------------<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>--------------------------------------*/
|
|||
|
|
extern DMA_HandleTypeDef DMA_Handle_UartRx , DMA_Handle_UartTx ;
|
|||
|
|
|
|||
|
|
static u8 BLE_resp = BLE_WAIT;
|
|||
|
|
|
|||
|
|
uint8_t Series[12]={0,1,2,3,4,5,6,7,8,9,10,11};
|
|||
|
|
uint8_t BLE_count;
|
|||
|
|
uint8_t BLE_flag;
|
|||
|
|
|
|||
|
|
u8 BLE_at_response_check(u8 *resp, u8 check_resp)
|
|||
|
|
{// <20>ȴ<EFBFBD><C8B4><EFBFBD><EFBFBD><EFBFBD>ģ<EFBFBD>鷵<EFBFBD>ص<EFBFBD><D8B5><EFBFBD>Ϣ
|
|||
|
|
u8 count = 0;
|
|||
|
|
while(*resp != check_resp)
|
|||
|
|
{
|
|||
|
|
delay_ms(10);
|
|||
|
|
count++;
|
|||
|
|
if(count == 100) //<2F>ȴ<EFBFBD>1s<31><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȼû<C8BB>и<EFBFBD><D0B8>£<EFBFBD><C2A3><EFBFBD><EFBFBD><EFBFBD>ʾģ<CABE><C4A3>û<EFBFBD>з<EFBFBD><D0B7>أ<EFBFBD><D8A3><EFBFBD><EFBFBD>ܿ<EFBFBD><DCBF><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
return 1;
|
|||
|
|
}
|
|||
|
|
return 0;
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
u8 BLE_at_cmd_write(char *pbuf)
|
|||
|
|
{
|
|||
|
|
BLE_resp = BLE_WAIT;
|
|||
|
|
BLE_SendData((u8*)pbuf, strlen(pbuf));
|
|||
|
|
return BLE_at_response_check(&BLE_resp, BLE_OK);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
u8 BLE_at_rec_process(char *inbuf, u8 data_len)// <20><><EFBFBD><EFBFBD>ģ<EFBFBD>鴫<EFBFBD><E9B4AB>MCU<43><55><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д
|
|||
|
|
{
|
|||
|
|
int i = 0;
|
|||
|
|
u8 resp;
|
|||
|
|
if (strstr(inbuf,"ERROR\r"))
|
|||
|
|
{
|
|||
|
|
resp = BLE_ERROR;
|
|||
|
|
} else if(strstr(inbuf,"OK\r")) {
|
|||
|
|
resp = BLE_OK;
|
|||
|
|
} else {
|
|||
|
|
resp = BLE_OTHER;
|
|||
|
|
}
|
|||
|
|
return resp;
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
void BLE_lp_exit(void)
|
|||
|
|
{
|
|||
|
|
LHL_GPIO_WritePin(BLE_CTS_GPIO, BLE_CTS_PIN, GPIO_PIN_SET);
|
|||
|
|
delay_ms(1);
|
|||
|
|
LHL_GPIO_WritePin(BLE_CTS_GPIO, BLE_CTS_PIN, GPIO_PIN_RESET);
|
|||
|
|
delay_ms(1);
|
|||
|
|
}
|
|||
|
|
void BLE_lp_enter(void)
|
|||
|
|
{
|
|||
|
|
BLE_at_cmd_write("AT+SLEEP=0,1\r\n");
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
void BLE_metering_packet_send(void)
|
|||
|
|
{
|
|||
|
|
char tx_buf[256];
|
|||
|
|
BLE_lp_exit();
|
|||
|
|
BLE_at_cmd_write(tx_buf);
|
|||
|
|
BLE_at_cmd_write("AT+ADS=1,0,1000\r\n");
|
|||
|
|
}
|
|||
|
|
void BLE_identification_packet_send(void)
|
|||
|
|
{
|
|||
|
|
char tx_buf[256];
|
|||
|
|
BLE_lp_exit();
|
|||
|
|
|
|||
|
|
BLE_at_cmd_write(tx_buf);
|
|||
|
|
BLE_at_cmd_write("AT+ADS=1,0,100\r\n");
|
|||
|
|
}
|
|||
|
|
void BLE_beacon_check(void)
|
|||
|
|
{
|
|||
|
|
BLE_count++;
|
|||
|
|
if(BLE_count == 236)
|
|||
|
|
BLE_flag = BLE_FLAG_ID;// <20><>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƿ<EFBFBD><C7B7><EFBFBD> ID <20><>
|
|||
|
|
else if(BLE_count == 240){
|
|||
|
|
BLE_count = 0;;// <20><>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ü<EFBFBD><C3BC><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
BLE_flag = BLE_FLAG_METER;// <20><><EFBFBD>Ƿ<EFBFBD><C7B7>ͼ<EFBFBD><CDBC><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
}
|
|||
|
|
else
|
|||
|
|
;
|
|||
|
|
}
|
|||
|
|
void BLE_beacon_done(void)
|
|||
|
|
{
|
|||
|
|
if(BLE_flag == BLE_FLAG_METER){
|
|||
|
|
BLE_metering_packet_send();
|
|||
|
|
BLE_flag = 0;
|
|||
|
|
}
|
|||
|
|
else if(BLE_flag == BLE_FLAG_ID){
|
|||
|
|
BLE_identification_packet_send();
|
|||
|
|
BLE_flag = 0;
|
|||
|
|
}
|
|||
|
|
else
|
|||
|
|
;
|
|||
|
|
}
|
|||
|
|
/**
|
|||
|
|
* @brief <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ձ<EFBFBD>־
|
|||
|
|
*/
|
|||
|
|
static inline void ClearRxFlag(void)
|
|||
|
|
{
|
|||
|
|
comState.state.ReceivedData = 0;
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/******<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*************************************************************************************************************/
|
|||
|
|
void BLE_init(void)
|
|||
|
|
{
|
|||
|
|
GPIO_InitTypeDef GPIO_InitStruct;
|
|||
|
|
// CTS <20><><EFBFBD><EFBFBD>ģʽ (<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ؼ<EFBFBD><D8BC><EFBFBD>)
|
|||
|
|
GPIO_InitStruct.Pin = BLE_CTS_PIN;
|
|||
|
|
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
|
|||
|
|
GPIO_InitStruct.Current = GPIO_CURRENT_2mA;
|
|||
|
|
GPIO_InitStruct.Pull = GPIO_PULLUP;
|
|||
|
|
GPIO_InitStruct.SchmittTrigger = ENABLE;
|
|||
|
|
GPIO_InitStruct.Alternate = GPIOx_AF_GPIO; // // AFΪ<46><CEAA>ͨIO
|
|||
|
|
LHL_GPIO_Init(BLE_CTS_GPIO, &GPIO_InitStruct);
|
|||
|
|
|
|||
|
|
// RST
|
|||
|
|
GPIO_InitStruct.Pin = BLE_RST_PIN;
|
|||
|
|
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
|
|||
|
|
GPIO_InitStruct.Current = GPIO_CURRENT_2mA;
|
|||
|
|
GPIO_InitStruct.Pull = GPIO_NOPULL;
|
|||
|
|
GPIO_InitStruct.SchmittTrigger = ENABLE;
|
|||
|
|
GPIO_InitStruct.Alternate = GPIOx_AF_GPIO; // // AFΪ<46><CEAA>ͨIO
|
|||
|
|
LHL_GPIO_Init(BLE_RST_GPIO, &GPIO_InitStruct);
|
|||
|
|
|
|||
|
|
//3. Ĭ<><C4AC><EFBFBD><EFBFBD><EFBFBD>߸<EFBFBD>λ<EFBFBD><CEBB>
|
|||
|
|
LHL_GPIO_WritePin(BLE_CTS_GPIO, BLE_CTS_PIN, GPIO_PIN_RESET);
|
|||
|
|
LHL_GPIO_WritePin(BLE_RST_GPIO, BLE_RST_PIN, GPIO_PIN_SET);
|
|||
|
|
delay_ms(1000);
|
|||
|
|
|
|||
|
|
char tx_buf[256];
|
|||
|
|
BLE_at_cmd_write("+++"); // <20><><EFBFBD><EFBFBD> AT ָ<><D6B8>ģʽ
|
|||
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƣ<EFBFBD>SIARGO + <20><><EFBFBD>к<EFBFBD> (Hex<65><78>ʽ)
|
|||
|
|
sprintf(tx_buf, "AT+NAME=1,53494152%x%x%x%x%x%x%x%x%x%x\r\n", Series[1], Series[2], Series[3],
|
|||
|
|
Series[4], Series[5], Series[6], Series[7], Series[8], Series[9], Series[10] );
|
|||
|
|
BLE_at_cmd_write(tx_buf);
|
|||
|
|
// <20><><EFBFBD><EFBFBD> AT+EXIT <20>˳<EFBFBD> AT ģʽ<C4A3><CABD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><CDB8>ģʽ
|
|||
|
|
// <20>˺<EFBFBD><CBBA><EFBFBD>ģ<EFBFBD>齫<EFBFBD><E9BDAB><EFBFBD>ٽ<EFBFBD><D9BD><EFBFBD> AT ָ<><EFBFBD><EEA3AC><EFBFBD>д<EFBFBD><D0B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݽ<EFBFBD>ֱ<EFBFBD><D6B1><EFBFBD><CDB8><EFBFBD><EFBFBD> MCU
|
|||
|
|
BLE_at_cmd_write("AT+EXIT\r\n");
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
void BLE_HardwareReset(void)
|
|||
|
|
{
|
|||
|
|
// <20><><EFBFBD><EFBFBD>λ
|
|||
|
|
LHL_GPIO_WritePin(BLE_RST_GPIO, BLE_RST_PIN, GPIO_PIN_RESET);
|
|||
|
|
delay_ms(BLE_RESET_HOLD_TIME);
|
|||
|
|
|
|||
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD>ͷ<EFBFBD>
|
|||
|
|
LHL_GPIO_WritePin(BLE_RST_GPIO, BLE_RST_PIN, GPIO_PIN_SET);
|
|||
|
|
delay_ms(BLE_RESET_WAIT_TIME);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
void BLE_SendData(uint8_t *pData, uint16_t len)
|
|||
|
|
{
|
|||
|
|
if (pData == NULL || len == 0) return;
|
|||
|
|
// ֹ֮ͣǰ<D6AE><C7B0><EFBFBD><EFBFBD>
|
|||
|
|
// LHL_DMA_Stop(&DMA_Handle_UartTx);
|
|||
|
|
// // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
// memcpy(comState.TxdData, pData, len);
|
|||
|
|
MBBuf.TxdLen = len;
|
|||
|
|
MBBuf.TxPointer =pData ;
|
|||
|
|
StartDMAForTxdMainUartData();
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
void BLEModBusReturnDevice(void)
|
|||
|
|
{
|
|||
|
|
MBBuf.RxPointer[0] = 0x01; // <20>ӻ<EFBFBD><D3BB><EFBFBD>ַ
|
|||
|
|
MBBuf.RxPointer[1] = 0x2B; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> (<28>Զ<EFBFBD><D4B6><EFBFBD>)
|
|||
|
|
MBBuf.RxPointer[2] = 0x0E; // <20><><EFBFBD><EFBFBD>
|
|||
|
|
MBBuf.RxPointer[3] = 0x01;
|
|||
|
|
MBBuf.RxPointer[4] = 0x01;
|
|||
|
|
MBBuf.RxPointer[5] = 0xFF;
|
|||
|
|
MBBuf.RxPointer[6] = 0x05;
|
|||
|
|
MBBuf.RxPointer[7] = 0x03;
|
|||
|
|
MBBuf.RxPointer[8] = 0x00;
|
|||
|
|
MBBuf.RxPointer[9] = 0x0D;
|
|||
|
|
// Ӳ<><D3B2><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><D6B7><EFBFBD> "SIARGO-MF5700"
|
|||
|
|
MBBuf.RxPointer[10] = 0x53;//S
|
|||
|
|
MBBuf.RxPointer[11] = 0x49; //I
|
|||
|
|
MBBuf.RxPointer[12] = 0x41;//A
|
|||
|
|
MBBuf.RxPointer[13] = 0x52;//R
|
|||
|
|
MBBuf.RxPointer[14] = 0x47;//G
|
|||
|
|
MBBuf.RxPointer[15] = 0x4F;//O
|
|||
|
|
MBBuf.RxPointer[16] = 0x2D;//-
|
|||
|
|
MBBuf.RxPointer[10] = 0x56; // V
|
|||
|
|
MBBuf.RxPointer[11] = 0x4D; // M
|
|||
|
|
MBBuf.RxPointer[12] = 0x31; // 1
|
|||
|
|
MBBuf.RxPointer[13] = 0x30; // 0
|
|||
|
|
MBBuf.RxPointer[14] = 0x30; // 0
|
|||
|
|
MBBuf.RxPointer[15] = 0x30; // 0
|
|||
|
|
MBBuf.RxPointer[23] = 0x02;//XULEIHAO (<28><><EFBFBD>ͺ<EFBFBD>?)
|
|||
|
|
MBBuf.RxPointer[24] = 0x0C; // <20><><EFBFBD>кų<D0BA><C5B3><EFBFBD>
|
|||
|
|
MBBuf.RxPointer[25] = Series[0]; // <20><><EFBFBD><EFBFBD>10λ<30><CEBB><EFBFBD>к<EFBFBD>
|
|||
|
|
MBBuf.RxPointer[26] = Series[1];
|
|||
|
|
MBBuf.RxPointer[27] = Series[2];
|
|||
|
|
MBBuf.RxPointer[28] = Series[3];
|
|||
|
|
MBBuf.RxPointer[29] = Series[4];
|
|||
|
|
MBBuf.RxPointer[30] = Series[5];
|
|||
|
|
MBBuf.RxPointer[31] = Series[6];
|
|||
|
|
MBBuf.RxPointer[32] = Series[7];
|
|||
|
|
MBBuf.RxPointer[33] = Series[8];
|
|||
|
|
MBBuf.RxPointer[34] = Series[9];
|
|||
|
|
MBBuf.RxPointer[35] = Series[10];
|
|||
|
|
MBBuf.RxPointer[36] = Series[11];
|
|||
|
|
MBBuf.RxPointer[37] = 0x02;
|
|||
|
|
MBBuf.RxPointer[38] = 0x04;
|
|||
|
|
// MBBuf.RxPointer[39] = MAJ_VERSION; // <20>̼<EFBFBD><CCBC>汾
|
|||
|
|
// MBBuf.RxPointer[40] = SUB_VERSION;
|
|||
|
|
// MBBuf.RxPointer[41] = REV_VERSION;
|
|||
|
|
// MBBuf.RxPointer[42] = BUD_VERSION;
|
|||
|
|
MBBuf.RxPointer[39] = 0x0a; // <20>̼<EFBFBD><CCBC>汾
|
|||
|
|
MBBuf.RxPointer[40] = 0x0b;
|
|||
|
|
MBBuf.RxPointer[41] = 0x0c;
|
|||
|
|
MBBuf.RxPointer[42] = 0x0d;
|
|||
|
|
MBBuf.RxPointer[43] = 0x03;
|
|||
|
|
MBBuf.RxPointer[44] = 0x01;
|
|||
|
|
MBBuf.RxPointer[45] = 0x00;
|
|||
|
|
MBBuf.RxPointer[46] = 0x04;
|
|||
|
|
MBBuf.RxPointer[47] = 0x01;
|
|||
|
|
MBBuf.RxPointer[48] = 0x00;
|
|||
|
|
|
|||
|
|
MBBuf.TxdLen =49;
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
void BLEModBusReturnData(void)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
u8 tx_Length;
|
|||
|
|
|
|||
|
|
tx_Length = 0;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x01;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x42;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x0c;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x3A;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x3C;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x3E;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x37;
|
|||
|
|
//MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
// MBBuf.RxPointer[tx_Length++] = 0x48;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x50;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x51;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x90;
|
|||
|
|
|
|||
|
|
MBBuf.RxPointer[2] = tx_Length - 3;
|
|||
|
|
MBBuf.TxdLen=tx_Length;
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
void BLEModBusReturnparameter(void)
|
|||
|
|
{
|
|||
|
|
u8 tx_Length;
|
|||
|
|
|
|||
|
|
tx_Length = 0;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x01;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x43;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x12;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x83;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x85;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x8B;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x96;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x98;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x9A;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x9C;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0xF2;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0x00;
|
|||
|
|
MBBuf.RxPointer[tx_Length++] = 0xF0;
|
|||
|
|
MBBuf.RxPointer[2] = tx_Length - 3;
|
|||
|
|
MBBuf.TxdLen=tx_Length;
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* @brief <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʼ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
* @note <EFBFBD>˺<EFBFBD><EFBFBD><EFBFBD>ֻ<EFBFBD><EFBFBD>Ӳ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>λ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD>ʼ<EFBFBD><EFBFBD>־<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
*/
|
|||
|
|
void BLE_Application_Init(void)
|
|||
|
|
{
|
|||
|
|
/* ==================== <20><> 1 <20><><EFBFBD><EFBFBD>Ӳ<EFBFBD><D3B2><EFBFBD><EFBFBD>ʼ<EFBFBD><CABC> ==================== */
|
|||
|
|
// 1.1 <20><><EFBFBD>õײ<C3B5><D7B2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʼ<EFBFBD><CABC> GPIO (CTS/RTS/RST)
|
|||
|
|
BLE_init();
|
|||
|
|
//Ӳ<><D3B2><EFBFBD><EFBFBD>λ
|
|||
|
|
// LHL_GPIO_WritePin(BLE_RST_GPIO, BLE_RST_PIN, GPIO_PIN_RESET);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|