Google+
Showing posts with label development. Show all posts
Showing posts with label development. Show all posts

Friday, 20 June 2014

Welcome to DIY hub


Welcome Folks....
this blog is for the ones who likes to take their eagerness to their peak.....
so you can DO IT YOURSELF!!!

So we will be posting techno related posts from mobile development to Robotics and much more for your intrest...

We will b providing you best contents soon.. so stay at touch...
Read More


Wednesday, 19 June 2013

[Starter Guide] BUILDING YOUR OWN CUSTOM ROM FROM STOCK ROMS DIRECT FROM DEVICE

These are the whole new step towards the development of android devices
                        i.e. BUILDING YOUR OWN CUSTOM ROM
It includes many features and depend totally upon ur choice of what u want and/or need to make ur device so called BETTER!!!

The basic features that ur rom contains generally:-


  • THEMES (i.e. frameworks, launchers nd all sort of visuals)
  • KERNALS (i.e. interface performance, efficiency of device)
  • TWEAKS (i.e. device performance and efficiency)
So, we will cover above topics step by step resulting in OUR OWN CUSTOM ROM.



NOTE :- Building custom rom from stock rom direct from ur device MEANS MODIFYING the rom present in devices, it might need pc for modify some features
ND it is SLIGHTLY DIFERENT FROM EDITING CUSTOM ROMS ALREADY PRESENT FOR DEVICES!
Read More


[DIY] make your own WIFI SPYBOT

For making a wifi spybot the basic process involves stripping the R/C car, plugging in the Barracuda – which bridges the local servo controls with an ethernet connection – and hooking up the wireless router and webcam.  There’s also some fiddling with network settings to be done.




We will be showing you how to build a wifi robot / spybot from scratch. It is a very straight forward project and can easily be handled by a intermediate robot builder. To complete the robot, it will take a couple of hours.


WHAT U NEED FIRST-

1-Rc Car (new or used, choose one that could easily have a Rc servo fitted in the steering system. We got ours from Radio Shack.)


  • 1-Barracuda wifi robot controller
  • 1-Wifi Router 
  • 1-Network Camera
  • 2-Ethernet Cables
  • 1-5v Regulator for camera
  • 2-3 7.2v Rc Batteries (3300mAh or greater recommended)
  • Misc wire, solder, tape etc.




NOW follow some steps :-




Step 1: Hacking The Car





To start building your wifi Robot / spybot, gutting of the Rc car is the first step. Take out everything! We got our Rc truck from Radio Shack, but others will work also. We gutted it out and built a roll cage on top. Here is a Picture of the truck gutted and the 3 Rc batteries mounted in the truck.

The two red batteries are to power the main motor and the barracuda wifi controller. While the blue 7.2v battery will power the Linksys router, 5v Regulator for the camera, and the steering servo. Three batteries are not needed, but i just find that it makes the wifi robot / spybot more reliable and allows longer run times. If you opt for two batteries the Linksys router can handle 40v, so you will be fine running it straight off of the two packs. The same with the 5v regulator. Te only problem will be the power for the steering servo, so you will either have to add another 5v regulator and run it off of that or just get a higher amperage 5v Regulator and run the servo and the camera off of it. The latter would be easiest. 



Step 2: Install The Steering Servo



We gutted out the steering box and retro fitted in a standard Rc servo. Other people have used the steering Mechanism that comes with the Rc car, But I wanted true proportional steering.



Step 3: Install The Barracuda wifi robot / spybot controller











(Picture One)
We started this step out by extending the leads coming from the motor by soldering on extra wire we had laying around.

(Picture Two)
Here is a picture of the barracuda wifi robot / spybot controller. This is what we will be using to control our robot.

(Picture Three)
Here is a picture of the yellow lead from the motor connected to the terminal block. You can also see how the batteries are connected in series to power the barracuda wifi robot controller. On the green terminal block is where we connect the servo. The red wire is connected to the third 7.2v batteries ground and the servo's ground. The white wire is the servo's signal wire. The barracuda has two output ports. Each can individually be configured as a digital or analog input, digital output, or an Rc output making the Barracuda very flexible




 Step 4: Power the camera, router and servo



In this step, all we did was take the mating connector that will connect to the batteries connector and solder the power and ground together for the 5v regulator. The power plug for the Linksys and the power wires for the servo. For a more detailed view, check out our Youtube Video.
Here is a picture of the 5v Regulator attached to the rear battery.



 Step 5: connect everything to the router





 Configure your router to have the base Ip Address of 192.168.1.1. The stock Ip Address for the barracuda is 192.168.1.10. The IP can be changed to whatever you want it to be with the configuration program that comes with it. Connect the camera and the Barracuda wifi robot controller to the router using the two Ethernet cables. Configure the camera to have an ip that works with that of the router and barracuda.


