[android-developers] Re: audio recording issues

2008-12-08 Thread Dorn Hetzel

While I am sure any "forward looking statement" will need to be taken
with a grain of salt, perhaps you could alleviate many of our concerns
with some clue as to the timeframe in which we might expect relief on
this front.  If we knew that in a month or two we could look forward
to at least rudimentary real-time audio we could quit expending energy
on trying to scheme a workaround and just delay our application plans.
 If it's going to be a lot longer than that, we can make appropriate
decisions as well.  Leaving us knowing nothing doesn't really engender
confidence.  Some sort of roadmap with approximate dates would help a
lot!

Regards,

Dorn Hetzel

On Fri, Dec 5, 2008 at 12:12 AM, Dave Sparks <[EMAIL PROTECTED]> wrote:
>
> The reason this isn't in 1.0 is because we didn't want to ship a half-
> baked API. We have a solution coming soon in the form of a flexible
> base layer that supports push and pull models. For example, we have
> built an InputStream object on top of it that we will offer as sample
> code.
>
> In the future, this development will be taking place in the open
> source repo so we can have a real-time dialog about the code as it is
> developed. In the meantime, we are working hard to get the code that
> has been in development since we forked the 1.0 branch moved into the
> open source repo as soon as possible.
>
> On Dec 4, 6:40 pm, MichaelEGR <[EMAIL PROTECTED]> wrote:
>> On Dec 2, 5:22 am, "Dorn Hetzel" <[EMAIL PROTECTED]> wrote:
>>
>> > Maybe we need to start another mailing list for unrequited android
>> > realtimeaudio:)
>>
>> I'm all for focused discussion on this topic as it crosses between
>> native concerns and public APIs via the SDK. In my longer original
>> post I mentioned that it would be appropriate to evaluate how to not
>> only getting something workable on the G1, but keep in mind that
>> Android can/will be used in the future conceivably beyond smart phones
>> in devices/hardware that may support expanded audio I/O options. I
>> favor PortAudio (www.portaudio.com) for the task as it can provide a
>> workable real time audio API for desktop Java and Android audio
>> development/porting to other hardware configurations. It is also low
>> level enough to say even implement javax.sound on top of it for those
>> interested in that particular API. More discussion is welcome
>> especially in understanding unspecified work being done for the next
>> SDK release.
>>
>> Best,
>> --Mike
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: precision of alarms using RTC_WAKEUP

2008-12-08 Thread Dorn Hetzel

Is there a recommended method for setting alarms that will survive a
power cycle ?

On Mon, Dec 8, 2008 at 3:21 AM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> On Mon, Dec 8, 2008 at 12:18 AM, alex <[EMAIL PROTECTED]> wrote:
>>
>> My problem is that some alarms (maybe 20% of them) fire late, up to 15
>> minutes late.  Others are right on time.  Is this expected behavior?
>> Has anyone else noticed this?
>
> Are you sure you are holding a wake lock the entire time you process the
> alarm?  Put a log output in your intent receiver to be sure the problem is
> the alarm not going off, instead of the CPU going to sleep while your own
> code is running,
>
>>
>> A related question: if the user powers off and on his/her device, it
>> seems that the alarms that were set prior to the off/on don't fire.
>> Is that expected behavior as well?
>
> Yes.
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Testing application

2008-12-03 Thread Dorn Hetzel

I've just been testing on my phone.  I hadn't learned until recently
about being able to load
.apk's from my own website so I just uploaded my test to market under
demo and named it
something like "TestDontDownload" :)Still got some downloads and
one star reviews :)

On Wed, Dec 3, 2008 at 11:10 AM, loty <[EMAIL PROTECTED]> wrote:
>
> Personally I found that emulator does a pretty good job at
> approximating the physical device but you really want to try your app
> on an actual phone before you unleash it on the unsuspecting public. I
> found numerous issues with my UIs that are very easy to click using
> mouse in the emulator but near impossible to do on my G1 with my man
> fingers.
> To get apps into my phone I compile my apps in release, sign them and
> upload to my web site from which I download it using my phone's
> browser. Just make sure Unknown Sources under Applications is checked.
>
> On Dec 2, 11:09 pm, "indiabolbol.com" <[EMAIL PROTECTED]> wrote:
>> I am interested in how the developers tested the application before
>> putting the application on the android market. I know it can be tested
>> on the device, but what about testing on the real device.
>>
>> In other words, if I have the real device can I upload the application
>> to the device and perform the test? If so, how do I connect my
>> development environment to real device, rather than the emulator.
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: G1 Linux

2008-12-02 Thread Dorn Hetzel

Totally!

On Tue, Dec 2, 2008 at 5:22 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> Because He Was Enthralled By The Awesomeness Of It, Like I Am Too.  It Is
> Awesome!
>
> On Tue, Dec 2, 2008 at 2:20 PM, Xavier Mathews <[EMAIL PROTECTED]>
> wrote:
>>
>> Why Did You Say That?
>>
>> On 12/02/2008, Eric Mill <[EMAIL PROTECTED]> wrote:
>> >
>> > This has been an awesome thread.
>> >
>> > On Dec 1, 5:33 pm, "Xavier Mathews" <[EMAIL PROTECTED]> wrote:
>> >> So that means the G1 Does!
>> >>
>> >> Xavier A. Mathews
>> >> Student/Browser Specialist/Developer/Web-Master
>> >> Google Group Client Based Tech Support Specialist
>> >> Hazel Crest Illinois
>> >> [EMAIL PROTECTED]@[EMAIL PROTECTED]
>> >> "Fear of a name, only increases fear of the thing itself."
>> >>
>> >> On Mon, Dec 1, 2008 at 4:31 PM, Jean-Baptiste Queru <[EMAIL PROTECTED]>
>> >> wrote:
>> >>
>> >> > Android is and has always been built on top of Linux.
>> >>
>> >> > JBQ
>> >>
>> >> > On Mon, Dec 1, 2008 at 2:30 PM, Xavier Live Tech.S
>> >> > <[EMAIL PROTECTED]> wrote:
>> >>
>> >> > > Will G1 be running Linux like Iphone anytime soon?
>> > >
>> >
>>
>>
>> --
>> Xavier A. Mathews
>> Student/Browser Specialist/Developer/Web-Master
>> Google Group Client Based Tech Support Specialist
>> Hazel Crest Illinois
>> [EMAIL PROTECTED]@[EMAIL PROTECTED]
>> "Fear of a name, only increases fear of the thing itself."
>>
>>
>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: audio recording issues

