This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Help needed understanding the steps in setting up a bluetooth mouse using nRF52840

I have managed to get working a BMW iDrive to act as a bluetooth mouse for my iPhone. To do this I used a CANBUS shield connected to an arduino NANO and an nRF51 BLE connected to another NANO and joined the two NANOs using the .Wire interfaces.

I wanted to shrink it down so I am trying to use a Nano 33 BLE which is an NRF52840. I have to use a different BLE library and it is not clear to me how this is done. If I declare a service with code "1812" the iPhone connects and sees it as a bluetooth mouse but has no buttons and I can't see a pointer appear. If I look at the code  from the previous working prototype, it does everything using sendCommand with AT+ codes, and I can't find a way of doing that. 

Can anyone point me in the right direct, I have searched the web extensively for instructions on how to define and setup a HID device but I can't find what I need.

Thanks in advance,

Derek

Parents
  • Hi,

    I do not believe iOS support mouse pointers, never seen it at least.. You can use keyboard though.

    Kenneth

  • Hi,

    Thanks for your comments. The answer is yes, as of iOS 13, the iPhone now supports a mouse. It's a bit hard to find but go into settings---Accessability---Touch---AssistiveTouch---Devices---Bluetooth Devices and you're there.

    I tested it first with an HP bluetooth mouse and it worked fine so I then did it using an Arduino NANO connected to a bluetooth dongle nRF51. This used a BLE library that allowed me to write AT+Commands to the ble module and that also worked perfectly. In fact, by using the extra commands I could even do things that the mouse wasn't capable of including mute the volume etc. However, the new NANO 33 BLE that is based around a nRF52840 chip uses a different ble library and that won't allow me to write AT+Commands. So I have to build up the service and I can get as far as the iPhone seeing the device but cannot cause any actions.

    Thanks again

Reply
  • Hi,

    Thanks for your comments. The answer is yes, as of iOS 13, the iPhone now supports a mouse. It's a bit hard to find but go into settings---Accessability---Touch---AssistiveTouch---Devices---Bluetooth Devices and you're there.

    I tested it first with an HP bluetooth mouse and it worked fine so I then did it using an Arduino NANO connected to a bluetooth dongle nRF51. This used a BLE library that allowed me to write AT+Commands to the ble module and that also worked perfectly. In fact, by using the extra commands I could even do things that the mouse wasn't capable of including mute the volume etc. However, the new NANO 33 BLE that is based around a nRF52840 chip uses a different ble library and that won't allow me to write AT+Commands. So I have to build up the service and I can get as far as the iPhone seeing the device but cannot cause any actions.

    Thanks again

Children