Step 6: Power up and go!


The barracuda wifi robot controller comes with a sample program and source code to drive the car. Power the car up,connect to your camera in the browser, run the sample program for the barracuda and start driving! The barracuda also supports use of a PS3 controller plugged into your computer to control it.


SOURCE - instructables

Read More


Monday, 22 April 2013

Nokia Mobile Secret Codes

These are the secret codes for Nokia Java/Symbian  mobile to unlock, test and view many of the aspects of your phone. Many of the codes listed here doesn't work because of the software version and model number. Sometimes they didn't match together. So, enter these codes in your phone and checkout how many of them work for you!

On the main screen type the following codes:
*#746025625# Sim clock allowed status. 
*#62209526# - Display the MAC address of the WLAN adapter. This is available only in the newer devices that supports WLAN like N80
#pw+1234567890+1# Shows if sim have restrictions.

For more advanced codes click here
Read More


Thursday, 11 April 2013

Changing resolution of High-End games into hvga/qvga in android

Some lower end devices does not support high graphics games or high resolution games meant to be for high end devices...
BUT
Here is a way to convert those games into low resolution, Its like chamging resolution pf games in computers
IT IS BIT TOUGH AND A NEXT STAGE TOWARDS OUR DEVELOPMENT IN ANDROID..
so lets begin :-
We need the following programs:
1. Apk Manager (download here).
2. Any text editor (notepad will fit).
3. Ida Pro 5.5 (can be found in the internet, the tracker).
4. Any hex editor (I use UltraEdit).



Now let us think that the game is optimized for screen HVGA / QVGA?
It can be divided into several stages.
Key:
1. Changing the rendering resolution to HVGA / QVGA.
2. Adjustment grid touch screen.
Secondary:
3. How to disable the cache (necessary in order to be able to convert introductory video at lower resolution).
4. Assigning a hardware button on any action (required for phones without multitouch).

Before proceeding to any stage of optimization, we need to get to the source code, the original source code, we certainly do not get, but we can get a JAVA-byte code, which is quite to our problem would be enough. For this purpose, we use "Apk Manager".

Install and use a "Apk Manager".
The setup is nothing complicated, just unzip it to any folder. Also recommend that a file Script.bat, located in the folder "Apk Manager", change "set heapy = 64" to a higher value, such as 256 or 512, to prevent problems with large agribusiness files.
Working with "Apk Manager" also does not present difficulties. Required APK file put in folder "place-apk-here-for-modding", run "Script.bat" and the pop up window with green text, press "9 " and "Enter". Less than a minute later, the folder "projects" we unpacked APK file. Packs the same, run "Script.bat", click on "11"," Enter ", the question is whether the APC system? "Hit"n". And in the end, when the APK-packed file, sign it, for that press "12 " and "Enter". As a result, we get in the folder "place-apk-here-for-modding" file with the name signed [the name of the original APK-file].apk. Additionally, about "Apk manager" can be read here.
Further in the text I will miss the description of the process of unpacking / packing APK files.
For example I will use the game "Modern Combat: Sandstorm".

1. Changing the rendering resolution to HVGA / QVGA.
Most games under android, written using OpenGL, an OpenGL permission given by the function "glViewPort", and it will use. The most optimal, I think the function "glViewPort" place in the function "OnDrawFrame". To do this, by looking in the folder "smali", which is located in a folder with raspakovanym APK file, look for a file containing the function "OnDrawFrame". Usually this file is named "GameRenderer.smali" or "[Name Game] Renderer.smali ", in this case, "SandstormRenderer.smali". Open it in Notepad or another text editor and find in it the function "OnDrawFrame".
Here is a fragment of this function.
HTML Code:
.method public onDrawFrame(Ljavax/microedition/khronos/opengles/GL10;)V
    .locals 6
    .parameter "gl"

    .prologue
    .line 174
    const-wide/16 v0, 0x0

    .line 177
    .local v0, time:J
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v0

    .line 179
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/GLMediaPlayer;->update()V

    .line 180
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/SandstormRenderer;->nativeRender()V

    .line 186
    const-wide/16 v2, 0x32

    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v4

    sub-long/2addr v4, v0

    sub-long v0, v2, v4

    .line 188
    const-wide/16 v2, 0x0

    cmp-long v2, v0, v2

    if-lez v2, :cond_0

    .line 190
    :try_start_0
    invoke-static {v0, v1}, Ljava/lang/Thread;->sleep(J)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 193
    :cond_0
    :goto_0
    return-void

    .line 190
    :catch_0
    move-exception v2

    goto :goto_0