2008-12-02 Thread Dorn Hetzel

Melody,

Unfortunately, this does seem to be the situation until at least the
next release of the SDK.

I am trying to find a way around it through other interfaces in the
native code, but I get the impression that even if I find one,
it won't actually be useable in combination with SDK code.

Maybe we need to start another mailing list for unrequited android
realtime audio :)

Regards,

-Dorn

On Mon, Dec 1, 2008 at 10:02 PM, melody <[EMAIL PROTECTED]> wrote:
>
> I've been working on an application that requires the user to record
> some audio, and for that audio to be sent my server.  On our end, we
> then analyze that audio and return results to the user.  The percieved
> performance of our application benefits greatly from being able to
> start sending the audio data to our server while the user is still
> recording.
>
> My problem:
>
> The MediaRecorder class only seems to support writing to a file at the
> moment.  This audio data seems to be flushed to this output file in
> 4kB chunks, which works out to about 7 seconds of audio.  This means I
> can't start sending any data to my server until after the first 7
> seconds of recording (and then I can't send anything again for another
> 7 seconds, and so on).  Ideally I would like to start sending the
> audio to the server much sooner, and in much smaller chunks than
> that.  This is not only to minimize the potential impact of a slow
> connection, but also so that I can start processing the chunks of
> audio earlier.
>
> The perfect situation would be that when the user stops recording
> audio, I will have already received and processed almost all that he/
> she recorded, with only a very small chunk leftover.
>
> Thanks for your help.
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: pre-portability number being returned from telephony manager

2008-11-27 Thread Dorn Hetzel


I had to get tmobile to repush the ported number to my phone before it would 
work right

On Nov 27, 2008 12:26 PM, "Clay" <[EMAIL PROTECTED]> wrote:


I tried to search around a bit but this is all I could find...

http://groups.google.com/group/android-developers/browse_thread/thread/34da2ed2431f67f9/627e73f98fd84f77?lnk=gst&q=TelephonyManager#627e73f98fd84f77

it seems that telephony manager is not in sync with the network after
I ported my number, is there any way to find out the real endpoint for
the phone? I have a feeling that most people will use portability so I
need to know how to support it.

THX!

Clay





--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Push Notification Techniques: Discuss

2008-11-26 Thread Dorn Hetzel

My phone seems to get an IP from T-mobile which is not an RFC1918
address, and which I am therefore guessing *may* be routable.

I have a little more code to write and I will have an answer on that.
Does anyone else already know the answer?

On Wed, Nov 26, 2008 at 6:26 PM, Mark Murphy <[EMAIL PROTECTED]> wrote:
>
>> If I open a datagram socket to listen on a particular UDP port and
>> leave it open but don't send anything, does that keep the radio on?
>>
>> If a listening socket doesn't keep the radio on, then an application
>> could send a couple packets to register it's IP and port and then shut
>> up and wait for incoming requests.
>>
>> Thoughts?
>
> I doubt there's a unique IP address per phone on a carrier data network --
> it feels like too many addresses would be needed. It's probably NATted or
> the equivalent. Hence, I'm not convinced a phone can serve as a server
> (TCP or UDP) without help, a la P2P NAT-traversal systems.
>
> But, then again, I've certainly been wrong before...
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 1.4 Published!
>
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Push Notification Techniques: Discuss

2008-11-26 Thread Dorn Hetzel

If I open a datagram socket to listen on a particular UDP port and
leave it open but don't send anything, does that keep the radio on?

If a listening socket doesn't keep the radio on, then an application
could send a couple packets to register it's IP and port and then shut
up and wait for incoming requests.

Thoughts?

On Wed, Nov 26, 2008 at 5:43 PM, Mark Murphy <[EMAIL PROTECTED]> wrote:
>
>> And the radio is necessarily always on.
>
> Yeah, but...
>
> I was under the impression that, in normal operating mode, the GSM radio
> is in a low-power state. That's why you have "talk time" versus "standby
> time" in mobile device battery life specs -- when a call begins, the radio
> stays in a high-power-draw state until the call ends.
>
> So, the question is: with an open-but-quiet Internet connection on a
> carrier data network, how much power draw is there from the GSM radio?
>
> There's also the scenario of the device being on WiFi instead of GSM, but
> that's probably not as frequent.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 1.4 Published!
>
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Flaky network connections

2008-11-24 Thread Dorn Hetzel

If you sniff the wire just past the wifi access point, how many
requests/responses do you see during this time?

