tickmate icon indicating copy to clipboard operation
tickmate copied to clipboard

Android Wear

Open Querschlag opened this issue 8 years ago • 10 comments

A few weeks ago I got myself a Moto 360 and started thinking of good use cases for it. Since I'm still into habit tracking I wondered how a wearable would make this more comfortable. So I sat down and wrote an Android Wear companion app for Tickmate. It pulls the tracks from the device and lets you add and remove Ticks from your wrist + it shows you your weekly stats. I used the Android Wear MessageApi for reading/writing data, so the app won't work without your phone being nearby. I made this choice mostly because of privacy concerns, as the only other option - the Google DataApi - would sync your sensitive data through Google's Cloud services.

Check out my fork at: https://github.com/Querschlag/tickmate

Android Wear: Setting Multitick Android Wear: Weekly stats

Querschlag avatar Nov 25 '15 19:11 Querschlag

Wow, that looks awesome! I don't have any experience with Android Wear apps (nor do I own any wearables yet), but I find it very interesting. Do you know if I can I try the companion app in the android studio simulator?

lordi avatar Nov 25 '15 20:11 lordi

You can run the app with your physical device + the Android Emulator.

  1. Create a new ADB device with Android Wear and fire it up.
  2. Install the Android Wear App on your phone.
  3. Forward ports for emulator debugging on your computer. adb -d forward tcp:5601 tcp:5601
  4. Open the Android Wear app on your phone and start the pairing dialog. In the upper right menu you can choose to pair with an emulator.
  5. In Android Studio run the "app" configuration on your phone to install the service for wearable communication.
  6. Run the "wear" configuration on the Wear Emulator.

After that you should be able to see the data from Tickmate on your phone in the emulator.

Querschlag avatar Nov 25 '15 20:11 Querschlag

Over the last few days I fixed a few bugs and a communication issue when wearable device and handset have different Android versions. Since I now use my Nexus 6P for testing I also implemented support for Android M permissions when importing/exporting the database.

For those of you that have an Android watch and like to test it on a real device - you can get a binary with the latest changes at: https://github.com/Querschlag/tickmate/releases/tag/v1.3.0

Make sure to backup your database first! You'll have to delete your current Tickmate installation in order to install the Android Wear version!

Querschlag avatar Dec 05 '15 13:12 Querschlag

Nice to see progress! Why do you have to delete the Tickmate install?

lordi avatar Dec 05 '15 21:12 lordi

It's because my APK file is signed with a different key than the Google PlayStore version. Android does not allow to update an app with an APK of different signature.

Querschlag avatar Dec 05 '15 23:12 Querschlag

But in principle it would be possible to release a new version with the Wear App bundled - so that for non-wear users nothing would change, but wear users can use the companion app? Or is the companion Wear App a separate app?

lordi avatar Dec 06 '15 12:12 lordi

My release already includes the Wear App. It's really just a matter of signing. User without wearables can use/update the app from Google Play as usual and if there are any Android Wear devices paired, the Watch App will be synced automatically after installation.

Querschlag avatar Dec 06 '15 12:12 Querschlag

Sorry for the delay, I definitely want to accept this PR. But it might take some more time as I want to make sure that no user is affected negatively by it.

lordi avatar Jan 24 '16 17:01 lordi

No problem. I had been busy with other projects lately. Unfortunately I was unable to further test the Travis config due to merge conflicts in the PR. Let me know when you need further input.

Querschlag avatar Jan 24 '16 20:01 Querschlag

Would love to see this on contemporary WearOS

PanderMusubi avatar May 28 '21 06:05 PanderMusubi