arduino as bluetooth keyboard - no scancodes sent? - Galaxy Tab 10.1 Q&A, Help & Troubleshooting

I am trying to use an arduino with a bluetooth HID module (bluesmirf) 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 keytest 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.
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.

Related

mapping hardware buttons to switch on/off bluetooth

Does anyone know a way of mapping one of the h/w buttons to switch BT on and off. This would be espescially useful for when driving and using BT tools and wanting to switch on BT using a one handed action without looking at the screen.
One way I can see this happening is if I can get hold of the command that can be inputted using the run function provided by PHM powertoys (that can be mapped in the buttons section in the settings-> personal menu) that could toggle BT on and off in the same way as pressing the BT icon on the today screen that is installed with BT tools.
Any other ideas welcomed

[APP][24JUN2010]VolDpad: Use the volume buttons as a d-pad; New: Source code avail.

I have changed my Diamond bay a Touch HD and what I miss more is the d-pad.
I really need it because I read a lot on my device and it is necessary to turn pages, etc. So I searched for a solution.
I've using remaping keys programs for some days, but they are big and have some limitations so I've done my own program with a very simple behaviour:
-Volume UP is remaped to d-pad UP. Can be hold for autorepeat.
-Volume DOWN is remaped to d-pad DOWN. Can be hold for autorepeat.
-Double click Volume UP is remaped to d-pad LEFT. Does not support autorepeat.
-Double click Volume DOWN is remaped to d-pad RIGHT. Does not support autorepeat.
-Double click with hold in Volume UP is remaped to d-Pad RETURN with Hold.Does not support autorepeat.
-Double click with hold in Volume DOWN is remaped to d-Pad RETURN.Does not support autorepeat.
-If a call is being established or is active the volume keys will behave normally.
-Running the file a second time will close the resident with a small tone.
The program is small (7Kb) and remain resident without making use of CPU, it is simply a keyboard hook.
To install it copy the file werever you want and execute it. If you want it to start automatically after a Soft Reset make a link (DO NOT PUT THE FILE DIRECTLY) under \Windows\Startup or your locale equivalent.
REVISIONS
June 24, 2009: I've liberated the source code in order to allow other developers to improve the concept!!
August 28,2009:
-Soved the Back Arrow issue on HTC devices.
-Added support for unloading the program
-First try to add suport for Return-Hold (Context menus)
IMPORTANT
Some users are having issues with VolDpad on HD2 and Diamond 2. This one solves the issue:
http://forum.xda-developers.com/showpost.php?p=8062091&postcount=4
Hope it will be useful
If you like it and want to give me a buck please use this button:
Thanks to the following donators:
Johannes B., Federico, Mike P., Marie-Françoise H.,
DOWNLOADS
Download VolDpad from my site.
really nice app
but does it work in touch pro 2 ?
I've tested it only on a Diamond and on a Touch HD.
But the technology should be the same for the TP2
well this is brilliant! and it works great on my blackstone.
few suggestions:
- it would be a good idea to have command-line support so that you can turn it on and off easily by creating shortcuts or assigning hardware buttons to enable or disable it, or having a status check so that if it's on, next time you run it will turn it off and vice versa.
-it would be great to have both the "ok" button support and the "hold ok" button support so that you can load "right click" menus.. (you can have the upper vol button function as "ok" and lower vol button function as "hold ok")
wonderful work
it works perfectly on my HD!
Virtual button interrupt on HD?
hi all,
installed this on my HD and it works well, but i notice that when i try to use the virtual button to go <Back> (looks like a left arrow <-- ), now it goes up instead.
anyone else have this issue?
This is a fantastic app, will be useful specially for those who play games on their phone. One query; is there a way to remap the vol key buttons? For example can volume up key be mapped to left key, and volume down key mapped to right key. I say this because in Diamond and Touch Pro the Up and Down key on D-Pad functions normally, its only the left key and the right key that has a problem.
I just check - program works good on samsung i780. Is it possible to disable left/right/return function, but remain only up/down? Could you please add (in future version) any configuration file?
Best regards
Tomasz
lifeisaparody said:
hi all,
installed this on my HD and it works well, but i notice that when i try to use the virtual button to go <Back> (looks like a left arrow <-- ), now it goes up instead.
anyone else have this issue?
Click to expand...
Click to collapse
Same here on the Diamond 2, otherwise, fantastic stuff! If we can either get the Back Arrow button to act like the OK, or return it to its former glory, we are good to go!
Brillant, and I agree with the ML idea
fantastic. been looking for something like this for my touch hd
Awesome app! It works great with mobipocket. You can easily start/kill it with mortscripts (put links in the start menu, and you can do it with voice command). Edit the path as necessary.
kill("\Program Files\VolD-Pad\VolDpad.exe")
run("\Program Files\VolD-Pad\VolDpad.exe")
well done job
Nice work thx
vol buttons as a d-pad
Hi....anyone got it working for worms world party?? Kinda miss that game after changing from a kaiser to a blackstone....
thanks in advance.
Great App! Thanks!
Great stuff. I would add my vote to remove the left/right functionality and replace with 'OK' and 'context menu' support. I miss my Kaiser scroll wheel
It is difficult to do smething that will be perfect for all
I'll try to add support for exiting the program (easy) and for context menus (more difficult).
I also revise the issues with the back key.
EDIT: Done
One thing, What context menu can be reached with holding return? I wish to know for testing it
Thanks
Usefull app, I will get use to it.
Does not work for the TG01! After soft-reset it hijacks the bluetooth, switching it on and removing the BT link from the comm manager. It will not allow delete from any folder where it is copied! even the shortcut will not delete. (Had to manually disable the BT, then it auto deletes the shortcut, andyou can delete from a secondary folder. After soft-reset it will again delete from Primary folder, releasing control of the BT!)

USB Mouse Functionality

I have a logitech laptop USB mouse that works w/ the dock, except for the scroll wheel. Is there some kind of settings screen for the mouse once you plug it in? Do I have any chance of getting this working properly? I also can't seem to hold down the button and highlight text for cut/paste.
Thanks,
Brian
Scroll wheel works fine here with a Razer Orochi
You can't highlight text on holding button since Android doesn't support it, just hold mouse button (like longpress on the screen) steadily and you'll be able to select text
My scroll wheel kind of works in some apps. It is useless though as it skips one line at a time and doesn't always even do that. Is there a way to get to a mouse configuration or setup screen somehow?

[Q] Custom Bluetooth headset button actions?

Did a quick search and found nothing -- is there any application or way to customize the actions performed when the headset button is pressed?
I use Tasker for various automated things, but looks like there's nothing there (did I miss something?).
Specifically, this is the button on a bluetooth headset that would normally start the voice dialer -- I'd like it to do something different, perhaps. I know that the button's "command" can be intercepted by some applications, because I know that Vlingo, when installed, becomes an option of an application that would "handle" the bluetooth button press (i.e. when I press it, it pops up a window for "which application do you want to use for this").
Unfortunately, Vlingo just uses this to launch its own voice dialer...
Thoughts? If it matters, I'm using the Galaxy Nexus on ICS.
Thanks!
*bump*? ^_^
bump? Anyone? =/
I'm interested in knowing whether there's a solution for this as well, I'm wanting Jeannie/assistant called when I hit the call button on BT headset.
I know this is old but I'm look for a option to do this. Running a old stereo deck in my car but is bluetooth enabled and would love to have something trigger Google Now or Voice Dialer. Possibly by long pressing the play button or something.

[Q] Rotary keyboard app for Android?

Hello.
I am looking for a rotary keyboard application for Android, where A-Z0-9/Enter/Del keys would be drawn around a cirlce and I could choose them
moving the pointer around with UP/DOWN keys and confirm letter selection by the Enter key.
The reason for this is I am developing an Android based car system using IconBIT Toucan ARM9 mediaplayer. The device has everything (WiFi, GPS via PL2303/USB GPS Emulation) but no touchscreen. It can also be controlled by car stock keys using a HID USB PIC-controlled keyboard emulator. Cursor keys are "connected" to rotary encoder in the car, and Enter key is encoder press.
This is a sample of rotary phone number entry on Audi MMI, Audi has a similar keyboard for letters... Just to give an idea of what I'm looking for.
So, I would be grateful if someone could point me to a similar app for Android.
Thanks!

Categories

Resources