Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

How to test android app not connected to PC?

  • 11-12-2012 01:20PM
    #1
    Moderators, Science, Health & Environment Moderators, Social & Fun Moderators, Society & Culture Moderators Posts: 60,119 Mod ✭✭✭✭


    So I have to disconnect my tablet from my PC and connect it to a serial device to test it. However now I have no idea how to test what is happening, what do people generally do?

    I have tried using toasts, and some of them come up saying I am inside a method and so on, but a few of them seem not to be, I don't know if this is indeed indicating errors and is a valid way to test? An alternative?


Comments

  • Registered Users, Registered Users 2 Posts: 18,272 ✭✭✭✭Atomic Pineapple


    So I have to disconnect my tablet from my PC and connect it to a serial device to test it. However now I have no idea how to test what is happening, what do people generally do?

    I have tried using toasts, and some of them come up saying I am inside a method and so on, but a few of them seem not to be, I don't know if this is indeed indicating errors and is a valid way to test? An alternative?

    Just use CatLog

    CatLog | Google Play link


  • Moderators, Science, Health & Environment Moderators, Social & Fun Moderators, Society & Culture Moderators Posts: 60,119 Mod ✭✭✭✭Tar.Aldarion


    Thanks will give that a go, hopefully without needing root!


  • Registered Users, Registered Users 2 Posts: 18,272 ✭✭✭✭Atomic Pineapple


    Thanks will give that a go, hopefully without needing root!

    No doesn't need root, it just logs the log cat traces from the OS when your not connected on USB. Handy tool.


  • Moderators, Science, Health & Environment Moderators, Social & Fun Moderators, Society & Culture Moderators Posts: 60,119 Mod ✭✭✭✭Tar.Aldarion


    Ah I see, very cool. Have it running, million things happening :D


  • Registered Users, Registered Users 2 Posts: 18,272 ✭✭✭✭Atomic Pineapple


    Ah I see, very cool. Have it running, million things happening :D

    Use your own logging in your code and make sure to filter on that.


  • Advertisement
  • Moderators, Science, Health & Environment Moderators, Social & Fun Moderators, Society & Culture Moderators Posts: 60,119 Mod ✭✭✭✭Tar.Aldarion


    Sounds perfect, cheers.


  • Moderators, Science, Health & Environment Moderators, Social & Fun Moderators, Society & Culture Moderators Posts: 60,119 Mod ✭✭✭✭Tar.Aldarion


    If I do Log.d(TAG, "message"); can i filter by tag? Or is there a way just completely filter one app, like an id etc? Gonna mess around with it now.

    Edit: I see both ways work fine.


  • Registered Users, Registered Users 2 Posts: 7,157 ✭✭✭srsly78


    There is a way to run adb over wifi: http://forum.xda-developers.com/showthread.php?t=1685736

    This will let you debug as normal with breakpoints etc.


Advertisement