Wednesday, September 25, 2013

[General] How can I upgrade from Gingerbread 2.3.6 to Jelly Bean 4.3 on LG Optimus p936 true hd lte?


How can I upgrade from Gingerbread 2.3.6 to Jelly Bean 4.3 on LG Optimus p936 true hd lte?



Hello, I've recently bought LG Optimus P936 and it comes with Gingerbread 2.3.6 and it seems it can't be updated via "software update". This phone seems to have quite strong hardware so I wanted to upgrade Android to newer version. Is there any way I can do this?



Read more

forum.xda-developers.com



[General] Texting over wifi with my number (recent convert from the iphone)


Texting over wifi with my number (recent convert from the iphone)



I just moved over from the iphone, one of the things I miss is imessenger. Mainly because I get almost no signal and it can send out most texts through my wifi connection. I want to be able to use my number and I don't want to have to have all my friend install a special app. But I don't mind paying a few dollars for the app or a even a small monthly fee.

Thanks



Read more

forum.xda-developers.com



[General] stuck at Android 4.1.1


stuck at Android 4.1.1



For xmas last year i got an ipad 2 and loved it!! but it fell off my car last year sna smashed, so this past xmas my dad got me a samsung galaxy tab 2 10.1

I have been loving it so far to this date but as i just realized the android device will not update to android 4.2 or 4.3.It says is updated to as far as it can and i keep hitting the button but it keeps saying " the latest updates havwe already been installed!!

how do i go about fixing this



Read more

forum.xda-developers.com



[General] Need a Gmail Account Made in USA


Need a Gmail Account Made in USA



Hi Guys, I need a gmail account created in USA to add it to my phone for using Google Play Music as it is not available in my Country. I know that is kind of weird asking you guys to create a account for me but I need one. If some generous American Friend can help me out with this, I will be very thankful to him. I will provide you my details



Read more

forum.xda-developers.com



[General] Can't install apps on my Huawei Andriod phone?


Can't install apps on my Huawei Andriod phone?



Welcome to Android Central! Are you sure the setting you changed allows you to install apps on the removable SD, or the internal SD (aka Internal Storage)? Android phones generally don't let you install to the removable SD card unless you're rooted, or running an earlier version (can't remember if Gingerbread allows this).



Read more

forum.xda-developers.com



[General] rply


rply


Copyright 2013 Mobile Nations ● Terms and ConditionsPrivacy Policy

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License. AndroidCentral is an independent site that is not affiliated with or endorsed by Google.



Read more

forum.xda-developers.com



[android help] Crash in location program


Crash in location program



Make application according to the tutorial in the book, but have some error which crashed my program in unknown place: logCat don't gave error message So code of my location class`:



import android.app.Activity;
import android.content.Context;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.widget.TextView;

public class MainActivity extends Activity {

private LocationManager myLocationManager;
private LocationListener myLocationListener;
private TextView myLatitude, myLongitude;


@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);

setContentView(R.layout.activity_main);

myLatitude = (TextView)findViewById(R.id.textView1);
myLongitude = (TextView)findViewById(R.id.textView2);



myLocationManager = (LocationManager)getSystemService(
Context.LOCATION_SERVICE);

myLocationListener = new MyLocationListener();

myLocationManager.requestLocationUpdates(
LocationManager.GPS_PROVIDER,
0,
0,
myLocationListener);

//Get the current location in start-up
myLatitude.setText(String.valueOf(
myLocationManager.getLastKnownLocation(
LocationManager.GPS_PROVIDER).getLatitude()));

myLongitude.setText(String.valueOf(
myLocationManager.getLastKnownLocation(
LocationManager.GPS_PROVIDER).getLongitude()));
}

private class MyLocationListener implements LocationListener{

public void onLocationChanged(Location argLocation) {
// TODO Auto-generated method stub
myLatitude.setText(String.valueOf(
argLocation.getLatitude()));
myLongitude.setText(String.valueOf(
argLocation.getLongitude()));
}

public void onProviderDisabled(String provider) {
// TODO Auto-generated method stub
}

public void onProviderEnabled(String provider) {
// TODO Auto-generated method stub
}

public void onStatusChanged(String provider,
int status, Bundle extras) {
// TODO Auto-generated method stub
}
};
}