On Mon, Nov 24, 2008 at 2:59 PM, joshv <[EMAIL PROTECTED]> wrote:
>
> My issues is that I am sitting 3 feet from a stable wi-fi access point
> and for minutes on end every single URLConnection attempt will fail.
> I could certainly understand if maybe the first attempt failed, or
> took longer, because I was waiting for the radio to turn on, but 100%
> failure for minutes on end is just weird.  There is no good reason for
> it.  It should be considered a bug.  And even when it does work, it's
> still not 100%, the failure rate is still very high.
>
> This makes for a really crappy application experience, as I simply
> cannot predict when my user will see their data update.  I feel like
> there are reliable ways of communicating, as even when my application
> is experiencing errors, I get emails and IMs on the phone, and I can
> browse the internet - so somehow the google apps are able to
> communicate.  That's why I am asking if I am doing something wrong or
> if there is some other API I should try.  I can try out the Apache
> HTTPComponents, but I am assuming they just wrap the lower level java
> network APIs.  I am not sure what benefit I would get.
>
> On Nov 24, 1:44 pm, "Tom Gibara" <[EMAIL PROTECTED]> wrote:
>> I don't know if this is related to what you're experiencing, but it's my
>> understanding that the wifi connections shuts down when the phone sleeps. I
>> believe this is because, unlike the radio, it requires the CPU to be active
>> to maintain the connection.
>> Also, contrary to your view, I think it's not intrinsically a hardware or
>> software problem. It's simply that in the context of mobile phone software,
>> the probability of a connection failure is greater than that you may be used
>> to, and due to the necessary limitations in powering the device, simple
>> solutions (like constantly striving to maintain a wifi connection) aren't an
>> option.
>>
>> Perhaps a better perspective is to see the various data connections (wifi,
>> GPRS, EDGE, 3G etc.) as fallible primitives which you can combine to form a
>> more reliable transport suited to your application's needs.
>>
>> Tom.
>>
>> 2008/11/24 joshv <[EMAIL PROTECTED]>
>>
>>
>>
>> > As I pointed out in my previous post, the polling occurs only when the
>> > application is active and on screen.  It starts/stops in onResume/
>> > onPause - so I am not sure how this is going to limit battery life
>> > unless the user forces the application to remain active for hours at a
>> > time.
>>
>> > Could you please explain to me why, with a solid wi-fi signal and
>> > connection to a local access point, my URLConnections would ever throw
>> > an exception unless there is a problem with the remote website?  Are
>> > the implementations of these APIs that brittle?  Is the hardware
>> > really that flaky?
>>
>> > Are there other APIs that bang on the hardware until it works, without
>> > throwing exceptions?  Am I doing something wrong?  Or is this level of
>> > unreliability, even over local wi-fi, to be expected?
>>
>> > On Nov 24, 10:58 am, Jean-Baptiste Queru <[EMAIL PROTECTED]> wrote:
>> > > Even with a 10-second pause between the end of a response and the next
>> > > request, you're likely to keep the radio (either cell or wifi) turned
>> > > on all the time, since they tend to stay up for about that long even
>> > > when there's no activity before powering back down. That could limit
>> > > the phone's battery life to as little as 3 or 4 hours (with the screen
>> > > constantly off and the CPU idle most of the time).
>>
>> > > The APIs that you're using are built on top of a foundation that was
>> > > designed for environments where the conditions that trigger exceptions
>> > > were indeed more exceptional than what you're seeing on a device
>> > > indeed. Such is the cost of making Android compatible with APIs that
>> > > developers are likely to be familiar with.
>>
>> > > JBQ
>>
>> > > On Mon, Nov 24, 2008 at 8:51 AM, joshv <[EMAIL PROTECTED]> wrote:
>>
>> > > > The polling happens only while the apps is loaded and displayed on
>> > > > screen.  The second the screen turns off or another app is loaded, the
>> > > > polling stops.  It's pretty well behaved in that respect.  Also, I
>> > > > don't hammer the connection 6 times a minute no matter what - each
>> > > > thread waits for the previous to finish, waits ten seconds, and then
>> > > > attempts to connect.
>>
>> > > > My issue is that URLConnections seem to be so unreliable that
>> > > > Exceptions seem to be the rule, not the exception.  This might be
>> > > > something unique to my handset, I only have one, so I can't tell.  It
>> > > > certainly doesn't happen in the emulator.  I might expect it to happen
>> > > > if I have a marginal 3G or edge connection - but not when the handset
>> > > > is literally 3 feet away from the WiFi access point it's using for a
>> > > > c

[android-developers] Re: native audio interface / AudioRecord.h

2008-11-24 Thread Dorn Hetzel

Dianne,

Ok, well, can you tell me if using the C++ Audio Libraries is merely
unsupported, or is actually not possible due to the security model of
the currently deployed platform (G1) ?

I mean, can I write most of my application in the standard SDK but use
one outside JNI/.so that is unsupported to do my audio bits, or will
that simply not work because I can't merge it with the SDK code and
sign it and upload it to market and download it to a phone and have it
work?

Thanks!

-Dorn

On Mon, Nov 24, 2008 at 2:36 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> Sorry, at this point any native code is outside of the SDK.  Using the C++
> audio libraries is way way way outside of the SDK.
>
> On Mon, Nov 24, 2008 at 6:05 AM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>>
>> Dianne,
>>
>> Hmm, sorry, didn't realize I had gone off-topic.  I still plan to
>> develop in the SDK.
>>
>> Is it possible use the SDK and still access one custom .so ?  If so,
>> am I still off-topic?
>>
>> Regards,
>>
>> -Dorn
>>
>> On Sun, Nov 23, 2008 at 7:48 PM, Dianne Hackborn <[EMAIL PROTECTED]>
>> wrote:
>> > Could you please move this to android-platform or another of the open
>> > source
>> > groups?  Thanks.
>> >
>> > On Sun, Nov 23, 2008 at 12:40 PM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>> >>
>> >> David,
>> >>
>> >> Thank you very very much for the tips.  I've gotten as far as
>> >> downloading the android source code (onto a clean ubuntu VM I built
>> >> for the job) and doing an initial make (which generated quite a lot of
>> >> whining level errors but seemed to complete ok).
>> >>
>> >> I'm so-so at Java but a pretty old hand at C/C++ so hopefully I will
>> >> be able to work through the remaining steps.  Can you recommend any
>> >> other similar interface classes I could examine for general clues?
>> >>
>> >> Once I get all this done, will the .so in the .apk be able to go
>> >> through the marketplace and run on a real G1 or will I only be able to
>> >> play with in on the emulator?
>> >>
>> >> In any case, I will write progress reports to the list and make the
>> >> code available to all if I succeed.
>> >>
>> >> Best Regards,
>> >>
>> >> Dorn Hetzel
>> >>
>> >> On Fri, Nov 21, 2008 at 8:23 PM, davidsparks davidsparks
>> >> <[EMAIL PROTECTED]> wrote:
>> >> > The native interface is called AudioRecord.h. You'll need to download
>> >> > the
>> >> > Android source code, write a JNI interface to AudioRecord, build a
>> >> > .so
>> >> > library that you can include in your APK, write a Java wrapper class
>> >> > for
>> >> > it,
>> >> > and then load the library from your Java wrapper.
>> >> >
>> >> > Hope that helps.
>> >> >
>> >> > Dave
>> >> >
>> >> > On Wed, Nov 19, 2008 at 11:22 AM, Dorn Hetzel <[EMAIL PROTECTED]>
>> >> > wrote:
>> >> >>
>> >> >> David,
>> >> >>
>> >> >> It looks like the MediaRecorder functionality is a non-start for my
>> >> >> application since I need to process the audio as it is coming in,
>> >> >> not
>> >> >> some time later after the recording is complete.  Can you provide me
>> >> >> some clue as to where to find information on the native interface,
>> >> >> since I would rather be able to at least make some progress with the
>> >> >> rest of my application while waiting for the next version.  Without
>> >> >> some alternative to MediaRecorder I will be simply unable to
>> >> >> proceed.
>> >> >>
>> >> >> Thanks!
>> >> >>
>> >> >> -Dorn
>> >> >>
>> >> >> On Wed, Nov 19, 2008 at 2:14 PM, [EMAIL PROTECTED]
>> >> >> <[EMAIL PROTECTED]> wrote:
>> >> >> >
>> >> >> > It is the only supported method in SDK 1.0. There is a native
>> >> >> > interface to audio input, but it will be changing in a future
>> >> >> > release
>> >> >> > and I strongly advise against using it.
>> >> >> >
>> >> >> > On N

