Phidgets On the Android OS

Supporting 4.1 and up
RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Phidgets On the Android OS

Postby RobOrt » Tue Jun 21, 2011 4:43 am

I've been working on porting the Phidgets drivers to the Android platform and am now close to releasing a BETA version of my first app. In the meantime however I've created a short YouTube video which can be viewed here:

http://youtu.be/QNEQNHQ1sU8

The app featured will shortly be FREELY available from the Android Market so anyone with an 8/8/8 Interface Kit can try it out.

At the moment I have an app for the interface kit only but can provide native Android drivers for the majority of the Phidget range. This enables apps to be developed with the standard, FREE Java Android tools.

Please note, these drivers use the WebPhidgets service. USB is not currently supported in Android.

If you'd like some specific development work I'd be interested in hearing from you.

I'll also be creating a paid version if this app but it will be considerably more feature rich than the free Beta release

RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Re: Phidgets On the Android OS

Postby RobOrt » Fri Jun 24, 2011 3:50 am

The first beta release of my Android app has been released and you can point your browser to:
https://market.android.com/details?id=uk.co.androidcontrols.androidphidgets

From Android Market just search for 'Phidget' and the application 'Android Phidgets' will be returned (developer is Android Controls).

Some points to note about using the app:
  • It does not currently detect if you have wireless or data connection enabled it will simply fail silently. Therefore you must ensure you have a wireless connection of one sort or another.
  • You will need to change the default IP address to the IP of your webphidget/InterfaceKit (see instructions below). Note the app will retain 2 IPs; one for a local connection and the second when using an internet connection.
  • To exit the app please press the 'HOME' key otherwise the app may just reconnect and it appears you're stuck in loop!. This is a known issue and will be resolved in the next update.
When the app starts you will be presented with a screen displaying text messages such as library version etc and the app will automatically attempt to connect to the default IP. Altering the settings for your own specific installation is as follows:

The MENU button will bring up 3 options:
  • Reconn.
  • Network
  • Conns

Beginning with the last option:

Conns: This is where you enter your target IP.The first dialog will ask whether you wish to alter a local or Internet IP. Essentially there is no difference between the two but a way of saving and distinguishing between 2 IPs for your installation. (One for when you are local to it and using say a wireless connection and the second for when using a mobile data connection)
Network: This tells the app which of the two IPs set above it is to use. NOTE: Even though you select which IP to use you MUST the app will not automatically reconnect to it. You must direct it to use it with the third MENU option:
Reconn.Tells the app to reconnect to the IP selection set in the 'Network' Menu.

Please note that you may need to alter firewall settings if you are connecting via a mobile data connection.

I hope to add some YouTube videos soon to show how the controls work.

RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Re: Phidgets On the Android OS

Postby RobOrt » Fri Jun 24, 2011 8:05 am

You can now follow me on Twitter:

@AndroidControlz

I'll be tweeting development, upcoming releases, news etc there.

ClosetGeek
Phidgetsian
Posts: 11
Joined: Sun Jun 12, 2011 11:19 am
Contact:

Re: Phidgets On the Android OS

Postby ClosetGeek » Sat Jun 25, 2011 10:29 am

Hi,

Thanks for the info. Will certainly check out the app later.

Am new to Phidgets and Java, so still going through a bit of a learning curve.

Am also a very keen Android user, with some success in producing my own apps. Nothing on the Market Place though.

Would love to see a Phidget release on Android. Would be pretty cool to have an Android app to control my Scalextric timing system I'm currently building.

Regards,
Paul

RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Re: Phidgets On the Android OS

Postby RobOrt » Sun Jun 26, 2011 3:30 am

ClosetGeek wrote:Hi,

Thanks for the info. Will certainly check out the app later.

Am new to Phidgets and Java, so still going through a bit of a learning curve.

Am also a very keen Android user, with some success in producing my own apps. Nothing on the Market Place though.

Would love to see a Phidget release on Android. Would be pretty cool to have an Android app to control my Scalextric timing system I'm currently building.

Regards,
Paul


Hi Paul,

Thanks for your post. I like the Android platform a lot and Java is pretty easy to pick up too especially as all the development tools are free! I use Linux for everything now (Vista pushed me to it and from there I learnt C/C++, Java, PHP etc).

What Phidget devices do you use?

pmazzarol

Re: Phidgets On the Android OS

Postby pmazzarol » Thu Jul 07, 2011 5:03 am

