Wednesday, 21 August 2013

Samples and API: getting started

Several people have already received their samples. I've got more requests about samples, so I think about going for a short pick-and-place assembly run. Hand-soldering is OK for 1-2 prototypes, otherwise it just takes way too much time. Currently I'm waiting to get quotes.

Here's a simple "getting started" guide:

Device Manager (InputStickUtility):

To use InputStick you have to install DeviceManager app on your Android phone.

Installation:

Make sure that "allow installation of non-market applications" is checked in your devices settings.

Copy DeviceManager.apk to your device and install it.

Pairing with InputStick:

Plug InputStick into any USB port in order to power it up.

Run DeviceManager, if Bluetooth is disabled it will ask you to enable it.

By default it will be named "Dev-00" and set as "Home", however application will ask you if you want to edit this.

Settings:

Dialog settings:

Always ask: each time you will be asked to manually select InputStick device that you want to connect to. Use this if you want to be sure that no application will be able to connect to InputStick without you knowing.

Ask when more than 1 [Default]: you will be asked to select device only when more than one InputStick is paired with your phone. Otherwise it will connect automatically.

Never ask: you won't be bothered with dialog. If there is more than one device paired, it will attempt to connect to the one marked as "Default device".

Toast settings:

Show all - show all toasts, useful mainly in my case.

Show important - show only important toasts, useful for application developers.

Enabled - notification will be displayed when InputStick device is in use.

Disabled - no notifications will be displayed.

Demo apps:

Use Connect/Disconnect button, exact behaviour depends on configuration of DeviceManager. If it is the first time that you are using your InputStick device you will be asked to enter PIN code (1234), unless you have already paired it manually.

BUG: if attempt to establish Bluetooth connection fails (InputStick not plugged in, out of range etc), pressing "Connect" again will do nothing. You have to kill the app and try again. Next API release will solve this issue.

Depending on USB host, OS, and settings it may take some time to detect new hardware and install drivers. During this period you won't be able to
use application, even though it may appear to be ready. Next time, this should be much faster (OS will recognize the device using PID/VID pair).