[android-developers] acceptable range of ports for DatagramSocket in Android SDK

2008-11-24 Thread Dorn Hetzel

What is the acceptable range of port numbers which can be passed to
new DatagramSocket(n) in Android SDK?

800 fails (not suprisingly, less than 1024)
1075 succeeds
1999 succeeds
 fails
30230 fails

And yes, my manifest requests INTERNET permission :)

Code example below, any clues appreciated...

package com.mese.hello;

import android.app.Activity;
import android.os.Bundle;
import android.widget.TextView;
import java.net.DatagramSocket;
import java.net.SocketException;

public class MeseHelloAndroid extends Activity {
protected DatagramSocket s = null;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
TextView tv = new TextView(this);
try {
s = new DatagramSocket(1999);
tv.setText("Mese Says, 'Socket Created.'");
} catch (SocketException e){
tv.setText("Mese Says, "+e.toString());
}
/* setContentView(R.layout.main); */
setContentView(tv);
}
}

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: native audio interface / AudioRecord.h

2008-11-24 Thread Dorn Hetzel

Dianne,

Hmm, sorry, didn't realize I had gone off-topic.  I still plan to
develop in the SDK.

Is it possible use the SDK and still access one custom .so ?  If so,
am I still off-topic?

Regards,

-Dorn

On Sun, Nov 23, 2008 at 7:48 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> Could you please move this to android-platform or another of the open source
> groups?  Thanks.
>
> On Sun, Nov 23, 2008 at 12:40 PM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>>
>> David,
>>
>> Thank you very very much for the tips.  I've gotten as far as
>> downloading the android source code (onto a clean ubuntu VM I built
>> for the job) and doing an initial make (which generated quite a lot of
>> whining level errors but seemed to complete ok).
>>
>> I'm so-so at Java but a pretty old hand at C/C++ so hopefully I will
>> be able to work through the remaining steps.  Can you recommend any
>> other similar interface classes I could examine for general clues?
>>
>> Once I get all this done, will the .so in the .apk be able to go
>> through the marketplace and run on a real G1 or will I only be able to
>> play with in on the emulator?
>>
>> In any case, I will write progress reports to the list and make the
>> code available to all if I succeed.
>>
>> Best Regards,
>>
>> Dorn Hetzel
>>
>> On Fri, Nov 21, 2008 at 8:23 PM, davidsparks davidsparks
>> <[EMAIL PROTECTED]> wrote:
>> > The native interface is called AudioRecord.h. You'll need to download
>> > the
>> > Android source code, write a JNI interface to AudioRecord, build a .so
>> > library that you can include in your APK, write a Java wrapper class for
>> > it,
>> > and then load the library from your Java wrapper.
>> >
>> > Hope that helps.
>> >
>> > Dave
>> >
>> > On Wed, Nov 19, 2008 at 11:22 AM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>> >>
>> >> David,
>> >>
>> >> It looks like the MediaRecorder functionality is a non-start for my
>> >> application since I need to process the audio as it is coming in, not
>> >> some time later after the recording is complete.  Can you provide me
>> >> some clue as to where to find information on the native interface,
>> >> since I would rather be able to at least make some progress with the
>> >> rest of my application while waiting for the next version.  Without
>> >> some alternative to MediaRecorder I will be simply unable to proceed.
>> >>
>> >> Thanks!
>> >>
>> >> -Dorn
>> >>
>> >> On Wed, Nov 19, 2008 at 2:14 PM, [EMAIL PROTECTED]
>> >> <[EMAIL PROTECTED]> wrote:
>> >> >
>> >> > It is the only supported method in SDK 1.0. There is a native
>> >> > interface to audio input, but it will be changing in a future release
>> >> > and I strongly advise against using it.
>> >> >
>> >> > On Nov 19, 8:26 am, dorn <[EMAIL PROTECTED]> wrote:
>> >> >> Is the MediaRecorder the only method available to acquire audio from
>> >> >> the microphone, or is there a lower level method available?
>> >> >>
>> >> >> On Nov 14, 4:59 pm, Dave Sparks <[EMAIL PROTECTED]> wrote:
>> >> >>
>> >> >> > The MediaRecorder is currently hardcoded for AMR-NB and is
>> >> >> > intended
>> >> >> > for MMS messages.
>> >> >>
>> >> >> > You can expect improvements toaudiorecording in a future SDK.
>> >> >>
>> >> >> > On Nov 14, 12:26 pm, ste <[EMAIL PROTECTED]> wrote:
>> >> >>
>> >> >> > > I'm testing out the MediaRecorder'saudiorecording capability,
>> >> >> > > and
>> >> >> > > the quality of theaudiowas less then I was expecting. It was
>> >> >> > > significantly lower then the quality you get while speaking on
>> >> >> > > the
>> >> >> > > phone, and sounded very digitized.
>> >> >> > > I've tested both the 3gpp and MPEG_4 encoding options, and
>> >> >> > > noticed
>> >> >> > > the
>> >> >> > > same quality.
>> >> >> > > Has anyone else noticed this, and is this an issue with the
>> >> >> > > phone's
>> >> >> > > hardware or the MediaRecorder's capabilities? If it's the
>> >> >> > > latter,
>> >> >> > > is
>> >> >> > > the quality of recording something which is planned to be
>> >> >> > > improved?
>> >> > >> >
>> >> >
>> >
>> >
>>
>>
>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] native audio interface / AudioRecord.h

2008-11-23 Thread Dorn Hetzel

David,

Thank you very very much for the tips.  I've gotten as far as
downloading the android source code (onto a clean ubuntu VM I built
for the job) and doing an initial make (which generated quite a lot of
whining level errors but seemed to complete ok).

I'm so-so at Java but a pretty old hand at C/C++ so hopefully I will
be able to work through the remaining steps.  Can you recommend any
other similar interface classes I could examine for general clues?

Once I get all this done, will the .so in the .apk be able to go
through the marketplace and run on a real G1 or will I only be able to
play with in on the emulator?

In any case, I will write progress reports to the list and make the
code available to all if I succeed.

Best Regards,

Dorn Hetzel

On Fri, Nov 21, 2008 at 8:23 PM, davidsparks davidsparks
<[EMAIL PROTECTED]> wrote:
> The native interface is called AudioRecord.h. You'll need to download the
> Android source code, write a JNI interface to AudioRecord, build a .so
> library that you can include in your APK, write a Java wrapper class for it,
> and then load the library from your Java wrapper.
>
> Hope that helps.
>
> Dave
>
> On Wed, Nov 19, 2008 at 11:22 AM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>>
>> David,
>>
>> It looks like the MediaRecorder functionality is a non-start for my
>> application since I need to process the audio as it is coming in, not
>> some time later after the recording is complete.  Can you provide me
>> some clue as to where to find information on the native interface,
>> since I would rather be able to at least make some progress with the
>> rest of my application while waiting for the next version.  Without
>> some alternative to MediaRecorder I will be simply unable to proceed.
>>
>> Thanks!
>>
>> -Dorn
>>
>> On Wed, Nov 19, 2008 at 2:14 PM, [EMAIL PROTECTED]
>> <[EMAIL PROTECTED]> wrote:
>> >
>> > It is the only supported method in SDK 1.0. There is a native
>> > interface to audio input, but it will be changing in a future release
>> > and I strongly advise against using it.
>> >
>> > On Nov 19, 8:26 am, dorn <[EMAIL PROTECTED]> wrote:
>> >> Is the MediaRecorder the only method available to acquire audio from
>> >> the microphone, or is there a lower level method available?
>> >>
>> >> On Nov 14, 4:59 pm, Dave Sparks <[EMAIL PROTECTED]> wrote:
>> >>
>> >> > The MediaRecorder is currently hardcoded for AMR-NB and is intended
>> >> > for MMS messages.
>> >>
>> >> > You can expect improvements toaudiorecording in a future SDK.
>> >>
>> >> > On Nov 14, 12:26 pm, ste <[EMAIL PROTECTED]> wrote:
>> >>
>> >> > > I'm testing out the MediaRecorder'saudiorecording capability, and
>> >> > > the quality of theaudiowas less then I was expecting. It was
>> >> > > significantly lower then the quality you get while speaking on the
>> >> > > phone, and sounded very digitized.
>> >> > > I've tested both the 3gpp and MPEG_4 encoding options, and noticed
>> >> > > the
>> >> > > same quality.
>> >> > > Has anyone else noticed this, and is this an issue with the phone's
>> >> > > hardware or the MediaRecorder's capabilities? If it's the latter,
>> >> > > is
>> >> > > the quality of recording something which is planned to be improved?
>> > >> >
>> >
>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Problem doing the programming tutorial

2008-11-22 Thread Dorn Hetzel


When the android emulator pops up it takes a good while to boot b4 it runs 
your code

On Nov 22, 2008 8:13 PM, "automerc" <[EMAIL PROTECTED]> wrote:


Hello, I downloaded and set up the sdk and I was working on the Hello,
Android! part of the tutorial, but I am having issues. When I ran the
code nothing happens expect that a android simulator pops up in my
screen. The doesn't seem to do anything and it doesn't look anything
like what it should in the Hello, Android! tutorial. I tried this
answer codes provided in the tutorial for the Hello, Android! and the
notepad application and the same simulator appears.
Can any1 tell me how to fix this and what i'm doing wrong. Also i'm
using eclipse to work on the programs.



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Eclipse repo is down?

2008-11-22 Thread Dorn Hetzel

Well, I can tell you that a few days ago, https didn't work for me,
and http still whined, but when I expanded the selection box, what I
needed was magically there.

On Sat, Nov 22, 2008 at 2:08 PM, David Orriss Jr <[EMAIL PROTECTED]> wrote:
>
> Same thing.. which kind of figures when you note that the beginning of
> that URL address is *dl-SSL*.. ;)
>
> And in all seriousness.. this isn't good considering this is the home
> of the Android SDK plugin for eclipse.. :|
>
> On Sat, Nov 22, 2008 at 8:19 AM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>>
>> Try http instead of https
>>
>> On Sat, Nov 22, 2008 at 3:33 AM, Bogomil Shopov
>> <[EMAIL PROTECTED]> wrote:
>>>
>>> Hi all,
>>> There is no Eclipse repo available here:
>>> https://dl-ssl.google.com/android/eclipse/
>>>
>>>
>>> Bogo
>>>
>>> >
>>>
>>
>> >
>>
>
>
>
> --
> David Orriss Jr.
>
> My blog: http://www.codethought.com/blog
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: how to inject a KeyEvent

2008-11-22 Thread Dorn Hetzel

Is that a permanent, security related, state if the droid, or is it
thought that someday, with the right permissions, or between
consenting applications, this would be allowed? :)

On Fri, Nov 21, 2008 at 7:23 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> Correct, one application can not inject key events into another
> application.  There should be no way around this.
>
> For instrumentation test cases that cross application boundaries, I strongly
> recommend you set up an ActivityMonitor to block the launching of that other
> application's activity, returning a mocked result instead.
>
> On Fri, Nov 21, 2008 at 3:34 PM, dreamerBoy <[EMAIL PROTECTED]> wrote:
>>
>> Hi Hackbod -
>>
>> I tried this using Instrumentation -
>>
>> The goal of this little program is to make an outgoing call and then
>> generate a keypress on the ENDCALL button.
>>
>> 1. It appears that I am incapable of unlocking the keyguard:
>>
>> 11-21 14:40:58.445: INFO/InstTest(209): after
>> inKeyguardRestrictedInputMode() ? true
>>
>> 2. Then, Android tells me I don't have permission to send a key event:
>>
>> 11-21 14:41:00.173: WARN/WindowManager(53): Permission denied:
>> injecting key event from pid 209 uid 10019 to window Window{43506808
>> com.android.phone/com.android.phone.InCallScreen} owned by uid 1001
>>
>> EmptyActivity is just as it sounds - no additional code other than
>> what Eclipse generates.
>>
>>
>> If anyone can see something that is not being done correctly, I would
>> very much appreciate their thoughts -
>>
>> Thanks -
>>
>> Paul
>>
>> ~~
>>
>> package test.instTest;
>>
>> import android.app.Activity;
>> import android.content.Context;
>> import android.content.Intent;
>> import android.net.Uri;
>> import android.telephony.PhoneStateListener;
>> import android.telephony.TelephonyManager;
>> import android.test.ActivityInstrumentationTestCase;
>> import android.util.Log;
>> import android.view.KeyEvent;
>> import android.app.Instrumentation;
>> import android.view.View;
>> import android.content.IntentFilter;
>> import android.app.Instrumentation.ActivityResult;
>> import android.app.KeyguardManager;
>>
>> public class InstTest extends
>> ActivityInstrumentationTestCase
>> {
>>   private static final String LOG_TAG= "InstTest";
>>   private TelephonyManagertelMgr;
>>   private Instrumentation instrumentation;
>>   private Context context;
>>   private KeyguardManager keyguardMgr;
>>
>>   public InstTest()
>>   {
>>  super("test.instTest", EmptyActivity.class);
>>   }
>>
>>   public void testPreconditions()
>>   {
>>  instrumentation = getInstrumentation();
>>  assertTrue("Instrumentation must be non-null", instrumentation !
>> = null);
>>  context = instrumentation.getContext();
>>  assertTrue("Context must be non-null", context != null);
>>  telMgr = (TelephonyManager) context.getSystemService
>> (Context.TELEPHONY_SERVICE);
>>  assertTrue("TelephonyManager must be non-null", telMgr != null);
>>  keyguardMgr = (KeyguardManager) context.getSystemService
>> (Context.KEYGUARD_SERVICE);
>>  assertTrue("KeyguardManager must be non-null", keyguardMgr !=
>> null);
>>   }
>>
>>   public void testCall()
>>   {
>>  testPreconditions();
>>
>>  Log.i(LOG_TAG, "before inKeyguardRestrictedInputMode() ? " +
>> keyguardMgr.inKeyguardRestrictedInputMode());
>>
>>  KeyguardManager.KeyguardLock keyguardLock =
>> keyguardMgr.newKeyguardLock(LOG_TAG);
>>  keyguardLock.disableKeyguard();
>>
>>  Log.i(LOG_TAG, "after inKeyguardRestrictedInputMode() ? " +
>> keyguardMgr.inKeyguardRestrictedInputMode());
>>
>>  IntentFilter intentFilter = new IntentFilter
>> (Intent.ACTION_CALL);
>>
>>  Uri parsedPhoneNumber = Uri.parse("tel:1234567");
>>
>>  Intent myIntent = new Intent(Intent.ACTION_CALL,
>> parsedPhoneNumber);
>>  Intent resultData = new Intent(Intent.ACTION_CALL,
>> parsedPhoneNumber);
>>  // myIntent = new Intent(Intent.ACTION_DIAL, parsedPhoneNumber);
>>
>>  myIntent.setFlags(Intent.FLAG_DEBUG_LOG_RESOLUTION |
>> Intent.FLAG_FROM_BACKGROUND
>>| Intent.FLAG_ACTIVITY_SINGLE_TOP |
>> Intent.FLAG_ACTIVITY_NEW_TASK);
>>  resultData.setFlags(Intent.FLAG_DEBUG_LOG_RESOLUTION |
>> Intent.FLAG_FROM_BACKGROUND
>>| Intent.FLAG_ACTIVITY_SINGLE_TOP |
>> Intent.FLAG_ACTIVITY_NEW_TASK);
>>
>>  Instrumentation.ActivityResult actResult = new
>> Instrumentation.ActivityResult(Activity.RESULT_OK, resultData);
>>
>>  Instrumentation.ActivityMonitor actMonitor = new
>> Instrumentation.ActivityMonitor(intentFilter, actResult, false);
>>
>>  Log.i(LOG_TAG, "starting call.");
>>
>>  instrumentation.waitForIdleSync();
>>
>>  context.startActivity(myIntent);
>>
>>  instrumentation.waitForIdleSync();
>>
>>  Log.i(LOG_TAG, "number of hits from ActivityMonitor: " +
>> actMonitor.getHits());
>>  Activity phoneActivity = actMonitor.getLastActivity();
>>  if (phoneActivity != null)
>>

[android-developers] Re: Help me to test APK file on your real device

2008-11-22 Thread Dorn Hetzel

I suppose you could also upload it to the marketplace under maybe the
Demo category and name it TestMePlease :)

On Sat, Nov 22, 2008 at 1:22 AM, Peter <[EMAIL PROTECTED]> wrote:
>
> Hi Ulziisaikhan,
>
> There's a (fairly) new service that enables developers to test their
> mobile application on a real device by a variety of different testers:
>
> http://www.testarmy.com/
>
> If you can't obtain (or afford) a real Android device then this could
> be a cheap option.
>
> Regards,
> Peter
>
> On Oct 10, 8:44 pm, Ulzii <[EMAIL PROTECTED]> wrote:
>> Hi All,
>>
>> I have finished an application for the Android platform device.
>>
>> I am writing from Ulaanbaatar, Mongolia. It means there is no
>> possibility to test apk file on real android gPhone device.
>>
>> Is there anyone who obtained gPhone, could you help me to test my APK
>> file on your device.
>>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Eclipse repo is down?

2008-11-22 Thread Dorn Hetzel

Try http instead of https

On Sat, Nov 22, 2008 at 3:33 AM, Bogomil Shopov
<[EMAIL PROTECTED]> wrote:
>
> Hi all,
> There is no Eclipse repo available here:
> https://dl-ssl.google.com/android/eclipse/
>
>
> Bogo
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: PackageManager??

2008-11-21 Thread Dorn Hetzel
If PackageManager has to do the installation, can PackageManager be
launch from another application and passed information to help it
locate the desired application?

2008/11/21 Dianne Hackborn <[EMAIL PROTECTED]>:
> Current this API is not planned to be available to third party apps, they
> will need to go through the system installer UI.
>
> 2008/11/21 teo2706 <[EMAIL PROTECTED]>
>>
>> Will PackageManager.installPackage() be available for applications in
>> future versions? Ot will it be possible to install applications only
>> through Package Installer application, as you suggested below in this
>> thread?
>>
>> On 26 Авг, 09:36, hackbod <[EMAIL PROTECTED]> wrote:
>> > This is not available to applications, sorry.
>> >
>> > On Aug 26, 12:25 am, Wesley Sagittarius <[EMAIL PROTECTED]> wrote:
>> >
>> > > hi,
>> >
>> > > Does anyone successful use the PackageManager  to install apk???
>> >
>> > > wesley.
>>
>>
>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Is there a hook to run code on device shutdown (power off)?

2008-11-21 Thread Dorn Hetzel

And at least with respect to the current hardware instance (G1) is any
inability a hardware, firmware, or software limitation?

On Fri, Nov 21, 2008 at 9:39 AM, Eric Mill <[EMAIL PROTECTED]> wrote:
>
> Dianne, do you think this will be added to the API in the future?
> Saving state on phone shutdown could be important for some apps.
>
> -- Eric
>
> On Nov 20, 9:12 pm, Jon Colverson <[EMAIL PROTECTED]> wrote:
>> Eek. That makes things a bit more difficult. Thank you for the quick
>> response, though!
>>
>> On Nov 20, 9:55 pm, "Dianne Hackborn" <[EMAIL PROTECTED]> wrote:
>>
>>
>>
>> > Sorry, there is nothing available to find out when the device is being
>> > turned off.
>>
>> > On Thu, Nov 20, 2008 at 5:37 AM, Jon Colverson <[EMAIL PROTECTED]> wrote:
>>
>> > > Hello.
>>
>> > > Part of the app I'm writing is a Service that does some work. If it
>> > > hasn't finished when the user switches the device off I'd like to be
>> > > able to save my state to a file and then restart the Service when the
>> > > device starts up again.
>>
>> > > I can see how to start it up again (receive the ACTION_BOOT_COMPLETED
>> > > Intent), but I can't figure out a way to run the saving code on
>> > > shutdown. I was expecting my Service's onDestroy() to be called, but
>> > > this doesn't seem to be the case.
>>
>> > > Thanks.
>>
>> > > --
>> > > Jon
>>
>> > --
>> > Dianne Hackborn
>> > Android framework engineer
>> > [EMAIL PROTECTED]
>>
>> > Note: please don't send private questions to me, as I don't have time to
>> > provide private support.  All such questions should be posted on public
>> > forums, where I and others can see and answer them.
>>
>> --
>> Jon
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] detecting various buttons

