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

is multi touch HID possible with nrf51822 chip?

Hi All,

       Currently i am working on nrf51822 for multi touch HID.For that i have chosen mouse HID example as a reference, in which i have changed HID descriptor(single touch) and some other things.So, that single touch has been working.

And, if i changed the HID descriptor for multi touch, touch devices(touch laptop) were showing "Bluetooth driver error".

is it possible multi touch HID over nrf51822 as a reference of mouse HID example?

if possible, what all changes are to be required to work for multi touch.

so, please guide me how to implement multi touch HID over nrf51822.

regards

akash.

Parents
  • Hi Akash

    Multi touch should definitely be possible with the nRF51 series. 

    Microsoft have some good articles on how to use multi touch with windows, such as this one. Have you had a look at that?

    If you still can't make it work, are you able to attach your HID descriptor so I can have a look at it?

    Best regards
    Torbjørn

  • Thanks for your precious reply.

    yes, i have gone through windows multi touch HID, but didn't work for me.

    so, i have taken one more multi touch HID, which has been working over USB.

    if i emulated same HID into Bluetooth stack, it was not working.

    here, i am attaching my HID

    0x05, 0x0D, // Usage Page (Digitizer)
    0x09, 0x04, // Usage (Touch Screen)
    0xA1, 0x01, // Collection (Application)
    0x09, 0x22, // Usage (Finger)
    0xA1, 0x02, // Collection (Logical)
    0x09, 0x42, // Usage (Tip Switch)
    0x15, 0x00, // Logical Minimum (0)
    0x25, 0x01, // Logical Maximum (1)
    0x75, 0x01, // Report Size (1)
    0x95, 0x01, // Report Count (1)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0x09, 0x30, // Usage (Tip Pressure)
    0x25, 0x7F, // Logical Maximum (127)
    0x75, 0x07, // Report Size (7)
    0x95, 0x01, // Report Count (1)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0x09, 0x51, // Usage (0x51)
    0x26, 0xFF, 0x00, // Logical Maximum (255)
    0x75, 0x08, // Report Size (8)
    0x95, 0x01, // Report Count (1)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
    0x09, 0x30, // Usage (X)
    0x09, 0x31, // Usage (Y)
    0x26, 0xFF, 0x7F, // Logical Maximum (32767)
    0x65, 0x00, // Unit (None)
    0x75, 0x10, // Report Size (16)
    0x95, 0x02, // Report Count (2)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0xC0, // End Collection
    0x05, 0x0D, // Usage Page (Digitizer)
    0x27, 0xFF, 0xFF, 0x00, 0x00, // Logical Maximum (65534)
    0x75, 0x10, // Report Size (16)
    0x95, 0x01, // Report Count (1)
    0x09, 0x56, // Usage (0x56)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0x09, 0x54, // Usage (0x54)
    0x25, 0x05, // Logical Maximum (12)
    0x75, 0x08, // Report Size (8)
    0x95, 0x01, // Report Count (1)
    0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
    0x05, 0x0D, // Usage Page (Digitizer)
    0x09, 0x55, // Usage (0x55)
    0x25, 0x0A, // Logical Maximum (12)
    0x75, 0x08, // Report Size (8)
    0x95, 0x01, // Report Count (1)
    0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile)
    0xC0, // End Collection

    is there any changes are to be required in code(like feature report, input report,output report)?

    because, single touch has been working without adding any feature reports and output reports.

    regards,

    akash.

  • Hi

    Sorry for late reply.

    I have been busy with another task. If i got time to test, will test and let you know.

    Thanks for your whole support.

    BR

    Akash.

  • Hi

    No worries, take all the time you need Slight smile

    Best regards
    Torbjørn

  • Hi

    Just now I have tested with Moto g5 plus phone,it has been working as expected.

    Tomorrow I will test on windows, and will let you know the result.

    Heartly appreciate your support.

    BR

    Akash.

  • Hi Ovrebekk,

    I'm working on a similar solution where I need the capability to reproduce a up/down/left/right finger swipe on an iPhone that performs a scroll effect.  I'm working with the nrf52832 DK and when I try to compile I get the following error. Do you have any advice?

    Thanks...

    Building ?ble_app_hids_mouse_pca10040_s132? from solution ?ble_app_hids_mouse_pca10040_s132? in configuration ?Debug?
    1> Compiling ?fds.c?
    2> Compiling ?hardfault_implementation.c?
    3> Compiling ?nrf_assert.c?
    1> In file included from /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:43:
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds_internal_defs.h:93:39: error: 'FDS_VIRTUAL_PAGES_RESERVED' undeclared (first use in this function); did you mean 'FDS_VIRTUAL_PAGE_SIZE'?
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:1645:24: note: in expansion of macro 'FDS_PHY_PAGES_RESERVED'
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds_internal_defs.h:93:39: note: each undeclared identifier is reported only once for each function it appears in
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:1645:24: note: in expansion of macro 'FDS_PHY_PAGES_RESERVED'
    4> Compiling ?nrf_atfifo.c?
    Build failed
Reply
  • Hi Ovrebekk,

    I'm working on a similar solution where I need the capability to reproduce a up/down/left/right finger swipe on an iPhone that performs a scroll effect.  I'm working with the nrf52832 DK and when I try to compile I get the following error. Do you have any advice?

    Thanks...

    Building ?ble_app_hids_mouse_pca10040_s132? from solution ?ble_app_hids_mouse_pca10040_s132? in configuration ?Debug?
    1> Compiling ?fds.c?
    2> Compiling ?hardfault_implementation.c?
    3> Compiling ?nrf_assert.c?
    1> In file included from /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:43:
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds_internal_defs.h:93:39: error: 'FDS_VIRTUAL_PAGES_RESERVED' undeclared (first use in this function); did you mean 'FDS_VIRTUAL_PAGE_SIZE'?
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:1645:24: note: in expansion of macro 'FDS_PHY_PAGES_RESERVED'
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds_internal_defs.h:93:39: note: each undeclared identifier is reported only once for each function it appears in
    1> /Users/matt/Documents/Nordic/nRF5_SDK_15.3.0_59ac345/components/libraries/fds/fds.c:1645:24: note: in expansion of macro 'FDS_PHY_PAGES_RESERVED'
    4> Compiling ?nrf_atfifo.c?
    Build failed
Children
  • I was finally able to get it to compile by using the SDK 15.2.  What was the goal of the DZ213974_ble_app_hids_mouse project.  What type of functionality should I expect for each button?  I have been testing with my Mac and get some response but get nothing on my iPhone XS.  

    Would this project set me on the path of reproducing a finger swipe across an iPhone?  I'm trying to reproduce a up/down/left/right finger swipe on the iPhone for scrolling.  I have had my customers ask about adding this feature to a product I sell.  I purchased a cheap remote from China that has the exact functionality I'm looking for.  Been trying to figure out how it's working with the phone.  I have the packet logs from logging the traffic but not making any progress with them because never had to go that deep into the protocol.  

    Thanks for any advice you may have.

  • Hi Matthew

    I am not sure how much help this project would be. Essentially I designed it to debug multi touch functionality. I tested it with an Android app called Multi Touch Test, and when pressing Button 4 on the kit repeatedly you should eventually see multiple points on the screen touched at the same time. 

    I never got it working quite as I expected, so it is not really a project I would recommend for other use cases. It does not try to replicate swipe either, this would probably require a different descriptor. 

    Best regards
    Torbjørn

Related