QN9080-001-M17-BLE Add an array for transfer

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

QN9080-001-M17-BLE Add an array for transfer

2,220 Views
1758793535
Contributor I

Hello 

I don't want to write or read data through the terminal. I want to add an array in 001-m17-ble program to put my prepared data in it. Then every time I read it with my mobile phone, 001-m17 will send one of the data in the array to my mobile phone. How do I add this array?

Thank you!

Labels (2)
0 Kudos
Reply
7 Replies

2,202 Views
Ricardo_Zamora
NXP TechSupport
NXP TechSupport

Hi,

 

Hope you are doing well. What example are you using as a base? What do you mean with "Then every time I read it with my mobile phone, 001-m17 will send one of the data in the array"?

Could you clarify?

 

Regards,

Ricardo

0 Kudos
Reply

2,200 Views
1758793535
Contributor I

Hello.

This is the case. I built a map of my house. Now I'm going to select a few pairs of coordinates from my map, turn them into an array and write them into a routine. After this routine establishes a connection with my mobile phone, I read these coordinates through my mobile phone. Each time I read them, 001-M17 will return a pair of coordinate values to my mobile phone.

Thank you!项目工程文件.png

 

0 Kudos
Reply

2,185 Views
Ricardo_Zamora
NXP TechSupport
NXP TechSupport

Hi,

 

From your description, I think the Wireless UART may not be the best example. I would recommend to check these post:

Creating a custom profile using NXP BLE stack – Server  

How to create a Custom Profile - Client 

Still, if for any reason you want to continue with this example, you should check the void BleApp_FlushUartStream(void *pParam) function, as in this is the one that sends data over the air.

I would recommend focusing on this section, if you don't want to "receive" from the terminal, but you can add here the coordinates data you mention, to send it to your phone.

FlushUart.png

 

Hope this helps.

Regards,

Ricardo

0 Kudos
Reply

2,130 Views
1758793535
Contributor I

HI

In the end, I determined a method, or I need to modify the program of this diagram provided by you. The part I modified is shown in the second diagram, but the third diagram will have a warning. How can I modify it to avoid a warning?

Thank you!串口流更新1.png串口流更新2+修改.png修改后警告.png

0 Kudos
Reply

2,156 Views
1758793535
Contributor I

In gatt_db.h, I'm going to replace (" MANUFACTURER_NAME ") with a function (#define) that returns an integer. specific code of the modification is shown in the figure below. But this always results in some errors. I don't know how to modify it.%R6{(RHA(ACXGJ(I$D_(OEL.png(UY%3QZOUR`6U5RSVR59C60.pngVLV0}0DF}}7[_Y3_D8]CGX4.png

0 Kudos
Reply

2,161 Views
1758793535
Contributor I

Hello.

I want to replace the PMG in it with an array. Can this be realized? How can I modify it.

Thank you!

0 Kudos
Reply

2,179 Views
1758793535
Contributor I

I think of a way: can the battery service or device information service in the following picture be changed to an array? For example, replace "manufacturer's_name" with an array, and then I can see the data in the array when I read it on my mobile phone.服务修改.png

0 Kudos
Reply