XAppDbg

XAppDbg is an app development tool that can be used to change parameters in your code during runtime. This can save you a lot of time, since you don’t have to build and run your application for each small change.

We have published XAppDbg as open source, and it can be downloaded from the XAppDbg project on GitHub. For a more extensive introduction, read our XAppDbg blog post. Any questions, comments or ideas for contribution can be posted in the XAppDbg thread in the XDA forum. We are monitoring this thread to answer your posts and continuously publish new information about the XAppDbg tool.

The first line just creates a server instance. The XAppDbgPropertiesModule scans the fields of an object or class, and exposes all the public fields it finds. The third line starts the server, and it will be listening on port 55011. In order for this to work, the application must have the INTERNET permission.

Run the application you’re developing on your phone.

Use a USB cable to connect the phone to the computer. In order for the client application on the computor to be able to connect to the phone using TCP/IP, you need Android Debug Bridge (ADB) to forward the port. This means that the following command needs to be executed in a shell every time your device is connected to the computer via the USB cable:

$ adb forward tcp:55011 tcp:55011

Now when you start the client application, you just need to click on “Connect localhost”, and you’re ready:

Screenshot of the connection dialogue of the XAppDbg client.

Now you can change any of your parameters during runtime on the computer and see the effect of the change immediately on your phone, without rebuilding the application.

Screenshot showing the XAppDbg client for the computer.

When you are satisfied with the result, just copy the values from the client back into your source code and rebuild it.