-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Want to control Smart TV with NimBLE used in esp-matter code (CON-1576) #1304
Comments
Are you wanting to use BLE after Matter commissioning? If yes, you should disable |
Thankyou for your reply, yes i want to use BLE after commissioning, I have already disabled CONFIG_USE_BLE_ONLY_FOR_COMMISSIONING. can you clarify what do you mean by External Platforms? I am unable to understand this. |
We will initialize BLE stack and advertise Matter-over-BLE services and handle Matter data in our platform codes https://github.com/project-chip/connectedhomeip/tree/master/src/platform/ESP32/nimble, but you are use BLE with HID profile to control Smart TV, so you must modify the BLE platform codes to support both Matter commissioning and HID Profile. And the external platform is the solution we provide to override the original platform codes. you can refer to https://docs.espressif.com/projects/esp-matter/en/latest/esp32/developing.html?#advanced-setup about how to use it. |
Sorry, But we don't want to use this way. I am sharing my sample code, please go through it and give me some suggestions. I am able to turn on BLE and it is visible in TV also but i am not able to connect it. Can you please help me to connect and control the TV using this way? and also please reply to this question: |
I cannot provide another way to enable HID with Matter. We have a example light_wifi_prov which will maintain two BLE advertisements and two BLE services. Seems it has met your requirements to add another BLE advertisement and service.
After looking through your sample code, I find you didn't add the access_cb for the characteristics in your services. And since we already called ble_gatts_add_svcs() in Matter platform code. I am not sure it is OK to call it again to overwrite the BLE service.
Normally we will add new BLE service and advertisement by modifying the platform code, and we haven't test to change the existing Matter BLE advertisement&service in example code. There is a state machine which maintains the Matter BLE service and the state machine might break the custom service you add. As for whether it will break Matter laws or Matter certification, I am not sure with your method. I can only ensure our example which enables two advs and services will not break the Matter laws or Matter certification. |
Hi @wqx6, -Thank you for your valuable Reply. -This are the LOG' s can you please help us to solve the problem: |
Did you check the service after connecting the BLE with nrfconnect app? Could you find the gatt service with the right UUID that you added? Normally there should be access_cb for the characteristics so that the device can handle the message sent by the peer(the TV in your scenario) and send the message to the peer in the access_cb. Did you add the logic in your access_cb? This might be the reason of BLE disconnection. |
The questions seem to be specific to BLE. Can you please close this issue and ask the specifics on ESP IDF Github instead? |
The reason is that we have already called |
Hi @wqx6, As you said that we need to use external platform feature to add our custom BLE services, I have not any kind of idea related to this feature can you guide me how can i use this feature and add my custom service t BLE. I have tried https://docs.espressif.com/projects/esp-matter/en/latest/esp32/developing.html?#advanced-setup, but not able to understand what to do with this, if you have any references related to this or if anyone have added custom service using this feature there reference, any patch or something you can provide would be very helpful for us. |
You can refer to the example light_wifi_prov about how to add custom GATT services with external platform, or you can apply the patch project-chip/connectedhomeip#38067 which adds an API to add the custom GATT services. |
Hi,
I am using esp-matter light example, for my development. I know matter uses Nimble stack, because it uses ble only for commissioning. But in my case i want to use ble for other purpose, like to control Smart TV's using HID Profile after commissioning and I got stuck at this point.
I have tried many different examples from esp-idf (Bluedroid and Nimble) and suggestions from esp-matter issues, but i am unable to solve this problem.
please Help me step by step to achieve this, and also let me know that if i'll do this kind of customisation will it break any matter law's or may issue while matter certification.
Or If you have any alternate way please suggest me, so i can continue with my development.
The text was updated successfully, but these errors were encountered: