yashsingh1/xdaforums huggingface dataset:
[Windows Phone 7 Software Development] otherworld:
You just have to check for errors in two places (and you're currently only checking in one) - it would be nice if the error event handled everything but unfortunately it can't; e.g. take the 'InvalidOperationException ' case of no channels being left on the device (quota exceeded), if there's no channel ever created in the first place then there's nothing to assign the error event to anyway; hence why you need to check both on initialisation (with the try catch around the open - see above), and once you've set it going (with the error event).

In your error event you can check what the problem is using a nice enum:

switch (e.ErrorType)

{

case ChannelErrorType.ChannelOpenFailed:

break;

case ChannelErrorType.MessageBadContent:

break;

case ChannelErrorType.NotificationRateTooHigh:

break;

case ChannelErrorType.PayloadFormatError:

break;

case ChannelErrorType.PowerLevelChanged:

// 0 is normal, 1 is low, 2 is critical

if (e.ErrorAdditionalData == (int)ChannelPowerLevel.LowPowerLevel || e.ErrorAdditionalData == (int)ChannelPowerLevel.CriticalLowPowerLevel)

// note a value of 0 here is not an error

break;

}

Ian
[Windows Phone 7 Software Development] sunxin8086:
Thanks Ian for the explanation. I got this part, however, what still puzzles me is why the InvalidOperationException got captured in the categories_LoadCompleted method. shouldn't this method only called from within the odata class? Is this a feature of .net or a bug??
[Windows Phone 7 Software Development] otherworld:
I agree it doesn't seem to make sense :eek: You have no try catch, yet the exception is seemingly being bubbled up a level and then contained somehow within your categories_LoadCompleted method.

The reason is found by decompiling the DataServiceCollection class. Here's part of what happens when you call LoadAsync - notice that when an error occurs (i.e. the push channel exception) your completed event is actually being called

a second time

(as it is contained in the bolded try catch below), and this time it contains the new InvalidOperationException. Obviously you'll need to code around this behaviour. You'll probably be fine knowing that, but is there a way you can keep the code in the completed method just for completion of loading categories (and subscribe to push, load messages, etc. elsewhere)? It might be good to do that just to help avoid encountering the same confusing situation elsewhere.

Hope that helps!

Ian

private void BeginLoadAsyncOperation(Func<AsyncCallback, IAsyncResult> beginCall, Func<IAsyncResult, QueryOperationResponse> endCall)
{
this.asyncOperationInProgress = true;
try
{
beginCall.Invoke(delegate(IAsyncResult ar)
{
Deployment.get_Current().get_Dispatcher().BeginInvoke(delegate
{
try
{
QueryOperationResponse queryOperationResponse = endCall.Invoke(ar);
this.asyncOperationInProgress = false;
if (this.LoadCompleted != null)
{
this.LoadCompleted.Invoke(this, new LoadCompletedEventArgs(queryOperationResponse, null));
}
}
[B]catch (Exception error)
{
this.asyncOperationInProgress = false;
if (this.LoadCompleted != null)
{
this.LoadCompleted.Invoke(this, new LoadCompletedEventArgs(null, error));
}
}[/B]
}
);
}
);
}
catch (Exception)
{
this.asyncOperationInProgress = false;
throw;
}
}
[Windows Phone 7 Software Development] sunxin8086:
You are the man. Yeah, I plan to keep the loadCompleted method clean, so I will try to catch the exception in the subscribeToPush method. Thank you so much for all your help. Couldn't do it without you.
[Windows Phone 7 Software Development] sunxin8086:
Hi, Ian,

Hope you can see this. I pushed out an update with the error reporting for my app two days ago. The version was pushed before I realized the error has something to do with Push Channel failed to open. However, from the user report, I found another rather interesting and confusing error.

Query URL: /Messages?$filter=Hidden eq 0 and Version eq 1,5 and ID gt 0

Outer Exception Message:

An error occurred while processing this request.

Inner Exception Message:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>

<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

<code></code>

<message xml:lang="en-US">Syntax error at position 29.</message>

</error>

At first, its kinda shocking to me that why my Version was transformed to "1,5", instead of "1.5"(comma instead of period). After googling it, I found it has something to do with CultureInfo. Wow, I would never thought about this, if I don't get an error report. Supporting multi-region is a lot tougher than I thought.
[Windows Phone 7 Software Development] otherworld:
You have to be careful anywhere you use dates, doubles, etc. as string.format (or most string methods) format them according to regional settings of the user - so unless you specify otherwise a user in Germany will see 1,5 whereas a UK user will see 1.5. This is a good thing usually as people get to see numbers and dates in the format they're used to.

You can get round it (when you need to have it a specific way e.g. for your query) using the InvariantCulture (which tells it to not use the current region's settings). E.g. for your versionid:

string.Format(CultureInfo.InvariantCulture.NumberFormat, "{0:0.0}", VersionID);

Will always (off the top of my head - make sure you test it) output using a decimal point rather than a comma.

A simpler way for you might be just to store the version ID as a string in the first place if that doesn't affect anything.

You can test all this in the emulator by e.g. changing the country to Germany and seeing if everything still works.
[Windows Phone 7 Software Development] otherworld:
Worth knowing too is XAML doesn't follow this convention (!) - when you use data binding in xaml it will always apply the "en-US" formatting to a DateTime or a Double etc. This is really important to know if you're displaying dates as you'll confuse a lot of users if you don't handle it. I avoid binding directly to dates for this reason - I pre-format them myself in code and then bind to the resultant string representation.

Microsoft obviously don't think consistency is important ;)
[Windows Phone 7 Software Development] sunxin8086:
And whats even worse is, I think Nodo and Mango have different error messages, which makes even harder to handle.
[Windows Phone 7 Q&A, Help & Troubleshooting] sunxin8086:
Hi,

I am experiencing a serious problem. I recently released an updated on my app "Funny Jokes" from modern creation. The update is meant to enhance the user experience by adding a few new cool features. However, since the update, there are a small number of users experiencing "Initialization Failure" when starting the app. According to my code, this error only happens when the internet connection is spotty. However, the users report that they have perfect good 3g or wifi. I have no idea what causes this error since it works perfectly fine on my own phone, the simulator and a few friends who have installed my app. However, since angry customers tend to leave reviews, the reviews since the update have been mostly negative. Its really hurting my app. Is there any way that Microsoft can help me debug this problem? since I don't have all the devices on all different carriers? I really don't know what to do at the moment.

Also can some of the developers help me on this problem? I am here attaching the xap file, will you please let me know if the app works on your phone and if it doesn't, can you please let me know what device you use, your carrier, and country. Thanks very much.
[Dell Streak 7] Herk718:
Quick questions... Why is dj_steve thread closed?? And why did his development status go from recognized developer to senior member??? Is this thee end of honeystreak development?? :(
[Dell Streak 7] otnos:
Read his thread in the ds7 general section.
[Dell Streak 7] Donmotobike:
DJ steve was upset because super moderators of xda demanded that he reveals his kernel source.....I don't think that's even his to reveal since he mentioned that it came from one of his buddies so I guess XDA moderators put a lock on all of his honeystreak thread due to strick rules gpl and open source guidelines on all developers...I understand why XDA strict to their rules since they are actually protecting us from possible virus or malware - who know anyone can say this is my kernel etc etc - how can you really trust someone to offer you operating system?? really nothing is free in this world...
[Dell Streak 7] pyraxiate:
/epic fail

And yet I bet you are using one of his Roms ............ or at least installed one at some point seeing as you answer rom specific questions in other posts........

/ end epic fail
[Dell Streak 7] Watcher64:
haha, it even says in his sig ...

"Dell Streak 7 Honeystreak RC 2"

OHHH NOOO but don't trust him!!!
[Dell Streak 7] Watcher64:
Just gotta say, this "source code" GPL stuff , and saying only to trust people who give out source code (if it even exists), is TOTAL BULL, how many of you , MODs, users and other people are using a modified, .apk, or a modified binary?

Do you have the source code for those???? I bet you don't , do you take the time to de-compile them to see if they are "trusted", not you just install the damn thing and use it, and if it is bad you find out later then fix it ...
[Dell Streak 7] Donmotobike:
devils advocate

im just sayin why the mod closed his thread just theory doesnt mean i support it duh:rolleyes:

Honeystreak awesome dj steve where ever you are u da man....peaceout:rolleyes::rolleyes::rolleyes::rolleyes::rolleyes::rolleyes::rolleyes::rolleyes::rolleyes:
[Dell Streak 7] Watcher64:
Well in that case, ooops, sorry ...

But the other points still stand versus the MODs
[Dell Streak 7] lufc:
Questions or Problems Should Not Be Posted in the Development Forum

Please Post in the Correct Forums and Read THIS

Moving to General

PLUS

His thread was closed because he would not produce the Kernal as per GPL Rules that xda have to abide by.
[Motorola Droid X2] madflava54:
I just got the X2 and it's been running fine for me. It seems with the Tegra 2, this phone would possibly be able to handle Android 4.0 whenever it comes out. With the lack of development, what are the chances that the X2 will just ride with GB until its death? I like so far how the phone is working well out of the box, but in 1-1.75 years when the phone shows its age, I would like to mod it here and there to get some more life out of it.
[Motorola Droid X2] Mandelbrot.Benoit:
No phone is future proof. The Tegra3 is around the croner for tablets, and phones wont be that far behind. I would bet 4g phones get the Tegra3, so if 4g is a negative for a select crowd, the DX2 may be the last great 3g phone. It will be interesting to see if they continue supporting a high-end 3g line.

I would imagine ICS would run fine on OG DX much less DX2. I would say there is a small, but possible chance a stock DX2 would die on GB. But the dev will bring it regardless.

Edit: And at this point I am 100% satisfied with everything I have flashed on DX2. What did DX have? Liberty and Apex. And yes a good bit of themes. But the devs here have a ton of scripts I never saw on DX and the themes have been coming fast, and are of good quality. The eclipse ROM has branched to AOSP, so both crowds should be happy. I personally stuck with 2.2 and couldnt be happier.

Jrummy can choke on his Charge :-P
[Motorola Droid X2] madflava54:
That's good to hear. ICS seems like it's going to be a new experience and I would hate to miss out on it. I'm a "noob" and so I can't demand things and my understanding is limited, but the bootlock seems to be restricting development :(
[Motorola Droid X2] ilovesoad:
I seriously doubt that we get an official update to ics.
[Motorola Droid X2] Kanibull:
Lol so negative. What makes you think we wont? Motorola is actually decent with updates. Hell the og dx got gingerbread before we did so I doubt they will just totally forget about us.
[Motorola Droid X2] Zeravnos:
Not to mention that Google bought Moto recently. I think we will indeed get ICS.
[Motorola Droid X2] madflava54:
Let's hope so! There is a game called "We Rule" that doesn't work on the X2 yet :( but on the X1! BOOO
[G2 and Desire Z General] bombadier:
Hi all first time I've had this problem, the phone is connected and works but the symbol telling me its connected is not showing up,made a theme from UOT Kitchen which I have done several times before without any problems, but since pushing this over,my symbols are gone?

Any ideas as to where they are hiding?
[G2 and Desire Z General] martonikaj:
You probably got a bad flash of a .zip or a bad framework-res.apk that accidentally overwrote the images. This will happen sometimes when flashing mods.
[G2 and Desire Z General] bombadier:
Its ok turns out the problem was with flashing an old kernel,

Sent from a htc desire z
[Desire HD Q&A, Help & Troubleshooting] b1rken:
Newly flashed rom, charged it full, and recalibrated battery.

only 6% battery drain while sleeping

But when im using it, it could use 1% battery after 5 minutes, but then suddely the next minute it has dropped 2-3%.

Sometimes it holds the battery, but then suddely it drops like crazy.

I havent let the battery die after recalibration, but i thought that after resetting the battery stats it should be more linear battery drain when im doing the exact same operation the whole time, so i guess it would drain the same amount of battery, not being that jumpy :(
[Desire HD Q&A, Help & Troubleshooting] DDFF:
using Current widget or battery monitor to observe how many mA it consume every one or five minutes? average 2-10mA is normal
[Galaxy S I9000 Q&A, Help & Troubleshooting] lior1262:
Hello everyone

How do I remove the logo of my company operates

I want to delete this picture and put something else (Original)

Is that possible?

I have a rom 2.2 (with root).

odexed
[Galaxy S I9000 Q&A, Help & Troubleshooting] lior1262:
up up i need help
[Galaxy S I9000 Q&A, Help & Troubleshooting] petulikt:
ehm complicated, but try this dialer, flash it through recovery
[Galaxy S I9000 Q&A, Help & Troubleshooting] lior1262:
thanks my rom is stock rom -odexed.

what to so?
[Milestone XT720 Android Development] Mioze7Ae:
Here are baseband updates created for the Milestone XT720 from the various sbf's I've collected:

Canada-Wind STR_U2_05.1F.2_GAS_NA_NAWIND_P012 (s7icky's nandroid--no known sbf)
CentralEurope STR_U2_01.1E.0_GAS_EMEA_UCASHOTBRTLRTCEE_P001
France STR_U2_02.1E.0_GAS_EMEA_UCASHOTBRTLRTFR_P018
GreatBritain STR_U2_01.1E.0_GAS_EMEA_UCASHOTBRTLRTGB_P021
Italy STR_U2_02.1E.0_GAS_EMEA_USASHOTBRTLRTIT_P001
Korea STSKT_N_79.33.50R/GAS_ASIA_SHOTSKT_P006/GAS_ASIA_SHOTSKT_P006
Russia STR_U2_03.20.1_GAS_ASIA_USASHLSTBRTRU_P012
Singapore STR_U2_01.1E.2_GAS_ASIA_USASHLSTBSTARSG_P019
US-BrightPoint STR_U2_04.1E.1_GAS_NA_NAREG_P011
US-CincinnatiBell STR_U2_04.1E.1_GAS_NA_NACBW_P011

I also included a baseband update built from the baseband files in Dexter's 1.3.

The forum only allows 8 attachements/post so this will continue into the next post. At this point only US-CincinnatiBell has been tested, so making a nandroid of /system is recommended in case the update rains on your parade.

To apply:

Place in /sdcard/OpenRecovery/updates

OR > Apply Update > select baseband

Reboot

Thanks: easye420 for original 3G_UPDATE_XT720.zip, dexter, s7icky
[Milestone XT720 Android Development] Mioze7Ae:
Additional baseband updates

Additional baseband update attachments
[Milestone XT720 Android Development] S7icky:
K back to my nubcakeness... What does this do lol?

Will it fix all my SMS issues :P
[Milestone XT720 Android Development] Mioze7Ae:
Well, I don't completely understand the baseband, but my understanding is these files configure the software that runs on the cellular radio chip (i.e. what frequencies to use for 3G etc) and I think they also configure the emergency numbers. I'm not entirely sure what the libril-moto-umts-1.so does but Dexter included it in some of the A853 basebands and it seems to have something to do with communicating with either the GSM network or the GSM hardware. Different regions did seem to have different libril's but I don't know if that's just because of newer builds or what. Wind's was different from the other North America ones. Incidentally Canada seems to have the newest kernel by compile date: August 16 and you're at build level 1F (although Russia is at 20). Too bad we don't have an sbf...

I don't know if it will fix your SMS issues. For me, it seems to have fixed a serious power drain that I was experiencing on an unreleased CM6.3 build.
[Milestone XT720 Android Development] S7icky:
Hmm ok.. I might have to try to flash over to XDA special RC2 and apply that and see if it helps :P I will report back my findings :)

Im tryin to get the SBF from wind lol. Ive been fighting with them for weeks about it. I keep telling them to give me the SBF so i dont have to come in and ***** at them. But i doubt ill ever get it.
[Milestone XT720 Android Development] peshovec:
as i suspect some problems with my phone (because of existence of /data/panic/ files such as:

/data/panic/bp_panic.log1
....

/data/panic/apr/bp_panic.bin1
.....

which trigger this condition:

service panic_daemon /system/usr/bin/panic_daemon
class post-zygote_services
user radio
group radio system graphics
socket panic_daemon stream 660 radio radio
onrestart exec /system/bin/reboot

)

i ran some brief comparing...

895da6b53f1b005b7d8ebbb15974c17c ./wind/system/lib/libril-moto-umts-1.so
bf581b2d7402d3e056541da28bf67911 ./fr/system/lib/libril-moto-umts-1.so
bf581b2d7402d3e056541da28bf67911 ./sing/system/lib/libril-moto-umts-1.so
bf581b2d7402d3e056541da28bf67911 ./cinc/system/lib/libril-moto-umts-1.so
bf581b2d7402d3e056541da28bf67911 ./uk/system/lib/libril-moto-umts-1.so
bf581b2d7402d3e056541da28bf67911 ./europe/system/lib/libril-moto-umts-1.so

75ed5c1f82fae52ba442a47da6d1d6ac ./wind/system/etc/motorola/bp_nvm_default/File_GSM
6594b74800259b2625c6717c7ccf218e ./fr/system/etc/motorola/bp_nvm_default/File_GSM
6594b74800259b2625c6717c7ccf218e ./sing/system/etc/motorola/bp_nvm_default/File_GSM
1d1a6b8099e0b715041b8094d3c81496 ./cinc/system/etc/motorola/bp_nvm_default/File_GSM
6594b74800259b2625c6717c7ccf218e ./uk/system/etc/motorola/bp_nvm_default/File_GSM
6594b74800259b2625c6717c7ccf218e ./europe/system/etc/motorola/bp_nvm_default/File_GSM

6a1547ec8290b20bacdd51b8b9246365 ./wind/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables
cafc920346704769b25b3cb01e9114fb ./fr/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables
cafc920346704769b25b3cb01e9114fb ./sing/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables
2a9c4db6e3062ff0c4eb9267762f8bc7 ./cinc/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables
cafc920346704769b25b3cb01e9114fb ./uk/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables
cafc920346704769b25b3cb01e9114fb ./europe/system/etc/motorola/bp_nvm_default/File_Seem_Flex_Tables

and just want to share my 2 cents...

there is directory /data/bp_nvm

it is pretty much like the /system/etc/motorola/bp_nvm_default

which is normal, because the /data/bp_nvm is generated on the phone, based on the "default" directory...

but

some of the files are different. I cannot check at the moment which , but i am pretty sure for the File_GSM one.

actually as our phones are 4 bands, i think the baseband topic is may be overreacted.

as i look at the comparision may be except wind (which is very different from the others).

but anyway when changing the baseband may be it will be good idea to delete the /data/bp_nvm (so to make sure it will be regenerated)

I am not sure, why the /data/bp_nvm exists. May be they are some "compiled" configuration or settings in the files. may be the files in /data/bp_nvm are "self recovering" from something... but it will be very interesting to compare them too (may be at 2 stages, 1st just after regenerating them, and 2nd after some time....)
[Milestone XT720 Android Development] Mioze7Ae:
I was wondering that, too. My current guess is that the bp_nvm_default is the initial /data/bp_nvm (or perhaps the version that gets used when a carrier can't be connected) but that it can probably be updated by the network and that may be what's in /data/bp_nvm. That's a good idea to keep an eye on them... I'll do that too.

I can't quite figure out Dexter's version. It seems to merge a bunch of them, but I don't know if that was intentional or if he just copied files there without deleting the old versions. Dexter seems to know a lot about basebands (he created the A853 ones), so that's why I also made his version.
[Milestone XT720 Android Development] Lienaj:
Would any work for Motoroi?
[Milestone XT720 Android Development] S7icky:
It did fix my SMS issue i think.... so far im getting txts from the people i wasn't before WOOT

Thank YOU!!!!!!!
[Milestone XT720 Android Development] molohov:
I would like to know if you do get a hold of it. I will try my hand at acquiring a copy too, I know some people who work at WIND.

On a side note, my memory recalls that the WIND SBF kernel undervolted the phone slightly compared to the Brightpoint SBF that I later flashed (and am still using). It would be cool to compare...again if we get a hold of it.
[Milestone XT720 Android Development] S7icky:
Yea one of the chicks i talk to works there :P And a buddy in t.dot works in there support

But the baseband dident fix it :(
[Milestone XT720 Android Development] AA1973:
For Germany I just flashed the Central Europe version. At the first reboot emergency calls only, after second reboot everything is fine.

MilestoneXT720 - CM 6.3.0 by MZ
[Milestone XT720 Android Development] peshovec:
can repeat the steps again?

may be the files at / data/bp_nvm are generated then......

if you are able to compare then inside openrecovery before and after will be nice
[Milestone XT720 Android Development] Woody:
Will this help signal strength or is it more-so a 3g fix? My wife and I can sit right next to each other and she'll get a signal and I will barely be able to 1edge bar.

Same phone, but hers is stock 2.1 with app2sd whereas mine is more like a Franken-Rom.
[Milestone XT720 Android Development] Mioze7Ae:
I think it might. My signal seems stronger, but unfortunately I didn't pay close attention except for the power drain. Low signal and power drain probably go hand in hand, but that's just speculation because I didn't measure it.
[Milestone XT720 Android Development] Woody:
Ok, I'll give it a whirl when I get home. If I wanted to check and see if it gets stronger, how should I do that, obviously other than bars.

Also is this a one time thing and it'll just carry through my backups or will it have to be re-updated with each "fresh" ROM test?
[Milestone XT720 Android Development] Mioze7Ae:
It changes files on /system, so you'll have to do it each time you install a new ROM or flash a nandroid that doesn't have the baseband update installed. Stay tuned.
[Milestone XT720 Android Development] Woody:
I figured as much but someone had to ask. Next are you going to tell me to wear a tin foil coned hat on my head, face north on one foot and turn counter-clockwise?

I'll check stregth before and after and post later on tonight or tomorrow.
[Milestone XT720 Android Development] Mioze7Ae:
The stay tuned part was just because the new recovery with the basebands built-in was on the way out the door. ;)
[Milestone XT720 Android Development] Mioze7Ae:
Maybe. I think there's a very good chance, but I can't test it. These baseband updates only change files in /system so if you make a nandroid of system before you apply it, you should be able to undo it.

Or are you asking for a Korean baseband update? I forgot that one.

Edit: added a baseband update based on the Korean 50R to the second post.
[Milestone XT720 Android Development] eejin2:
I havent got any problems with my network on all the roms I've flashed... and there was once o flashed a Singapore sbf but it didn't look like how it did when I first bought my phone so I'm not sure about the baseband. Lol
[Milestone XT720 Android Development] Mioze7Ae:
"If it ain't broke don't fix it." is almost always pretty good advice.