.end method
In this snippet of code to add the function call "glViewPort", so to obtain, as in the code snippet below.
HTML Code:
.method public onDrawFrame(Ljavax/microedition/khronos/opengles/GL10;)V
        .locals 9
    .parameter "gl"

    .prologue
    const/16 v8, 0x1E0

    const/16 v7, 0x140

    const/4 v6, 0x0

    invoke-interface {p1, v6, v6, v8, v7}, Ljavax/microedition/khronos/opengles/GL10;->glViewport(IIII)V

    .line 174
    const-wide/16 v0, 0x0

    .line 177
    .local v0, time:J
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v0

    .line 179
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/GLMediaPlayer;->update()V

    .line 180
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/SandstormRenderer;->nativeRender()V

    .line 186
    const-wide/16 v2, 0x32

    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v4

    sub-long/2addr v4, v0

    sub-long v0, v2, v4

    .line 188
    const-wide/16 v2, 0x0

    cmp-long v2, v0, v2

    if-lez v2, :cond_0

    .line 190
    :try_start_0
    invoke-static {v0, v1}, Ljava/lang/Thread;->sleep(J)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 193
    :cond_0
    :goto_0
    return-void

    .line 190
    :catch_0
    move-exception v2

    goto :goto_0
.end method
What we have done here? We've added three constants (v6, v7, v8), assign them a value of coordinates of the left lower (v6; v6) and upper right (v8; v7) corner of the screen and transferred them to the function "glViewport". I think it is understandable why for the coordinates of the lower left corner for the X and Y is used alone and also a constant v6? Since both X and Y in this corner are equal. In addition, change the 2-th line in the function ". locals 6 " on ". locals 9 ", it determines the number of constants / variables used in functions, so we added 3 constants, 6 +3 = 9. Also note that the names of the constants (v6, v7, v8), are not taken casually, as selected by focusing on already used in the function of the constants. If suddenly someone did not understand, 0x1E0 in decimal would be 480 and 0x140 - 320.

Also pay attention to the function "onSurfaceCreated".
HTML Code:
.method public onSurfaceCreated(Ljavax/microedition/khronos/opengles/GL10;Ljavax/microedition/khronos/egl/EGLConfig;)V
    .locals 7
    .parameter "gl"
    .parameter "config"

    .prologue
    const/4 v3, -0x1

    .line 138
    const/4 v0, 0x2

    const-string v1, "SandstormRenderer"

    const-string v2, "onSurfaceCreated"

    invoke-static {v0, v1, v2}, Lcom/gameloft/android/GAND/GloftMCHP/GLDebug;->debugMessage(ILjava/lang/String;Ljava/lang/String;)V

    .line 141
    invoke-direct {p0}, Lcom/gameloft/android/GAND/GloftMCHP/SandstormRenderer;->nativeGetJNIEnv()V

    .line 142
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/GLResLoader;->init()V

    .line 143
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/GLMediaPlayer;->init()V

    .line 144
    invoke-static {}, Lcom/gameloft/android/GAND/GloftMCHP/Sandstorm;->nativeInit()V

    .line 146
    :goto_0
    sget v0, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_W:I

    if-eq v0, v3, :cond_0

    sget v0, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_H:I

    if-ne v0, v3, :cond_1

    .line 149
    :cond_0
    const-wide/16 v0, 0x32

    :try_start_0
    invoke-static {v0, v1}, Ljava/lang/Thread;->sleep(J)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_0

    :catch_0
    move-exception v6

    .local v6, ex:Ljava/lang/Exception;
    invoke-virtual {v6}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_0

    .line 154
    .end local v6           #ex:Ljava/lang/Exception;
    :cond_1
    sget v1, Lcom/gameloft/android/GAND/GloftMCHP/Sandstorm;->m_bEnableKeyboard:I

    const/4 v2, 0x1

    sget v3, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_W:I

    sget v4, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_H:I

    sget v5, Lcom/gameloft/android/GAND/GloftMCHP/Sandstorm;->mCurrentLang:I

    move-object v0, p0

    invoke-direct/range {v0 .. v5}, Lcom/gameloft/android/GAND/GloftMCHP/SandstormRenderer;->nativeInit(IIIII)V

    .line 155
    return-void
.end method
Namely, the code
HTML Code:
sget v3, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_W:I

