I am trying to use an arduino with a bluetooth HID module (bluesmirf HID) to control the volume on my Galaxy tab. I have the arduino setup so that i push a small button that is wired in, and it sends ascii text to the tablet just like a keyboard would, and this works fine. I wanted to create a custom keyboard layout file for this “bluetooth keyboard” so that when the tablet receives a keypress from the arduino over bluetooth, it would control the appropriate item, like the volume, mute, etc. However, when using the keytest app to capture the incoming button press from the bluetooth module, the scancode is always 0. Keytest is reading the key right and shows it as keycode_a (for example) when an A is sent, but the scancode for that key is always 0 instead of a unique identifier. Oddly enough, the carriage return that the arduino automatically puts at the end of the serial.println command (command that I am using to send the button presses over bluetooth) shows up correctly as ENTER and DOES have a scancode.
I dont get it. I must be doing something wrong but I am still new/learning so I must be missing it. I cant setup a custom keyboard layout to do what I want without having a scancode coming in for the tablet to see. Is there some way to force scancodes to be sent? I read through the bluesmirf HID rn-42 docs and its a lot to try to absorb/figure out.
I can post my arduino code if necessary. Any and all help is greatly appreciated. I am so close to accomplishing what I need and its driving me insane.