2008-11-20 Thread Dorn Hetzel

Ok, so just to clarify, I guess I have been assuming (yeah, not good
to assume) that all of the buttons were "soft" buttons which generated
software events and then various applications acted on those events.
So are any of the buttons soft buttons?, and which
are hard buttons wired directly to things that can't be detected from code?

On Thu, Nov 20, 2008 at 6:28 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> No, sorry.
>
> On Thu, Nov 20, 2008 at 2:14 PM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>>
>> If not actual shutdown, is it possible to detect presses of the red
>> button that *might* result in a power down?
>>
>> On Thu, Nov 20, 2008 at 4:55 PM, Dianne Hackborn <[EMAIL PROTECTED]>
>> wrote:
>> > Sorry, there is nothing available to find out when the device is being
>> > turned off.
>> >
>> > On Thu, Nov 20, 2008 at 5:37 AM, Jon Colverson <[EMAIL PROTECTED]>
>> > wrote:
>> >>
>> >> Hello.
>> >>
>> >> Part of the app I'm writing is a Service that does some work. If it
>> >> hasn't finished when the user switches the device off I'd like to be
>> >> able to save my state to a file and then restart the Service when the
>> >> device starts up again.
>> >>
>> >> I can see how to start it up again (receive the ACTION_BOOT_COMPLETED
>> >> Intent), but I can't figure out a way to run the saving code on
>> >> shutdown. I was expecting my Service's onDestroy() to be called, but
>> >> this doesn't seem to be the case.
>> >>
>> >> Thanks.
>> >>
>> >> --
>> >> Jon
>> >>
>> >>
>> >
>> >
>> >
>> > --
>> > Dianne Hackborn
>> > Android framework engineer
>> > [EMAIL PROTECTED]
>> >
>> > Note: please don't send private questions to me, as I don't have time to
>> > provide private support.  All such questions should be posted on public
>> > forums, where I and others can see and answer them.
>> >
>> >
>> > >
>> >
>>
>>
>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Is there a hook to run code on device shutdown (power off)?

2008-11-20 Thread Dorn Hetzel

If not actual shutdown, is it possible to detect presses of the red
button that *might* result in a power down?

On Thu, Nov 20, 2008 at 4:55 PM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> Sorry, there is nothing available to find out when the device is being
> turned off.
>
> On Thu, Nov 20, 2008 at 5:37 AM, Jon Colverson <[EMAIL PROTECTED]> wrote:
>>
>> Hello.
>>
>> Part of the app I'm writing is a Service that does some work. If it
>> hasn't finished when the user switches the device off I'd like to be
>> able to save my state to a file and then restart the Service when the
>> device starts up again.
>>
>> I can see how to start it up again (receive the ACTION_BOOT_COMPLETED
>> Intent), but I can't figure out a way to run the saving code on
>> shutdown. I was expecting my Service's onDestroy() to be called, but
>> this doesn't seem to be the case.
>>
>> Thanks.
>>
>> --
>> Jon
>>
>>
>
>
>
> --
> Dianne Hackborn
> Android framework engineer
> [EMAIL PROTECTED]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Android Market's "Publish" Button does nothing

2008-11-20 Thread Dorn Hetzel

I published a little do-nothing application just to work through the
process.  It took about an hour from the time I hit publish until my
G1 could see the app.

Then in five more minutes I got like ten one star reviews for my do
nothing app (and one five star :) ) and unpublished it :)

The downoad counter never did move off zero.

-Dorn

On Thu, Nov 20, 2008 at 4:25 PM, Michael <[EMAIL PROTECTED]> wrote:
>
> Any error message?
>
> This process has been working for lots of other people, including
> myself
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: missing javax audio?

2008-11-20 Thread Dorn Hetzel

Dan,

I must be overlooking something?  The only audio input method that I
can find documented there is MediaRecorder, and it seems to only know
how to send audio to a file.  Can you point a little more closely at
whatever method will allow collecting audio input to a memory buffer
and sending audio from a buffer to output?

Thanks!

-Dorn

On Thu, Nov 20, 2008 at 2:29 PM, Dan Bornstein <[EMAIL PROTECTED]> wrote:
>
> On Thu, Nov 20, 2008 at 11:24 AM, Dorn Hetzel <[EMAIL PROTECTED]> wrote:
>> "There already are Android-specific classes and methods for a lot of
>> audio-related functionality..."
>>
>> At least for my applications, which would be new code for the android
>> platform, not ports from somewhere else,
>> I don't care if it's javax.sound or whatever, as long as I can move
>> bits from mic-->memory and memory->speaker.
>>
>> Even with caveats about having to rewrite stuff later when things
>> change, I would still like to use any capabilities available today on
>> the G1 through the 1.0 SDK.  Can you provide any additional clues or
>> even documentation or examples of such interfaces to they extent
>> they exist in any useable form?
>
> The Android API for such stuff is in the android.media package. Find
> online docs for it here:
>
>
> <http://code.google.com/android/reference/android/media/package-summary.html>
>
> Warm regards,
>
> -dan
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: missing javax audio?

2008-11-20 Thread Dorn Hetzel

Dan,

"There already are Android-specific classes and methods for a lot of
audio-related functionality..."

