完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
让我先解释一下我想要达到的目标(我用的是cy8ckit-042-ble)。
我有两个独立的开发工具模块,我想他们之间的联系和沟通(一个模块作为服务器的一个模块作为客户端藏藏)。 连接应该很简单:那是在配对模式,开始自动对过程直到连接设备服务器搜索。 沟通应该完全独立(配对过程和通信过程),没有主机或PC连接。 到目前为止,我可以设置隐藏客户端使用连接到一个普通的Windows PC的描述符,这实际上是很容易安装(HID鼠标/ HID键盘代码的例子有很大的帮助)。 但现在我想连接到另一个柏模块作为隐藏服务器。我想达到的目标是,把客户端(鼠标为例)可以操作一个领导在把服务器端。这应该作为一个独立的设置。 最后我还想使用从商店一鼠标连接到隐藏的服务器(这是独立的柏树模块)。 简短摘要: 在自动配对客户端发送HID描述符和服务器解释HID描述符和打开一个基于LED的某一事件。 问题: 如何做到这一点(服务器实现)?有一个示例项目吗? 提前感谢, 保罗 以上来自于百度翻译 以下为原文 Let me first explain what I want to achieve (I'm using the CY8CKIT-042-BLE). I have two standalone BLE dev kit modules and I want to connect and communicate between them (one module act as HID server one module as HID client). The connection should go pretty straight forward: server searches for devices that are in pairing mode and starts auto pair process until connected. The communication should go entirely standalone (paring process and communications process), no host system or PC is hooked up. So far I'm able to setup the HID client using the descriptors connecting to a regular Windows PC. This is actually pretty easy to setup (HID mouse / HID keyboard code examples were a great help). But now I want to connect to another Cypress Module that acts as a HID server. What I want to achieve is that the HID client (mouse for example) can operate a LED on the HID server side. This should work as a standalone setup. Eventually I also want to be able to use a BLE mouse from the store and hook it up to the HID server (which is the standalone cypress module). Short summary: After auto-pairing the client sends HID descriptors and server interprets HID descriptors and turns on a LED based on a certain event. Questions:
Thanks in advance, Paul |
|
相关推荐
8个回答
|
|
嗨,保罗,
我相信您是要求GATT客户设计的。 PSoC Creator包括用于BLE HID键盘和HID鼠标的示例,这些服务器是HID。我不认为有客户端连接到这些设备的例子。 谢谢, 兰吉特 以上来自于百度翻译 以下为原文 Hi Paul, I believe you are asking for the GATT client designs. PSoC Creator includes examples for BLE HID Keyboard and HID Mouse which are servers. I don't think there are examples of a client connecting to these devices. Thanks, Ranjith |
|
|
|
sdfjaslkdjf1 发表于 2018-9-29 10:39 嗨,Ranjith, 也许我的服务器和客户端的术语不是正确的命名,但我不知道该如何更好地解释它。我把鼠标和键盘作为客户,对一些我称为服务器主机系统。 不是我想连接鼠标或键盘,它是这样的。 我想用一个单独的柏树(柏)和BLE模块连接普通HID鼠标吧。比方说,我用一个逻辑或微软BLE鼠标连接到这棵柏树模块运行在电池和理解藏(意为没有智能的PC / Windows系统是挂在这个用例)。 我想要的是经营LED按下鼠标点击,如果是可行的,然后我做了一个基础工作。 请参阅下面的图片说明我的用例。 干杯,保罗 以上来自于百度翻译 以下为原文 Hi Ranjith, Maybe my terminology of server and client are not the proper naming in the BLE world, but I don't know how I should explain it better. I consider the mouse or keyboards as clients that pair to some host system which I call server. It is not that I want to connect to the mouse or keyboard, it is the other way around. I want to use a stand alone Cypress BLE module (Cypress) and connect a regular HID mouse with it. Let's say I use a Logitech or Microsoft BLE mouse and connect it to this Cypress module which runs on a battery and understands HID (meaning no intelligent PC/Windows system is hooked up in this usecase). All I want is operate a LED by pressing a mouse click, if that is feasible then I got a foundation to work from. See my picture below that explains my use case. Cheers, Paul |
|
|
|
yuxiangxyz 发表于 2018-9-29 10:49 你好,保罗, 在蓝牙术语中,服务器是具有某种信息的设备(例如,在您的情况下,鼠标具有“按键”点击信息,因此它是服务器)。 - & gt;客户端是一种请求信息或你发送信息到它(在你的例子中,你将鼠标信息柏BLE设备和因此它是一个客户端) 客户端和服务器也被称为链路层主从分别与中枢和外周分别。 在这里,我们没有把客户准备的固件但你告诉你程序的柏树BLE设备与客户机/主机的角色,可以连接鼠标和按键可以闪烁LED在客户端设备(柏BLE设备) 请参考一个简单的例子,从下面的链接在中枢和外周作用。请找到随着文档的所有测试步骤之间进行通信的主从设备。 psoc-4-ble / 100_projects_in_100_days / day020_ble_uart大师·cypresssemiconductorco / psoc-4-ble·GitHub -吉安 以上来自于百度翻译 以下为原文 Hello Paul, -> In Bluetooth terminology ,Server is a device which has some information ( For example, in your case the Mouse has the 'Key' Click information and hence it is a server) -> Client is a device which request the information OR you send the information to it ( In your example, you are sending the Mouse information to Cypress BLE device and hence it is a client ) Client and Servers are also known as Link Layer Master and Slave respectively and also Central and Peripheral respectively. Here , we do not have an HID Client Ready Firmware but as you told you can program the Cypress BLE device with a Client/Master Role, can connect to the Mouse and on Key press can blink a LED on Client device ( Cypress BLE device) Please refer a sample example from the below link on Central and Peripheral roles. Please find a document along with which has all the testing steps to communicate between Master and Slave device. PSoC-4-BLE/100_Projects_in_100_Days/Day020_BLE_UART at master · cypresssemiconductorco/PSoC-4-BLE · GitHub -Gyan |
|
|
|
YHYDZ 发表于 2018-9-29 10:58 嗨,Gyan, 谢谢你指出我的正确方向,这是令我困惑的术语(GATT,GAP,中央,外围,观察员等)。 如果找到北欧半导体术语的一个很好的解释: HTTPS://DeZoNe.NordIMSI.COM/F/NODIC-Q-A/71/WIT-IS-A客户端和服务器端 我花了相当多的时间到Day20uBulyUART示例,但是由于这是在旧版本中创建的,所以我需要更新组件(我使用PSoC Creator 4.2),它首先需要被转换。这对于“UARTHI ToBuleCurrand”部分来说是很好的,但是对于“UARTHI ToBuffi外设”,它不能编译。 我已经检查并比较了PSoC Creator中的许多配置文件和设置,以及生成的输出文件,但我找不到根本原因。目录在那里,文件在那里,配置与“UARTHI ToBuffiCalm”相同。 我得到的错误: ARM- NOE-EABI- GC.EXE:错误:…..…\\\文档 PSoC创建者 4.2下载(4.2).CYLBBLUV3V3L51库GCCSCyBuffStAcKyBulySoCuleApdio.A:没有这样的文件或目录 命令“ARME EABI GCC .exe”退出代码“1”失败。 但是该文件肯定是存在的,并且它试图从${PrutoDIr}返回的文件夹数量也是正确的。 虽然我可以用完整路径来手工编译(CLI),但是它生成了“UARTHYTHOBLULL Engult.ELF”文件,但是IDE不接收它。 我想知道在哪里可以找到${PrimeDIr}和其他IDE变量的定义(见下文)。 我被困在这一部分,失败的编译/链接,在ARM NOE-EABI GC.EXE的部分问题。 有什么主意吗? 干杯, 保罗 以上来自于百度翻译 以下为原文 Hi Gyan, Thanks for pointing me out in the right Direction, it is the terminology that confuses me (GATT, GAP, Central, Peripheral, Observer, etc.). If found a nice explanation about the terminology at Nordic Semiconductor: https://devzone.nordicsemi.com/f/nordic-q-a/71/what-is-a-client-and-server-in-ble I've spent quite some time to the Day20_BLE_UART example, but due to the fact that this is created in an older version I need to update the components (I'm using PSoC Creator 4.2) it first needs to be converted. This goes well for the "UART_to_BLE_central" part but for the "UART_to_BLE_peripheral" it fails to compile. I've checked and compared many config files and settings in the PSoC Creator and also the generated output files but I'm not able to find the root cause. The Directory is there, the files are there and the config is identical of that of "UART_to_BLE_central". The error I get: arm-none-eabi-gcc.exe: error: ................DocumentsPSoC Creator4.2Downloads ( 4.2).cylibBLE_v3_51LibrarygccCyBLEStack_BLE_SOC_PERIPHERAL.a: No such file or directoryBut the file is definitely there, and the amount of folders that it tries to go back from the ${ProjectDir} is also correct. Although I was able to compile by hand (cli) using full path's and then it generates the "UART_to_BLE_peripheral.elf" file, but the IDE doesn't pick it up. I wonder where I can find the definitions of ${ProjectDir} and the other IDE variables (see below). I got stuck at this part where it fails compiling/linking at the part where arm-none-eabi-gcc.exe gave issues. Any idea's here? Cheers, Paul |
|
|
|
yuxiangxyz 发表于 2018-9-29 11:06 当您通过右键弹出界面为两个单独的项目“更新组件”时,需要更新两个项目的组件以获得良好的结果。 另外,请确保在构建旧的对象代码时删除干净的/不需要的构建文件(通常不是从我所看到的每次清理+生成的问题)。 以上来自于百度翻译 以下为原文 When you "Update Components" through the right-click popup interface for the two separate projects, you need to update the components for both projects to get good results Also, make sure you clean when you build to remove extraneous/unneeded build files with old object code in them (Usually not an issue to clean + build every time from what I've seen). |
|
|
|
yuhe82 发表于 2018-9-29 11:17 不幸的是,我已经做了所有这些。 但是经过长时间的搜索,我发现了问题所在!PSoC创建者4.2中的一个关于路径长度的bug,与Windows中的主文件夹结合使用。我为此创建了一个分离的主题,因为我做了一些测试场景来证明这一点。 以上来自于百度翻译 以下为原文 Unfortunately I did all of that already But after a long search I discovered the problem! A bug in PSoC creator 4.2 regarding path length's in combination with using the home folder in Windows. I've created a separated topic for this as I did some test scenario's to prove this. |
|
|
|
YHYDZ 发表于 2018-9-29 10:58 让我们继续HID服务器的线程,这实际上是“HID中心”,我相信。 我发现这个项目还有待进一步分析:Day011StimalLax观察员。 一旦我掌握了它,我就必须实现一个HID解析器。 或者还有其他图书馆可以使用吗? 以上来自于百度翻译 以下为原文 Let's continue the the thread about HID Server, which is in fact is "HID Central" I believe. I've found the project to analyse further: Day011_Central_Observer. Once I've got a grip on it I have to implement a HID Parser? Or is there any other library to use for this? |
|
|
|
yuxiangxyz 发表于 2018-9-29 11:44 从我所看到的,没有隐藏的解析器。通常,Windows /OS处理连接到它的HID服务器,因此您不会自己实现HID客户端。 看:隐藏主机键盘 HID服务器实例实现了一种HID库Irrc,因此实现HID客户端可能是简单的模仿,但反过来。 以上来自于百度翻译 以下为原文 There are not HID parsers from what I've seen. Generally, Windows/OS handles the HID servers connected to it, and thus you wouldn't be implementing the HID client yourself. See: HID BLE Host keyboard The HID server examples implement a sort of HID library iirc, so implementing an HID client might be as simple as mimicking that but in reverse. |
|
|
|
只有小组成员才能发言,加入小组>>
754个成员聚集在这个小组
加入小组2113 浏览 1 评论
1861 浏览 1 评论
3673 浏览 1 评论
请问可以直接使用来自FX2LP固件的端点向主机FIFO写入数据吗?
1794 浏览 6 评论
1540 浏览 1 评论
CY8C4025LQI在程序中调用函数,通过示波器观察SCL引脚波形,无法将pin0.4(SCL)下拉是什么原因导致?
582浏览 2评论
CYUSB3065焊接到USB3.0 TYPE-B口的焊接触点就无法使用是什么原因导致的?
434浏览 2评论
CX3连接Camera修改分辨率之后,播放器无法播出camera的画面怎么解决?
445浏览 2评论
393浏览 2评论
使用stm32+cyw43438 wifi驱动whd,WHD驱动固件加载失败的原因?
1025浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-31 07:15 , Processed in 1.115486 second(s), Total 90, Slave 74 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号