I'm add next permission to MAnifest file: After starting application on my Galaxy TAb i have crash but after few second in a toolbar splashing icon "GPS" code from debuger(if helps)



DalvikVM[localhost:8624]
Thread [<1> main] (Suspended (exception RuntimeException))

ActivityThread.performLaunchActivity(ActivityThread$ActivityRecord, Intent) line: 2663
ActivityThread.handleLaunchActivity(ActivityThread$ActivityRecord, Intent) line: 2679
ActivityThread.access$2300(ActivityThread, ActivityThread$ActivityRecord, Intent) line: 125
ActivityThread$H.handleMessage(Message) line: 2033
ActivityThread$H(Handler).dispatchMessage(Message) line: 99
Looper.loop() line: 123
ActivityThread.main(String[]) line: 4627
Method.invokeNative(Object, Object[], Class, Class[], Class, int, boolean) line: not available [native method]
Method.invoke(Object, Object...) line: 521
ZygoteInit$MethodAndArgsCaller.run() line: 868
ZygoteInit.main(String[]) line: 626
NativeStart.main(String[]) line: not available [native method]
Thread [<6> Binder Thread #2] (Running)
Thread [<5> Binder Thread #1] (Running)


Read more

stackoverflow.comm



[android help] Setting progressbar's progressDrawable


Setting progressbar's progressDrawable



Im trying to create a custom progressbar. Im trying to only make half of the progressbar filled with blue color. But the result is that the whole bar gets filled eventhough i set the progress to be half of the maximum! This is my code:



xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" >

android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/hello_world" />

android:id="@+id/batteryProgressBar1"
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/textView1"
android:layout_alignParentRight="true"
android:layout_below="@+id/textView1"
android:layout_marginTop="26dp"/>


and the custom class:



public class BatteryProgressBar extends ProgressBar {

public BatteryProgressBar(Context context) {
super(context);
init();

}

public BatteryProgressBar(Context context, AttributeSet attrs) {
super(context, attrs);
init();
}

public BatteryProgressBar(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
init();
}

@Override
protected void onDraw(Canvas canvas) {
super.onDraw(canvas);
}

private void init() {
setProgressDrawable(getResources().getDrawable(R.drawable.blue));
setMax(100);
setProgress(50);
}


}


and my blue color comes from









Why is the whole bar filled when im only setting it to be 50% filled?


Thanks!



Read more

stackoverflow.comm



[android help] TextView only updated every x seconds


TextView only updated every x seconds


android - TextView only updated every x seconds - Stack Overflow







Tell me more ×

Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
















I have the following code which should change the textview every second but only does every 2 or even every 4 seconds:



final TextView tv = (TextView) findViewById(R.id.textView1);

new CountDownTimer(remain, 1000)
{
@Override
public void onFinish()
{
tv.setText("Done");
}

@Override
public void onTick(long millisUntilFinished)
{
tv.setText(timeCalculate(millisUntilFinished / 1000));
}
}.start();


What am I doing wrong?



















default






Read more

stackoverflow.comm



[android help] Start simple Animation top to bottom from a specific position


Start simple Animation top to bottom from a specific position


android - Start simple Animation top to bottom from a specific position - Stack Overflow







Tell me more ×

Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
















I need to make a textview that perform an animation from top to bottom and the animation start with the y value 50. How to do it? Thanks in advance.


























You can use TranslateAnimation. TranslateAnimation uses deltas, so to calculate the position of 50px from the top of the screen, subtract the top of the view & add 50. In this example, I set the toY by adding some value to the fromY. Here's the code:



int fromY = 50 - view.getTop();
int toY = fromY + someValue;
TranslateAnimation animation = new TranslateAnimation(0, 0, fromY, toY);
animation.setDuration(someDuration);
view.startAnimation(animation);


Hope this helps :)




















default






Read more

stackoverflow.comm



[android help] Is there any way to calculate speed of current ride in Android Maps V2


Is there any way to calculate speed of current ride in Android Maps V2



Check below code, done by me, and its working well. In this lots of code related your stuff, because I have did exactly same as your requirement. So you can use all the code given below. And if you find it unncessory, then dont use it.



@Override
public void onLocationChanged(Location location) {

try {
if (location != null) {

if (current_lat != null && current_lat > 0) {
latitude = current_lat;
}
if (current_long != null && current_long > 0) {
longitude = current_long;
}
current_lat = location.getLatitude();
current_long = location.getLongitude();
distanceBetweenTwoPoint = getDistance(latitude, longitude, current_lat, current_long);
if ((current_lat > 0 && current_long > 0) && distanceBetweenTwoPoint > IjoomerApplicationConfiguration.track_DistanceBetweenPoints_IN_METERS) {
if (location.hasSpeed()) {
speedInKm = location.getSpeed() * 3.6;
} else {
speedInKm = 0.0;
}
row = new HashMap();
row.put(TRACKID, IN_TRACKID + "");
row.put(LATITUDE, current_lat.toString());
row.put(LONGITUDE, current_long.toString());
row.put(SPEED, speedInKm + "");
row.put(TIMESTAMP, System.currentTimeMillis() + "");
row.put(STATUS, status);

distance = distance + (distanceBetweenTwoPoint / 1000);
row.put(DISTANCE, "" + distance);
dataProvider.InsertRow("TrackDetail", row);
row.put(LASTKNOWNLATITUDE, latitude.toString());
row.put(LASTKNOWNLONGITUDE, longitude.toString());
int seconds = (int) ((System.currentTimeMillis() - trackStartTime) / 1000) % 60;
int minutes = (int) (((System.currentTimeMillis() - trackStartTime) / (1000 * 60)) % 60);
int hours = (int) (((System.currentTimeMillis() - trackStartTime) / (1000 * 60 * 60)) % 24);

row.put(DURATION, String.valueOf(hours) + " : " + String.valueOf(minutes) + " : " + String.valueOf(seconds));
setNotification(speedInKm, String.valueOf(hours) + " : " + String.valueOf(minutes) + " : " + String.valueOf(seconds));
if (status.equalsIgnoreCase("1")) {

builder.append("|" + current_lat + "," + current_long);
trackDuration = String.valueOf(hours) + " : " + String.valueOf(minutes) + " : " + String.valueOf(seconds);
if (speedInKm > maxSpeed) {
maxSpeed = speedInKm;
}
totalSpeed = totalSpeed + speedInKm;
++totalTrackPoint;
sendBrodcastToActivity();
}
}
}
} catch (Exception e) {
e.printStackTrace();
}

}


Read more

stackoverflow.comm



[android help] How to find whether the device in same location or moving in Android?


How to find whether the device in same location or moving in Android?


gps - How to find whether the device in same location or moving in Android? - Stack Overflow







Tell me more ×

Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
















In Android, I am getting locations for every 30 seconds by GPS using alarm manager. I want to detect whether the device is traveling or presence at same location using geopoints. If the device in same location GPS getting some times accurate data some times getting approximate data at the time 20 or 30 meter away from accurate location displaying on map.


So it's getting problem on finding device traveling.


How to find device is not traveling?





























Every 30 seconds when you get the new locations you can compare it with the previous location to see if there is any difference in location and determine if the device is travelling.























You can write code in onLocationChanged() method. There you will get new latitude longitude each and everytime when device changed its position. OnLocationChange() method called only if location has been changed. But if you want some specific distance wise calculations then you have to calculate distance between older lat-long and newer one. You can find distance using lat-long.






















As the GPS signal recieved can vary even it's in the same position, you can't just compare the new location with the old one. I would use something like the following code



double venueLat =latitude
double venueLng = longitude

double latDistance = Math.toRadians(userLat - venueLat);
double lngDistance = Math.toRadians(userLng - venueLng);
double a = (Math.sin(latDistance / 2) * Math.sin(latDistance / 2)) +
(Math.cos(Math.toRadians(userLat))) *
(Math.cos(Math.toRadians(venueLat))) *
(Math.sin(lngDistance / 2)) *
(Math.sin(lngDistance / 2));

double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));

double dist = 6371 * c;
if (dist<1){ (in km, you can use 0.1 for metres etc.)
/* Include your code here to display your records */
}



















default






Read more

stackoverflow.comm



Google Voice on T-Mobile? [General]

Google Voice on T-Mobile? So I recently switched from a GNex on Verizon to a Moto X DE on T-Mobile. I had always used Google Voice for my v...