Shop OBEX P1 Docs P2 Docs Learn Events
Android Debug Bridge on a prop - Page 4 — Parallax Forums

Android Debug Bridge on a prop

124

Comments

  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-02 13:28
    I don't know if there is an app that does that, but it shouldn't be hard to write. I ported dterm to android a while ago using the minimum reference specs, and it's been working great on all the phones I put it on. That said, I have never seen errors other than a babble condition on some obsolete versions of cyanogenmod, so using cat should be fine.
  • ColeyColey Posts: 1,110
    edited 2011-05-03 02:33
    @simonl
    As you are in the UK if you PM me your address I'll send you a couple of 6MHz crystals, I've got loads..:thumb:

    Coley
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-03 12:05
    a bit more work on this -- you can tell the prop to start Android apps using the "am start" command, but the syntax is a nightmare.

    http://learnandroid.blogspot.com/2008/01/run-android-application-from-command.html <- works
  • TubularTubular Posts: 4,703
    edited 2011-05-03 13:46
    Good news. Yes looks like a complicated syntax but once you've done it once I'm sure it makes a whole lot more sense.
  • TubularTubular Posts: 4,703
    edited 2011-05-03 13:51
    Adafruit blog has your demo showing :-
    http://www.adafruit.com/blog/2011/05/02/cheap-and-easy-android-to-propeller-bridge/

    see, people *are* noticing :)

    No mention there of the "dual host" version as yet. Hmm what could be done connecting to two android phones...
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-03 16:17
    Not terribly much :) the dual host so far only makes much sense if you're talking to a phone and a usb flash drive at the same time, for making backups -- everything else two phones can do via bluetooth with no external hardware. Im working on a prop based bidge for phone--prop--any one usb device (would be great with printers) but thats a long time coming :)
  • TubularTubular Posts: 4,703
    edited 2011-05-04 17:38
    Inching forward on this...

    M K Borri, any idea what kind of bandwidth is available when talking between the Prop and ADB ? Just a ball park would be useful to know... 9600 bps?

    also, is it roughly the same in both directions?
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-05 07:40
    It is roughly the same. I find that ~115200bps is what seems to work as far as keeping up goes for long periods. The other option is audio as shown here http://hackaday.com/2010/11/10/android-talks-pulsewave/ the propeller can do up to 24000bps on most phones but it's one-way only. Both seem adequate for robots, but ADB was needed for dataloggers, which is what we are doing with them. I now sell a kit, but honestly it's just a prop board with a serial port, servo-style headers and a usb receptacle so it's something you can do yourself with a protoboard and four resistors :)
  • TubularTubular Posts: 4,703
    edited 2011-05-05 14:48
    Doesn't matter what it is... its what it does! Got a link to your kit? Can I buy a couple?
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-06 01:31
    sure, but it's really easy to do this from a proto board :) it's just 4 resistors and the usb plug. including shipping it's a lot cheaper to DIY :) that said email me at mkb@libero.it
  • TubularTubular Posts: 4,703
    edited 2011-05-06 15:32
    Ok, well I tried :)

    Got some 6 Mhz crystals yesterday, so I can look forward to some prop fun over the weekend
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-08 03:59
    I do sell a kit, right now it's $40 for it if you want one -- it's just a prop with a serial port, usb port and 26 servo-style headers. All I was saying is that if you already have a protoboard around it's a lot easier to build your own, especially if you're in Australia, because shipping time/cost :)

    Don't forget that right now only pins 0 and 1 can be used for the usb port. This will soon change but not there yet.
  • GerryKeelyGerryKeely Posts: 12
    edited 2011-05-08 05:32
    This is just for information http://www.basic4ppc.com sell a basic programming language for the android operating system. May be useful if you are not familiar with Java.

    regards
    Gerry
  • TubularTubular Posts: 4,703
    edited 2011-05-08 16:44
    Thanks Gerry, that looks really good. Are you using it for anything interesting?
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-08 17:49
    http://developer.android.com/sdk/eclipse-adt.html This is where you can get Eclipse (free) to develop on Android. I include a simple demo to send and receive data from the ADB bridge with the object, feel free to modify to suit your needs! The i/o stuff is in a "library" file which you are welcome to copy/paste in your own project and I tried to make it act more or less like a propeller object with rx and tx and str. Best I can do!

    I now have upgraded most of my Antbots to use the new system. I also am doing a long range UAV, but cannot post video because it's for a nasa guy so I have to get a zillion signatures for permission to put it on youtube... derp. (At least they pay me!)
  • TubularTubular Posts: 4,703
    edited 2011-05-10 22:57
    M K Borri,

    Did you see this?
    http://developer.android.com/guide/topics/usb/adk.html

    They are talking about the end of this year. You are well ahead of them.
  • Heater.Heater. Posts: 21,230
    edited 2011-05-10 23:14
    Interesting. How complicated could they make it?!.

    What should we do about powering the phone? As we are a USB host we should be supplying power also.
  • TubularTubular Posts: 4,703
    edited 2011-05-10 23:30
    Powering the phone? Sounds entirely reasonable!

    Actually I want to power some small motors and was expecting to power them separately anyways.

    So if we don't need the phone to have a battery (because its externally powered), we can use the battery space for a prop chip, right?

    This board I made has the three spots for resistors for a usb host. I haven't tried it yet. I don't think there will be enough height for both the C3 on the back side and the crystal, but lets see how it goes.

    DSC01260.jpg
    1024 x 680 - 90K
  • Heater.Heater. Posts: 21,230
    edited 2011-05-11 00:07
    Hey, that's damn neat!
  • TubularTubular Posts: 4,703
    edited 2011-05-11 00:43
    It would be neater if I could get the battery I wanted to which is 2.5x the capacity and should fit perfectly
    http://www.master-instruments.com.au/products/61348/LP601730-PCM-LD.html
  • Heater.Heater. Posts: 21,230
    edited 2011-05-11 00:54
    Today I'm considering dedicating my Samsug Galaxy S to Propeller projects.

    I just discovered that the contacts file that I exported to SD card and then carefully saved on my PC contains a few hundred contact name and email addresses and avatars etc , mostly sucked down from gmail. However now that I am in need of the back up I find that the file only has telephone numbers for about five contacts, wtf!!!

    Normally this would result in the phone going under the hammer but the Prop can make use of it.
  • TubularTubular Posts: 4,703
    edited 2011-05-11 01:39
    Heater. wrote: »
    Today I'm considering dedicating my Samsug Galaxy S to Propeller projects.
    ... normally this would result in the phone going under the hammer but the Prop can make use of it.

    Excellent! Do it!

    I suspect old Android phones are going to find all sorts in interesting second lives, kinda like old PCs do, or used to...
  • Heater.Heater. Posts: 21,230
    edited 2011-05-11 02:12
    Ha! This thing was damn expensive. "smart phone" indeed. Pretty stupid as a phone.

    Anyway, that thought about cheap and/or old Android devices for use with the Prop is what prompted my "Android android" thread a while back. And lo it came to be!

    It's hard to buy just a display for less. Not to mention all the other goodies.
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-11 05:15
    G1s are easy to find, I get them unlocked for $90 a piece. And this will work with the stock firmware. Careful however that a lot of phones will not boot without the battery, and the battery has some smarts in it to make that so!
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-12 01:27
    http://blog.laptopmag.com/google-announces-android-open-accessory-initiative So Google just presented this... their cellbots list is being filled with people calling them on too-little-too-late.
  • Heater.Heater. Posts: 21,230
    edited 2011-05-12 01:34
    Turns out that my Samsung Galaxy will not run with out a battery when plugged into USB for charging.

    Question might be how to get the smarts out of an old dead battery to keep the phone happy?
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-12 01:48
    That's actually easy: you can gut the battery, take out the cells, feed the phone a voltage thru the battery's side (sadly the 3.3v that the prop uses is too low), and keep the little chip in the battery.
    Alternatively you can devote a couple prop pins to pretend to be the battery's circuit, it's some variant of 1-wire protocol. The expert on this particular issue is bendhoward@gmail.com so poke him!
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-05-22 08:51
    I no longer feel comfortable continuing to develop the propbridge, it has brought me nothing but insults and suspicion. I refuse to beat someone up over a piece of hardware regardless how good said piece of hardware is.
  • TubularTubular Posts: 4,703
    edited 2011-05-22 14:32
    "If everyone says you are wrong, you're one step ahead. If everyone laughs at you, you're two steps ahead.”
    -- Charles Thompson
  • Heater.Heater. Posts: 21,230
    edited 2011-05-22 14:45
    M.K.Borri,

    I'm very sorry to hear this. I do hope we can buoy up your spirits and change your mind. We think the debug bridge is a brilliant and useful piece of work and it would be a serious shame to see it languish.

    Were are all the insults and suspicion coming from? Sounds like the Prop and Android using community should give these people a talking to.
Sign In or Register to comment.