sget v4, Lcom/gameloft/android/GAND/GloftMCHP/SandstormGLSurfaceView;->mDevice_H:I
In this code, the variable v3, v4 assigned to the real resolution screen devices, and passed to the function "nativeInit". Since the game is still designed for 480x800 resolution, it is better to have the game thinking that you have a device with this particular resolution. in this code is replaced by
HTML Code:
const/16 v3, 0x320

const/16 v4, 0x1E0
If you do not experience problems.
(You can ask and 480h720, since the proportion of screens with 480x800 and 320x480 are different and when "squeeze " the picture is slightly flattened (thanks for the comment G @ sh! sh). But in this case, at the stage of "adjustment grid touch screen", the coefficient must be assumed to be between 800 and between 720 and will it be 1.666666666666667 and 720/480 = 1.5)
Note
In other games instead of code, maybe something like this
HTML Code:
invoke-virtual {v0}, Landroid/view/Display;->getWidth()I

move-result v3

invoke-virtual {v0}, Landroid/view/Display;->getHeight()I

move-result v4
Anyway replace it at:
HTML Code:
const/16 v3, 0x320

const/16 v4, 0x1E0
Or variable names can not v3, v4 and v1, v2. Or nothing at all like it to be, and then change nothing.
Or if problems arise, you can just in case, go looking for all "*. smali" files and replace all function calls "Landroid / view / Display; -> getWidth () I" and "Landroid / view / Display; -> getHeight () I ", suffer from it will not.
For some games, our work is enough and they safely change the permissions on all the graphics you need. To do this again packs APK-file and check the phone as he works. If everything is successful then go to the item "adjustment grid the touch screen. " If not, read on. In our case, with the game Modern Combat: Sandstorm, not everything is smooth, game graphics smashtabirovalas until the required permission, and the menu - no. This means that somewhere in the function is called "glViewPort", and then change the resolution to 480x800. Thus, as in the files "*. smali" function "glViewPort" do not call, you can check by searching, so the case in the library "libsandstorm.so".

The main idea of ​​the next step, remove all calls to library functions "glViewPort".
To analyze the library, we need the "Ida Pro". For convenience, copy "libsandstorm.so" in any folder, run "Ida Pro" and click on "New" button

Then choose "Various files", "Unknown file" and click "OK".

In the window, open the file specify the path to the library "libsandstorm.so" and click "Open. "
In the next window, change the "Processor type" to "ARM processorARM710a", then click "Set" and "Ok ".

If after this, there will be another window with anything, click "OK ". Now you need to wait for the disassembly. This process is quite long, in this you can go to smoke or drink coffee 
The fact that reverse engineering is completed, will show a message "The initial autoanalysis has been finished." in the lower box "Output window".

For greater convenience, in this case, click the right mouse button on a blue field, and on the shortcut menu, select "Text view". Moving to the beginning of assembler code for the search for "glViewPort".

Hit the keyboard shortcut "Alt + T" in the dialog box to enter search "glViewPort" and click "OK".

We are interested in function calls "BLX glViewport", "BL glViewport", "B glViewport", "BX glViewport", etc. Any other mentions of "glViewport" we deny press "Ctrl + T" and continue the search.
A necessary place, switch to the "Hex View-A".

Make sure that the function call takes 4 bytes and a "CE F7 D4 E8" (in your case, these figures may be different), it is necessary in order to see what needs to be corrected and do not accidentally overwrite anything extra.

Calling this function we need to drink, for it must be replaced by "CE F7 D4 E8" (in your case, these figures may be different) on "C0 46 C0 46. Remember the address "001F994A" and run the hex editor, I use "UltraEdit". Open it to our library.

In order to move us to the right address, click "Ctrl + G", in the input box will appear "0x001F994A" and click "OK".

Moving, we see that hit where you want, all the hexadecimal code converges to the fact that we saw in "Ida Pro" tab "Hex View-A".

Correcting the "CE F7 D4 E8" on "C0 46 C0 46.

Switches to "Ida Pro" and continue to search for the following calls "glViewPort", there may be several dozen. They have been treated similarly.
When all calls to drink, is preserved. Copy to place a revised "libsandstorm.so". Packs APK-file and set the phone to check. If done correctly, the entire schedule to Decrease the required permission.
CREDITS =>
 
Read More


Monday, 8 April 2013

several ways of ROOTING Android device by Yourself

The most basic and important step during any type of development on android is, ROOTING it..
SO here are some ways so that u can root your device:-


Rooting Android with z4root :-

First, you’ll need to make sure that non-Market app installs are allowed; this is called sideloading apps. To do this, go to Menu > Settings > Applications and check “Unknown Sources”. (If it’s greyed out, that means that your carrier has decided to be mean and block sideloading. To remove this restriction, try rooting with SuperOneClick or device-specific rooting below.)

