你好-我有一个定制设备与CyPress BLU4半导体安装和运行UARTHYTUBLULL中央代码项目(第20天)。该设备以中心模式运行。我的外围设备实际上是Android三星Galaxy S7手机,运行Java API 24。我在电话上创建了一个定制的Services,它复制了与USB BLE Gunle CyPress提供的开发工具包相同的服务。这一个:CY5670HTP://wwwyCyp.com /文档/开发-KITSBBOARDS/CY5670CySMART-UB-GELE移动应用程序能够成功地广告和连接中央,我可以查看数据包来回发送使用我的Hollong BLE Sniffer。我的问题很简单,但我需要帮助。连接后,如何将信息发送回设备?我从BLE技术中了解到,外围设备需要将更新广播回所有连接的设备,但是我不确定CyPress代码实际上在哪里读取这个。在连接完成后,扫描数据被恢复,我只收到1个写入请求到我的描述符回调函数,称为“启用通信”。我相信这是从AppsBule.c文件,VelueEnabeloTimeIsCd()函数中得到的。我希望它能在AppuUART.C代码中的空隙HealuuARTTXCuffic(空)函数成功的BLE连接之后处理所有请求。在监视嗅探器中的日志时,似乎通信一直在PDU分组中发送,但由于任何东西都没有击中我的回调函数,所以我无法检索其中任何一个。有没有使用Cype产品的Android BLE开发的经验?欢迎大家提出意见和问题。 以上来自于百度翻译 以下为原文Hello- I have a custom device with a Cypress BLE4 Semiconductor installed and running the UART_to_BLE_central code project (day 20).This device is running in central mode.My peripheral is actually an Android Samsung Galaxy S7 phone runing Java API 24.I have created a custom serivce on the phone that replicates the same service as the USB BLE Dongle Cypress provides with the development kit.This one: CY5670 http://www.cypress.com/documentation/development-kit***oards/cy5670-cysmart-u***-dongle The Mobile App is able to advertise and connects successfully with the central and I can view Data Packets being sent back and forth using my Hollong BLE Sniffer.My question is pretty simple but I need help with it.After connection, how do I send information back to the device?I understand from BLE technology that the Peripheral needs to broadcast updates back to all connected devices however I am not sure where the Cypress code is actually reading this.After connection is made and the Scan data is returrned I only recieve 1 Write request to my Descriptor callback function saying to "Enable Communctions".I believe this is from the app_BLE.c file, void enableNotifications() function. What I expect is for it to handle all requests after the successful BLE connection at the void HandleUartTxTraffic(void) function in app_UART.c code. While monitoring the logs from the sniffer it seems that communications is consistently being sent in the PDU packets but I am unable to retrieve any of it because nothing is hitting my callback function.Anyone have experience with Android BLE development with Cypress products?All comments and questions welcome.
2018-09-19 15:14