At least for my applications, which would be new code for the android
platform, not ports from somewhere else,
I don't care if it's javax.sound or whatever, as long as I can move
bits from mic-->memory and memory->speaker.

Even with caveats about having to rewrite stuff later when things
change, I would still like to use any capabilities available today on
the G1 through the 1.0 SDK.  Can you provide any additional clues or
even documentation or examples of such interfaces to they extent
they exist in any useable form?

Regards,

Dorn Hetzel

On Thu, Nov 20, 2008 at 2:07 PM, Dan Bornstein <[EMAIL PROTECTED]> wrote:
>
> On Thu, Nov 20, 2008 at 6:10 AM, Robert Green <[EMAIL PROTECTED]> wrote:
>> That's very unfortunate.  iPhone has one up on the android in this
>> arena.
>
> There are two separate questions here, I think. One is about improved
> audio support. The other is about whether that support will come in
> the form of an implementation of the javax sampled sound API.
>
> We are absolutely committed to improving audio support. There already
> are Android-specific classes and methods for a lot of audio-related
> functionality, but we know full well that there is much more that
> could be done. You can safely expect to see us continue to improve the
> Android-specific API.
>
> We did have a go at implementing javax.sound for 1.0, but effectively
> due to time constraints, we were not able to bring that code up to
> production quality. So, rather than ship an "attractive nuisance" that
> would have caused developers pain, agony, and suffering, we decided
> instead that the platform API would be better off without it, for now.
> There is nothing that you could have done using the javax API, as
> implemented, that you couldn't have also done using the
> Android-specific API; the difference is more that porting pre-existing
> code would have been easier if the more standard API were in place
> (and if it worked as expected).
>
> You can find the javax.sound code, as it currently exists, in the open
> source tree at . When Dianne
> said...
>
>> Contributing patches would be a much more effective approach than a petition.
>
> ...the specific patches she presumably meant would be patches to make
> this as-yet incomplete code into a stable, usable, library.
>
> -dan
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: missing javax audio?

2008-11-20 Thread Dorn Hetzel

Dianne,

Give even a general description of what patches would help get this
lack of audio functionality dealt with in a way
that would be accepted for inclusion in the base, and I bet someone
will take up the challenge...

Regards,

Dorn Hetzel

On Thu, Nov 20, 2008 at 4:08 AM, Dianne Hackborn <[EMAIL PROTECTED]> wrote:
> On Wed, Nov 19, 2008 at 8:21 PM, Robert Green <[EMAIL PROTECTED]> wrote:
>>
>> I motion for a petition for full audio API in the 1.1 SDK.
>
> Contributing patches would be a much more effective approach than a
> petition.
>
> --
> Dianne Hackborn
> [EMAIL PROTECTED]
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: missing javax audio?

2008-11-20 Thread Dorn Hetzel

What mic->memory and memory->speaker method(s) *do* you plan to support?
Not to complain, android is wonderful, but mic->file and file->speaker
just won't work for many applications.

On Thu, Nov 20, 2008 at 1:26 AM, [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
>
> We have no plans to support the Javax multimedia classes at this time.
>
> On Nov 19, 8:21 pm, Robert Green <[EMAIL PROTECTED]> wrote:
>> I motion for a petition for full audio API in the 1.1 SDK.
>>
>> On Nov 19, 8:43 pm, E <[EMAIL PROTECTED]> wrote:
>>
>> > Hello,
>>
>> > Some months ago I began a project that involved some basic signal
>> > processing. I used the Java Sound API, including AudioInputStream to
>> > get linear bytes from a recording to do some simple analysis.
>>
>> > With the release of the 1.0 toolkit I picked the project up again, but
>> > the Javax audio classes are missing. Is there a replacement for these
>> > classes? What's the plan?
>>
>> > Apparently there are other API's that got pulled?
>> > I was able to get my code to compile by pulling them out of a full
>> > java distro and adding them to my project, but as noted elsewhere,
>> > this won't actually run on the device.
>>
>> > Thanks,
>>
>> >   -Ethan
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Quality of audio recording from MediaRecorder

2008-11-20 Thread Dorn Hetzel

I would really love a clue here as well, MediaRecorder is completely
unworkable for my application, so it's either use the native interface
or wait for another release, which I would rather not do...

On Thu, Nov 20, 2008 at 7:18 AM, GnuHash <[EMAIL PROTECTED]> wrote:
>
> wrt the native interface:
>
> is it AudioSetInputFormat,AudioOpen, AudioRead etc?
>
> -GnuHash
>
> On Nov 20, 12:14 am, "[EMAIL PROTECTED]"
> <[EMAIL PROTECTED]> wrote:
>> It is the only supported method in SDK 1.0. There is a native
>> interface to audio input, but it will be changing in a future release
>> and I strongly advise against using it.
>>
>> On Nov 19, 8:26 am, dorn <[EMAIL PROTECTED]> wrote:
>>
>> > Is theMediaRecorderthe only method available to acquire audio from
>> > the microphone, or is there a lower level method available?
>>
>> > On Nov 14, 4:59 pm, Dave Sparks <[EMAIL PROTECTED]> wrote:
>>
>> > > TheMediaRecorderis currently hardcoded for AMR-NB and is intended
>> > > for MMS messages.
>>
>> > > You can expect improvements toaudiorecording in a future SDK.
>>
>> > > On Nov 14, 12:26 pm, ste <[EMAIL PROTECTED]> wrote:
>>
>> > > > I'm testing out theMediaRecorder'saudiorecording capability, and
>> > > > the quality of theaudiowas less then I was expecting. It was
>> > > > significantly lower then the quality you get while speaking on the
>> > > > phone, and sounded very digitized.
>> > > > I've tested both the 3gpp and MPEG_4 encoding options, and noticed the
>> > > > same quality.
>> > > > Has anyone else noticed this, and is this an issue with the phone's
>> > > > hardware or theMediaRecorder'scapabilities? If it's the latter, is
>> > > > the quality of recording something which is planned to be improved?
>>
>>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] gathering audio in "streaming" mode

2008-11-19 Thread Dorn Hetzel

I would my application to start gathering audio from the microphone
and get it passed to me continuously until I ask for it to stop.

What interface would be best for this?  Can I get called back when
audio is available, and if so, in what time chunk sizes, or
do I have to check for it to see if any is available?

Thanks!

-Dorn

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] test, my apologies, please ignore

2008-11-19 Thread Dorn Hetzel

test, my apologies, please ignore, having some trouble posting earlier

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---