Please login or register.

Login with username, password and session length
Pages: [1] 2 3

Author Topic: Developing for Android  (Read 29407 times)

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Developing for Android
« on: September 08, 2011, 03:29:04 PM »

For those who want to program for Android but don't want to deal with Java, etc. Here is a 50% discount code for Basic4Android. You need to use the Plimus link for the $99 Enterprise version to enter the code. The result is $49.50 plus any applicable tax. It should be good for about 15-16 more redemptions.

Code: baukyj
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

Knightrider

  • Community Organizer
  • Hero Member
  • ***
  • Helpful Post Rating: 62
  • Posts: 1748
  • I love my WM100!
    • This Automated House
Re: Developing for Android
« Reply #1 on: September 08, 2011, 06:12:21 PM »

+1 for your generosity.
Logged
Remote control is cool,

but automation rules!

Tuicemen

  • Administrator
  • Hero Member
  • ****
  • Helpful Post Rating: 283
  • Posts: 10506
  • I don't work for X10, I use it successfuly!
Re: Developing for Android
« Reply #2 on: September 08, 2011, 08:22:57 PM »

Logged
Please Read Topic:
General Forum Etiquette
Before you post!

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #3 on: September 08, 2011, 09:01:47 PM »

Awww shucks, fellas.  :-[

Actually, I get an extra year of free updates for each code use - although I already had the 4 max before I posted here. Eveyone who buys gets their own discount code to pass on and the extra year of updates for the first four code users. It's a good marketing ploy and somewhat targeted as I posted it here and to a couple of embedded Basic forums after first giving it to a few friends who I knew likely to use it.
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

YB

  • Hero Member
  • *****
  • Helpful Post Rating: 3
  • Posts: 173
  • Coders Are The Only True Evils In This World...
    • X10 WTI
Re: Developing for Android
« Reply #4 on: September 09, 2011, 01:30:48 PM »

speaking of developing for android. As a developer, i read a lot of tuts and how to's, and is interested in how others code. given that, I found something great the other day, and your post makes me want to share it.

If you want to learn how to develop for android for real, from start to know what your doing enough to read some more advanced stuff, you can watch this guy teach you on youtube.

http://www.youtube.com/watch?v=SUOWNXGRc6g&feature=BFa&list=PL34F010EEF9D45FB8&lf=plpp

he is really awesome and really good, he has some quirks about himself (like repeating the same phrases over and over), but the way he explains stuff will get you programming in no time flat.
Logged
Michael Youngblood
Web Designer

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #5 on: September 09, 2011, 03:30:56 PM »

If you want to learn how to develop for android for real...

Well, I've been developing for real since Fortran and IBM punch card days. Currently, I develop for Windows, Linux and OSX as well as for PIC and AVR microcontrollers. The AirPad is the first tablet I have any interest in developing for and until you insulted me was planning some X-10 related Home Automation applications.  ;) Also, I consider Larry Elllison to be the biggest a**h*le in the known universe and want nothing to do with anything he has his fingers in. I've never allowed any form of Java on any of my networked machines. That's why I suggested an alternative. Plus, Basic is much more accessible to first-time or relatively inexperienced programmers who might want to buy an AirPad try their hand at their own applications.
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

YB

  • Hero Member
  • *****
  • Helpful Post Rating: 3
  • Posts: 173
  • Coders Are The Only True Evils In This World...
    • X10 WTI
Re: Developing for Android
« Reply #6 on: September 09, 2011, 06:53:58 PM »

I'm sorry for the confusion, I wasn't saying your not a real developer. I was simply sharing a set of videos with anyone interested in developing for the Android platform using the Google/Android recommended methods. Yea, there are other ways to develop for the platform, but your not going to have access to the platforms full potential if your not using the Android SDK and writing in Java.
Logged
Michael Youngblood
Web Designer

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #7 on: September 09, 2011, 07:58:50 PM »

your (sic) not going to have access to the platforms full potential if your not using the Android SDK and writing in Java.

As I understand it, Android is open source so there is no inherent reason why other development languages cannot access all of its features. I guess it depends on the skill of the developers of Basic4Android. Real developers might compile to machine code, as several Basic compilers do, although B4A appears to make use of the Java JDK and Android SDK (I may have to rethink using it ::)). Basic4Android even accesses GPS - oh, I guess it cannot do that on the AirPad. Maybe I should consider that other, cheaper Android tablet - it does have AGPS and can probably do everything I want to do in an X-10 related Home Automation application. rofl

« Last Edit: September 09, 2011, 08:38:19 PM by dhouston »
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

HA Dave

  • Hero Member
  • *****
  • Helpful Post Rating: 175
  • Posts: 7127
Re: Developing for Android
« Reply #8 on: September 09, 2011, 10:24:01 PM »

I can't believe X10 hasn't developed touchscreen software for the AirPad. Touchscreen automation has been the dream of the future for some time. A wall mount and/or stand-up docking station, along with the software is all that needed. We could use WiFi to interface with our HA PC to control our homes.

OR..... If this thing could be made to control a CM15A... the electric saving of not running a desktop (HA PC)... would save the cost of the AirPad in no time.
Logged
Home Automation is an always changing technology

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #9 on: September 09, 2011, 11:09:09 PM »

Touchscreen automation has been the dream of the future for some time. A wall mount and/or stand-up docking station, along with the software is all that needed.

