Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
RT200T_ESP32
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
RT200T
RT200T_ESP32
Commits
12523274
Commit
12523274
authored
Jun 24, 2024
by
时昊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
✨
feat:修改发送胎压数据,收到就会发送
parent
ab80e4bc
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
9 deletions
+12
-9
Protocol_User.c
RT200T_2_ESP32/main/Protocol_User.c
+6
-6
gattc_demo.c
RT200T_2_ESP32/main/gattc_demo.c
+6
-3
No files found.
RT200T_2_ESP32/main/Protocol_User.c
View file @
12523274
...
...
@@ -379,14 +379,14 @@ void Uart_Send_Id01_Pro(void)
// //
// }
if
(
arraysEqual
(
ID01_Backup
,
ID01
,
64
)
==
1
)
//相等
{
//printf("send 相等 \r\n");
}
else
//
if(arraysEqual(ID01_Backup, ID01, 64) == 1)//相等
//
{
//
//printf("send 相等 \r\n");
//
}
//
else
{
Protocol_Send
(
0x01
,
ID01
,
ID01_Len
);
memcpy
(
ID01_Backup
,
ID01
,
64
);
//
memcpy(ID01_Backup, ID01, 64);
}
...
...
RT200T_2_ESP32/main/gattc_demo.c
View file @
12523274
...
...
@@ -353,7 +353,7 @@ static void esp_gap_cb(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_param_t *par
//esp_log_buffer_hex(GATTC_TAG, scan_result->scan_rst.bda, 6);//尤其是当你需要查看设备地址、UUID ,Mac地址。
//if((scan_result->scan_rst.bda[4] == 0x22)||(scan_result->scan_rst.bda[4] == 0x1c))
{
//
{
//ESP_LOGI(GATTC_TAG, "searched Adv Data Len %d, Scan Response Len %d", scan_result->scan_rst.adv_data_len, scan_result->scan_rst.scan_rsp_len);
//adv_name = esp_ble_resolve_adv_data(scan_result->scan_rst.ble_adv,ESP_BLE_AD_TYPE_NAME_CMPL, &adv_name_len);
...
...
@@ -393,11 +393,14 @@ static void esp_gap_cb(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_param_t *par
for
(
i
=
0
;
i
<
scan_result
->
scan_rst
.
adv_data_len
;
i
++
)
{
ID01
[
i
]
=
scan_result
->
scan_rst
.
ble_adv
[
i
];
}
}
// else
// {
// memset(ID01, 0, sizeof(ID01));
// }
//printf("地址:%x \r\n",scan_result->scan_rst.bda[4]);
}
//
}
#if CONFIG_EXAMPLE_DUMP_ADV_DATA_AND_SCAN_RESP
if
(
scan_result
->
scan_rst
.
adv_data_len
>
0
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment