1
完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
如果C #代码使用cysmart API设置有一个梗概的例子跟狗??
参考指南不提供的,其不清楚至少如何正确启动的东西给我,等。 以上来自于百度翻译 以下为原文 Wondering if there is a bare bones example in C# code using the CySmart API to setup and talk to the dongle ?? The reference guide does not provide one, and its not clear to me at least how to properly start things up, etc.. |
|
相关推荐
14个回答
|
|
如果您打开一个案例,您可以从CyPress获得完整的代码。我知道没有赤骨的例子。
以上来自于百度翻译 以下为原文 You can get the complete code from Cypress if you open a case. There are no barebone examples that I know of. |
|
|
|
谢谢。。我去试试。 以上来自于百度翻译 以下为原文 Thanks.. I'll give that a go.. |
|
|
|
显然CyPress不共享CyScript应用程序的C源,也不提供任何其他示例来帮助API驱动应用程序离开地面。不是我们期待的“有用的反应”。我们建议签下NDA来偷看…我们来看看这是怎么回事。叹息
否则,他们对我的反应有点令人失望: “感谢您联系柏树技术支持。目前,我们没有使用CysARTAPI API的任何示例源代码。 在对CyScript代码本身进行了第二次查询之后: “Windows工具的CyScript源代码是内部的,不能共享。我们提供了在http://www. Cypress .com /文档/软件和驱动程序/ CySMixBluetooth LE测试和调试工具中提供的CyStAPI API参考指南。 以上来自于百度翻译 以下为原文 Apparently Cypress does not share the C# sources to the CySmart app, nor do they provide any other example as an option to help get an API driven application off the ground... not the 'helpful response' we were expecting.. we've suggested signing an NDA to get a peek.. we'll see how that goes.. sigh.. Otherwise, their response to my case has been a bit disappointing: "Thanks for contacting Cypress Technical support. Currently we don't have any example source code using Cymsart API." And after a second inquiry about the CySmart code itself: "The CySmart source code for windows tool is internal and cannot be shared. We provide CySmart API reference guide available at http://www.cypress.com/documentation/software-and-drivers/cysmart-bluetooth-le-test-and-debug-tool." |
|
|
|
我已经附上了使用CySMARTC API API的示例代码。我希望这有帮助。如果您有任何问题,或者如果您遇到代码的任何问题,请告诉我。
邮编 619.9 K 以上来自于百度翻译 以下为原文 I have attached a sample code for using CySmart C# APIs. I hope this helps. Let me know if you have any questions or if you face any problems with the code.
|
|
|
|
60user115 发表于 2019-2-25 07:12 谢谢你的样品!我设计电子产品并开发嵌入式软件/固件。我开发了一个蓝牙仪器,需要制作一个演示应用程序,但我不知道C。我能够学习和扩大你的样品。谢谢!!!! 以上来自于百度翻译 以下为原文 grsr, Thank you very much for your samples! I design electronics and develop embedded software/firmware. I developed a Bluetooth instrument and needed to make a demo app but I don't know C#. I was able to study and expand your samples. Thanks!!! |
|
|
|
你好,
将使用您的示例代码。这个代码从PSoC读取数据。我需要从计算机发送数据到PSoC。我该怎么做呢? 以上来自于百度翻译 以下为原文 Hi GRSR, ı will use your example code. this code read a data from psoc. I need send a data from computer to psoc. How can I do this ? |
|
|
|
如果您的问题意味着从CyStas-GeLE(GATT客户端)向PSoC BLE(GATT服务器)发送数据,那么GATT客户端首先应该在建立连接后发现GATT服务器上的属性。然后,您需要使用CyStaseAPI写特性(CygTtWrITeFielo信息)。CygTrWrITeFipe将封装需要发送的数据。尝试使用CyStAPI API进行属性发现和特性读写,如果遇到任何困难,请告诉我。CyStAPI API参考指南可在POST第4版中提到的链接中获得。必要时附上项目代码。 以上来自于百度翻译 以下为原文 If your question implies sending data from CySmart dongle (GATT client) to PSoC BLE (GATT server) then first the GATT client should discover attributes on the GATT server after establishing connection. Then you need to use the CySmart API WriteCharacteristic (CyGattWriteInfo info). The class CyGattWriteInfo will encapsulate the data you need to send. Try implementing the CySmart APIs for attribute discovery and characteristic read or write and let me know if you face any difficulties. The CySmart API reference guide is available at the link mentioned in post#4. Attach the project code if necessary. |
|
|
|
60user115 发表于 2019-2-25 07:12 HigrSR 非常感谢您的样品! 如果你能共享正确的序列,那么就可以帮助你读取那些被发送到CopStaskEngle(GATEclipse)的数据(GATServer)。使用CyStasTabiWrreEngult(CygTrTrReTeIfFIONFO)的封装,对我来说非常重要,ScCytTwiteReTeIn信息(UsHOTHANDLE,PARAMSSEBLID[]值)具有参数“值”,并且我能够发送通知,一旦需要接收到我应该使用的字符(CygATTRAIDIN FIONFION),而CygTATRADIN对象我读不到什么价值?根据文档,此对象拥有读取属性值所需的信息,但是否是实际存储的值? 以上来自于百度翻译 以下为原文 Hi grsr, Thank you very much for your samples! It would be helpful if you can share what correct sequence should be done for reading data on CySmart dongle (GATT client) that was sent from PSoC BLE (GATT server). Encapsulation using CySmart API WriteCharacteristic (CyGattWriteInfo info) working for me great, since CyGattWriteInfo(ushort handle, params byte[] value) has parameter "value" and I able to send notifications, once I need to receive I should use ReadCharacteristic(CyGattReadInfo info), but CyGattReadInfo object has no value I can read? According to documentation this object holds the information necessary to read an attribute value, but were the value actually stored? |
|
|
|
asd013 发表于 2019-2-25 08:00 如果GATT服务器向GATT客户端通知数据,则不应使用RealDead(CygTrAtAdvIngIn)API。GATT客户应在CyGattClientCallback下收到回调“OnTimeCurchange”的通知。CysCurrimeCudioEngIn将封装通知数据的句柄值对。读取特性API应该用于读取已经写入GATT服务器的GATT数据库的数据。 以上来自于百度翻译 以下为原文 If the GATT Server is notifying data to GATT Client, then you should not use ReadCharacteristic(CyGattReadInfo info) API. The GATT client shall receive notification as a callback "OnCharacteristicChanged" under CyGattClientCallback. The class CyCharacteristicChangedInfo will encapsulate the Handle-Value pair of the notified data. The ReadCharacteristic API should be used to read data that is already written into the GATT database of the GATT Server. |
|
|
|
oiewjrj 发表于 2019-2-25 08:17 HigrSR 谢谢你的回答! 不幸的是,在我的情况下,“OnTimechange”回调不被激发,但是当我使用CysReas1.2应用程序时,我能够在0x010HANLE下对服务器的消息进行SEGATATE。什么是一个可能的原因? 以上来自于百度翻译 以下为原文 Hi grsr, Thanks for your answer! Unfortunately "OnCharacteristicChanged" callback is not fired in my case, but while I'm using CySmart 1.2 application I able to see GATT Server's message under 0x010 hanle. What can be a possible reason? |
|
|
|
asd013 发表于 2019-2-25 08:23 您需要在CyStaseC代码中启用CCDC来接收通知。如果您这样做,检查您是否已经输入了ccCD的正确属性句柄。打开CyScript 1.2并检查CCDC的属性句柄。它应该等于被通知的特性的属性句柄+ 1。在C代码中使用这个值。 以上来自于百度翻译 以下为原文 You need to enable CCCD in CySmart C# code to receive notifications. If you are doing so, check if you have entered the correct attribute handle of the CCCD. Open CySmart 1.2 and check the attribute handle of the CCCD. It should equal the attribute handle of the characteristic to be notified + 1. Use this value in the C# code. |
|
|
|
你好,
谢谢你的代码,这对我很有帮助。我试着自己做,但我面临着一个问题。 我想使用特性(CygTATRADIONFION)方法读取一个特性值,但是我不能读取它。 你能帮助我吗? 我用参数调用它:“CyGattReadInfo GattInfo =新CygAtTrAdTeNoFo(0x01e);”但是当我调用“Err= GATEclipse,RealDead(GattInfo)”时,它是VisualStudio的一个未知名称。为了读取这个数据,我做了回调,但是我的问题是要启动读操作。我想问题是从我宣布“ICyGattClient GattClient”的方式来的,但我不知道如何处理这个问题。 谢谢您。 最好的问候, 纪尧姆 以上来自于百度翻译 以下为原文 Hi grsr, Thank you about this code it's very helpful to me. I'm trying actually to make my own but I'm facing to a problem. I want to use the ReadCharacteristic(CyGattReadInfo info) method to read a characteristic value but I'm unable to read it. Can you help me ? I called it with the parameter : "CyGattReadInfo GattInfo = new CyGattReadInfo(0x001E);" but when I call "err = GattClient.ReadCharacteristic(GattInfo);" it's an unknow name for visual studio. To read this data I made the callback but my problem is about to launch the read operation. I guess the problem is coming from my way to declare "ICyGattClient GattClient;" but I don't see how to manage with this object. Thank you. Best regards, Guillaume |
|
|
|
oiewjrj 发表于 2019-2-25 08:40 你好,GRSR, 谢谢支持! 我在做以下步骤: 步骤1。重写NoTrimeClchange(CysCurrimeDead信息)并启用公共动作& CyStimeClutoDeField≫CharacteristicChangedHandler {GET;set;} GATCclitCB:CygTcliclitCalbBeCh 步骤2。一旦MyGATcliclitCB初始化,我将MyGATcliclitCB链接到CharacteristicChangedHandler(MyGATcliclitCB.FrimeCudieDead)=(信息)=& gt;而在这里,我使用的是数据GETPrimTablValue(Fiel.Value)) 步骤3。在main函数中,我创建了MyCygAtTrAdTeaNe=新的CygTrAtAdvInt(0x011);(从CyScript 1.2获取的0x011值),我可以看到0x010处理器上的更改(接收到的数据),根据前面的建议,它应该等于要通知的特性的属性句柄+ 1)。启用MyPeer-Stutial.gATCuth.Read Type(MyCygTrAtAdvIngIn); 步骤4。没有接收到通知,并且在这种情况下没有发生特征性更改的事件。 A我漏掉了什么东西吗? 请教。 以上来自于百度翻译 以下为原文 Hello GRSR, Thank you for support! I’m doing following sequence: Step 1. override void OnCharacteristicChanged(CyCharacteristicChangedInfo info) and enabling public Action under class GattClientCb : CyGattClientCallback Step 2. Once m_gattClientCb initialized, I’m linking m_gattClientCb to CharacteristicChangedHandler (m_gattClientCb.CharacteristicChangedHandler = (info) => while here I’m using data GetPrintableValue(info.Value)) Step 3. In main function I’m creating m_cyGattReadInfo = new CyGattReadInfo(0x0011); (0x0011 value taken from CySmart 1.2, I can see changes (received data) on 0x0010 handler, accourding to previous suggestion it should be equal to attribute handle of the characteristic to be notified + 1). And enabling m_peerDevice.GattClient.ReadCharacteristic(m_cyGattReadInfo); Step 4. No notification is received and no OnCharacteristicChanged event fired in this case. A’m I missing something? Please advice. |
|
|
|
你好,
我附上另一个简单的代码示例。这是一个简单的GUI,它可以显示、连接、写入、读取和接收通知。 您可以从这个链接下载项目: HTTPS://www. DROPBOX.COM/S/W5V7OJE0SSUZ2IX/MADY-40.ZIP?DL=0 此外,这里还附有测试项目的文件。 当做, - Madhu Sudhan MADY40.DOC 277.5 K 以上来自于百度翻译 以下为原文 Hi, I am attaching another simple code example. This is a simple GUI that demosntrates scanning, connection, Write, Read and receiving notification. You can download the project from this link: https://www.dropbox.com/s/w5v7oje0ssuz2ix/MADY-40.zip?dl=0 Also, document for testing the project is attached here. Regards, - Madhu Sudhan
|
|
|
|
只有小组成员才能发言,加入小组>>
754个成员聚集在这个小组
加入小组2106 浏览 1 评论
1853 浏览 1 评论
3671 浏览 1 评论
请问可以直接使用来自FX2LP固件的端点向主机FIFO写入数据吗?
1786 浏览 6 评论
1536 浏览 1 评论
CY8C4025LQI在程序中调用函数,通过示波器观察SCL引脚波形,无法将pin0.4(SCL)下拉是什么原因导致?
570浏览 2评论
CYUSB3065焊接到USB3.0 TYPE-B口的焊接触点就无法使用是什么原因导致的?
423浏览 2评论
CX3连接Camera修改分辨率之后,播放器无法播出camera的画面怎么解决?
437浏览 2评论
384浏览 2评论
使用stm32+cyw43438 wifi驱动whd,WHD驱动固件加载失败的原因?
915浏览 2评论
小黑屋| 手机版| Archiver| 德赢Vwin官网 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-24 07:23 , Processed in 1.126996 second(s), Total 102, Slave 86 queries .
Powered by 德赢Vwin官网 网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
德赢Vwin官网 观察
版权所有 © 湖南华秋数字科技有限公司
德赢Vwin官网 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号