Now that your phone allows sideloading, download z4root onto your phone. Once it has been downloaded, use a file manager to navigate to the APK installer (it will probably be in the download folder) and install z4root. After it is installed, launch z4root from your app tray open it up from your launcher:


 Once z4root has been launched, you are half-way finished. Now all you have to do is decide if you want a permanent root, or just a root until you reboot your phone (temporary root). If you want a permanent root, be aware that it won’t work on every phone (try SuperOneClick or device-specific rooting if z4root doesn’t work for you).
Once you select what type of root you want, just follow on-screen instructions and you will be rooted within minutes. You know you are rooted if you have a “SuperUser” app in your app tray. You may have to reboot your device for this to appear. If the “SuperUser” app appears, congrats! Your Android 2.2 phone is now rooted.
Te following is the list of known phones compatible/incompatible with the permanent root:



If your phone is not in the list shown above, it may or may not be compatible with z4root. The only way to find out is try it out. If your phone is on the incompatible list, you can only use the temporary root option.




Rooting with SuperOneClick :-

Rooting with SuperOneClick is a fairly easy affair, but requires a bit of setup first. The first thing you need to do is make sure your device will work with SuperOneClick. It is most likely compatible if it is not one of these (the following are incompatible devices)
  • Sprint EVO 4G (HTC Supersonic)
  • Droid Incredible (HTC Incredible)
  • HTC Desire GSM
  • HTC Desire CDMA (HTC BravoC)
  • HTC Aria
  • Droid Eris (HTC DesireC)
  • HTC Wildfire (HTC Buzz)
These phones have locked NAND chips. In order to remove this lock, you must use unrevoked, a NAND unlocker.
So far the known phones that are compatible with SuperOneClick are:
  • Acer Liquid Metal
  • Dell Streak
  • HTC Magic (Sapphire) 32B
  • HTC Bee
  • LG Ally
  • Motorola Atrix 4G
  • Motorola Charm
  • Motorola Cliq
  • Motorola Droid
  • Motorola Flipside
  • Motorola Flipout
  • Motorola Milestone
  • Nexus One
  • Samsung Captivate
  • Samsung Galaxy 551 (GT-I5510)
  • Samsung Galaxy Portal/Spica I5700
  • Samsung Galaxy S 4G
  • Samsung Galaxy S I9000
  • Samsung Galaxy S SCH-I500
  • Samsung Galaxy Tab
  • Samsung Transform M920
  • Samsung Vibrant
  • Sony Ericsson Xperia E51i X8
  • Sony Ericsson Xperia X10
  • Sprint Hero
  • Telus Fascinate
  • Toshiba Folio 100
The key thing to note is just because your phone is not on the above list does not mean SuperOneClick won’t work with your phone. As long as your phone is not listed on the incompatible list (first list shown above), then your phone may still work with SuperOneClick. The only way you will know for sure is to give it a try; if you are on Android 2.3 Gingerbread or lower, SuperOneClick will likely work for your device. Use other method if ur device isnt compatible.
After verifying your phone is rootable, there still remain couple of prerequisites to rooting your device:
  • You NEED to put your phone on USB Debugging mode
  • You NEED to install make sure the Android drivers for your phone are installed
  • Make sure you DO NOT mount your SD card
  • If you still can’t get something to run, try doing it in recovery mode
To put your device into USB Debugging mode, go to Settings > Applications > Development and check the “USB Debugging” box. After enabling debugging, install drivers for your phone on your computer and plug in your phone.
After installing the drivers, you’ll need to download SuperOneClick. Note that, due to the exploit used in the rooting program, it may be detected as a virus; this is to be expected and the program is clean as far as we know.Open SuperOneClick.exe (Vista + 7: right click -> run as administrator):



The beauty of SuperOneClick is its rooting method is universal, allowing for all Android devices to be rooted at any version number. So, just hit Root to root your device.
(Sidenote: After rooting, if your device did not allow for sideloading, you can enable sideloading on your device by hitting the Allow Non-Market Apps buttons.)
Once the root procedure has finished, go back to your device. Open your app launcher and you should a new app called “Superuser”. This verifies your device has been rooted; if you don’t see it, try rebooting your device.




Other :-

If z4root nor SuperOneClick worked for your device and we haven’t covered your device , the best place to find how to root your device is XDA-Developers. Visit XDA and look for your specific device; then roam the forums and look for a thread that explains how to root. (You will most likely find it in the Android Development subforum for your device.) You can even ask questions if you have trouble.


Read More


Join Us

//go.ad2up.com/afu.php?id=25365

© Copyright 2012, Design by Lord HTML.
​