Actually, there have been 7", 9" & larger wall mounted (and dockable) SBC PC touchscreens (single touch, resistive), running Windows CE,  with wired ethernet connections available for a few years. The cost was a bit too high to use for HA in general although you might have found a limited market among some of the high-end hardwired and RF systems (e.g. Crestron, who I believe offers one). The names escape me at the moment. I looked at a couple seriously but, in the end, decided they were just too costly ($600 and up) for the typical X-10 user. The volume created by Apple and Android tablets have brought prices down and added features. The AirPad would seem a natural for HA and it's a shame they didn't include an IR emitter which would allow for control of A/V gear, as well. If I were a real developer, I might take a crack at it. ;)

 -:) Hmmm, my poor, ancient, addled brain vaguely recalls sending 38kHz bursts out of the headphone jack on an early PDA using an IR LED mounted to a 1/8" stereo plug. I'll have to do a bit of digging but suspect my records went bye-bye with a NAS crash a few years back. I wonder whether the AirPad audio circuits might be capable of 38kHz and whether there's a way to time the bursts.

Ahhh, I recall that I created .WAV files of the patterns needed, eliminating the need for any timing, with L & R 180° out of phase, connecting L to cathode and R to anode - on a 3V device that gave 6V across the emitter and there was just enough current to work across the average room. With the 16/32GB of available storage using the SD slot or the Lenovo, this will work if the hardware can generate the higher frequencies (which is likely). I already have code to convert several formats to/from .WAV.  Also, most IR receivers have about ±5-6kHz bandwidth so we may be able to cheat a bit if the hardware cannot do 38kHz.

I think I'll opt for the Lenovo with GPS and 16GB. Maybe they'll be more welcoming to an unreal developer.  ::)
« Last Edit: September 10, 2011, 11:18:56 AM by dhouston »
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

HA Dave

  • Hero Member
  • *****
  • Helpful Post Rating: 175
  • Posts: 7127
Re: Developing for Android
« Reply #10 on: September 10, 2011, 07:33:12 PM »

.......... it's a shame they didn't include an IR emitter which would allow for control of A/V gear, as well.

You know.... instead of an IR emitter... a mini USB RF transmitter would be the ticket. One that would send and receive X10 RF signals (as well as security channel signals) and the RF freqency that is used with the PowerMid IR device. So the PowerMid could be placed.... where it could receive the proper RF signal and in turn control the IR devices.

That way the tablet/AirPad device (with the proper software) could interface with a CM15A using RF. And/Or with camera views using a HA PC and Wifi. Plus the tablet could be used to set or disarm the security console. And the same Pad could control IR devices all over the house and without ever needing to "point" the tablet at anything.

Then we could have [little more than] $200 touchscreens... that could also come pretty close to filling in for a HA PC. The other ones have always been a bit too complex and pricey for me.
« Last Edit: September 10, 2011, 07:36:56 PM by HA Dave »
Logged
Home Automation is an always changing technology

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #11 on: September 10, 2011, 07:50:03 PM »

a mini USB RF transmitter would be the ticket.
That would have to come from X-10 as the cost of FCC required testing is prohibitive ($5K and up).

However, most inexpensive RF transmitter modules will not switch fast enough to respond to the IR carrier. In effect, they act like an envelope detector so you could send 418MHz with the IR output via the headphone jack  assuming there would be enough current to drive the transmitter (borderline, I think). 418MHz transmitter modules are readily available. 310MHz (for sending to X-10 HA transceivers) are not.
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

HA Dave

  • Hero Member
  • *****
  • Helpful Post Rating: 175
  • Posts: 7127
Re: Developing for Android
« Reply #12 on: September 10, 2011, 08:06:22 PM »

I control IR devices using BVC software, and a USB-UIRT. I then use the PowerMid(s) to send the IR signals to my living spaces from the HA PC. Here's a video of that.
Logged
Home Automation is an always changing technology

dhouston

  • Advanced Member
  • Hero Member
  • ******
  • Helpful Post Rating: 37
  • Posts: 2547
    • davehouston.org
Re: Developing for Android
« Reply #13 on: September 10, 2011, 08:22:26 PM »

I controlled X-10 and IR devices with devices of my own design (costing ~ $75 total) some 10-12 years ago. Later, I even had a touchscreen, adding an RF transmitter to a Philips Pronto Touchscreen Universal IR Remote Control. IIRC, a refurb Pronto cost me about $100 and the RF transmitter another $5. But it couldn't browse the web, had no GPS and didn't serve as a phone. 
 
Logged
This message was composed entirely from recycled letters of the alphabet using only renewable, caffeinated energy sources.
No twees, wabbits, chimps or whales died in the process.
https://www.laser.com/dhouston

helihead

  • Newbie
  • Helpful Post Rating: 0
  • Posts: 4
Re: Developing for Android
« Reply #14 on: September 11, 2011, 12:06:05 PM »


Just wanted to second the recommendation for Basic4Android.  I missed the punch card days but I caught up with you at Fortran and sounds like we have pretty common background with the micros and such.  Anyway, I traditionally do more C these days but have lots of java experience as well and was using the normal android dev environment for a while.  It worked OK but I was poking around with the free version of B4A and tried to download something from the forums.  It wouldn't let me have it since I hadn't bought the thing yet but it threw a discount offer up and I ended up buying the full version for $49.

It's actually very nice and most importantly to me, very solid.  Usually, well into a project with a new IDE, language or whatever, the compiler starts freaking or the gui designer starts fighting you and you know you just did a bunch of work and got a headache.  B4A so far is rock solid and I have never had any issues.  The app I am writing right now has 23 screens and about a dozen tables using sqlite, GPS and pretty much all the sensors, etc and it works flawlessly.  It does throw java type exceptions when you bomb something but the debugging is awesome and lets you step through your code in the emulator or connected phone/tablet.

Anyway, just change the screen res to Landscape 800x480x1 (160dpi) or Portrait 480x800x1 (160dpi) and you're ready to code for the Airpad.

Logged
Pages: [1] 2 3
 

X10.com | About X10 | X10 Security Systems | Cameras| Package Deals
© Copyright 2014-2016 X10.com All rights reserved.