Hi All, I'm very interested in the possible support of phidgets on Android. My question with the current approach is whether an intermediary device is needed for an android device to talk directly with a phidgets board? My Motrolla Xoom runs Android 3.1 and can talk to many devices via USB using OpenAccessory() OTG. I don't really want to toss all my nice phidgets and start soldering with the IOIO board thoug

Just get it going guys... my robot's brain needs a body it can control! 8)

RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Re: Phidgets On the Android OS

Postby RobOrt » Thu Jul 07, 2011 6:47 am

pmazzarol wrote:Hi All, I'm very interested in the possible support of phidgets on Android. My question with the current approach is whether an intermediary device is needed for an android device to talk directly with a phidgets board? My Motrolla Xoom runs Android 3.1 and can talk to many devices via USB using OpenAccessory() OTG. I don't really want to toss all my nice phidgets and start soldering with the IOIO board thoug

Just get it going guys... my robot's brain needs a body it can control! 8)


Hello pmazzarol,

The quick answer is, based on my understanding of your project, yes you need an intermediary device.

Currently USB support is only available from Android 3.0 (Possibly 3.1 onwards) and when I say 'support' I mean any type of USB support. However I do believe (not 100% sure of this) that Android £3.0+ does NOT use the udev package which manages USB devices. I understand Phidgets require this (as well as some other libraries which I don't think are available on Android.) so as far as allowing DIRECT connection of a phidget device to an Android tablet, that is not yet possible.

However this is where my libraries come in and there is a solution to controlling your robot.

Firstly, I would consider the strengths of Android devices/tablets. They are mobile and can be used without any wires attached (provided battery power is sufficient) so for me, as soon as I attach a physical wire to it i.e. a Phidget, I've immediately lost the mobility of the device and I may have well just bought a cheap computer to do the same job. Far better is to retain the mobility of the Android device and wirelessly link it to a central intermediary device to which you connect your Phidget devices.

Obviously this will mean extra expense, but if you consider one of Phidget's SBCs, you can have this device fitted to your robot with all your Phidgets connected to it. Then on the SBC you will have the (pre-installed) Phidget webservice which would allow wireless connection to your Android device. You can then used your 'droid anywhere you want whilst retaining control of your robot.

It's extra expense and I currently only have a (free) app for the Interface 8/8/8 Kit out on android Market. Unfortunately I have a day job to attend to which restricts the time I can devote to this.

User avatar
Patrick
Lead Developer
Posts: 3098
Joined: Mon Jun 20, 2005 8:46 am
Location: Canada
Contact:

Re: Phidgets On the Android OS

Postby Patrick » Thu Jul 07, 2011 10:05 am

When Phidgets officially releases an Android library, it will most likely support direct connection of Phidgets to Android devices that bring out USB Host.

However, we have not started work on this yet and don't even have an Android device to develop on yet.

Can anyone recommend a good Android development machine that runs 3.0+ and has USB host (preferably something with a netbook/laptop form factor, and preferably with fully powered USB ports)?

-Patrick

RobOrt
Phidgeteer!
Posts: 85
Joined: Wed Jun 17, 2009 11:39 am
Contact:

Re: Phidgets On the Android OS

Postby RobOrt » Fri Jul 08, 2011 2:20 am

Patrick wrote:When Phidgets officially releases an Android library, it will most likely support direct connection of Phidgets to Android devices that bring out USB Host.

However, we have not started work on this yet and don't even have an Android device to develop on yet.

Can anyone recommend a good Android development machine that runs 3.0+ and has USB host (preferably something with a netbook/laptop form factor, and preferably with fully powered USB ports)?

-Patrick


Hello Patrick,

I can't recommend a 3.0+ device as I use a 2.2 for my own work however I can make some comments about Android & USB that you might find helpful.

Firstly 3.0+ is aimed at tablet devices and as far as I know these are the only type of 3.0+ devices you can get i.e. no mobile phones. (the Motorola XOOM seems to be popular but not sure what it would be like for development work.)

As you're probably aware USB support is only slowly being introduced into Android. You might find this Google IO video helpful if you have 45 mins to spare :
http://developer.android.com/videos/index.html#v=s7szcpXf2rE

User avatar
Patrick
Lead Developer
Posts: 3098
Joined: Mon Jun 20, 2005 8:46 am
Location: Canada
Contact:

Re: Phidgets On the Android OS

Postby Patrick » Fri Jul 08, 2011 9:05 am

I don't know a lot about Android, but it's true that without udev and/or usbfs it could be difficult to get USB working. I imagine they don't want us writing kernel drivers.

-Patrick


Return to “Android”

Who is online

Users browsing this forum: No registered users and 1 guest