Hello,
it seems that Huami Amazfit GTR is not compatible with Gadgetbridge.
Can you implement support for this device ?
Many thanksl
A pointer, just in case: Support for a new Device (in the Gadgetbridge wiki). You might wish to check with this, maybe you can provide some helpful details that make implementation easier.
GTR is probably similar to bip. We do not have a device but we could create a test branch. That requires people to be able to compile and test!
I have no experience in Android development but I know very well Linux eco system.
I don't have my GTR yet but if you need me to get some logs or traces I can do that.
The most important point is I need people being able AND willing to build Gadgetbridge themselves, the rest is a bonus ;)
In a Docker Ubuntu image, with OpenJDK 8, git and adb, I've cloned the git repository but when I try to launch ./gradlew assembleDebug according to Developer Documentation, I face the following error :
root@6b450e359dee:~/Gadgetbridge# ./gradlew assembleDebug
Downloading https://services.gradle.org/distributions/gradle-5.4.1-all.zip
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
...............................................................................................................................................................
.......................................................................................................................
Unzipping /root/.gradle/wrapper/dists/gradle-5.4.1-all/1jkdto6ec7o8pep4874j0q1o8h/gradle-5.4.1-all.zip to /root/.gradle/wrapper/dists/gradle-5.4.1-all/1jkdto6ec7o8pep4874j0q1o8h
Set executable permissions for: /root/.gradle/wrapper/dists/gradle-5.4.1-all/1jkdto6ec7o8pep4874j0q1o8h/gradle-5.4.1/bin/gradle
Welcome to Gradle 5.4.1!
Here are the highlights of this release:
- Run builds with JDK12
- New API for Incremental Tasks
- Updates to native projects, including Swift 5 support
For more details see https://docs.gradle.org/5.4.1/release-notes.html
Starting a Gradle Daemon (subsequent builds will be faster)
FAILURE: Build failed with an exception.
* What went wrong:
Task 'assembleDebug' not found in root project 'Gadgetbridge'.
* Try:
Run gradlew tasks to get a list of available tasks. Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 39s
When I run "./gradlew tasks", assembleDebug is not listed :
root@6b450e359dee:~/Gadgetbridge# ./gradlew tasks
> Task :tasks
------------------------------------------------------------
Tasks runnable from root project
------------------------------------------------------------
Android tasks
-------------
sourceSets - Prints out all the source sets defined in this project.
Application tasks
-----------------
run - Runs this project as a JVM application
Build tasks
-----------
assemble - Assembles all variants of all applications and secondary packages.
assembleAndroidTest - Assembles all the Test applications.
build - Assembles and tests this project.
buildDependents - Assembles and tests this project and all projects that depend on it.
buildNeeded - Assembles and tests this project and all projects it depends on.
classes - Assembles main classes.
clean - Deletes the build directory.
cleanBuildCache - Deletes the build cache directory.
jar - Assembles a jar archive containing the main classes.
testClasses - Assembles test classes.
Build Setup tasks
-----------------
init - Initializes a new Gradle build.
wrapper - Generates Gradle wrapper files.
Distribution tasks
------------------
assembleDist - Assembles the main distributions
distTar - Bundles the project as a distribution.
distZip - Bundles the project as a distribution.
installDist - Installs the project as a distribution as-is.
Documentation tasks
-------------------
javadoc - Generates Javadoc API documentation for the main source code.
Help tasks
----------
buildEnvironment - Displays all buildscript dependencies declared in root project 'Gadgetbridge'.
components - Displays the components produced by root project 'Gadgetbridge'. [incubating]
dependencies - Displays all dependencies declared in root project 'Gadgetbridge'.
dependencyInsight - Displays the insight into a specific dependency in root project 'Gadgetbridge'.
dependentComponents - Displays the dependent components of components in root project 'Gadgetbridge'. [incubating]
help - Displays a help message.
model - Displays the configuration model of root project 'Gadgetbridge'. [incubating]
projects - Displays the sub-projects of root project 'Gadgetbridge'.
properties - Displays the properties of root project 'Gadgetbridge'.
tasks - Displays the tasks runnable from root project 'Gadgetbridge' (some of the displayed tasks may belong to subprojects).
Install tasks
-------------
uninstallAll - Uninstall all applications.
Verification tasks
------------------
check - Runs all checks.
connectedCheck - Runs all device checks on currently connected devices.
deviceCheck - Runs all device checks using Device Providers and Test Servers.
test - Runs the unit tests.
To see all tasks and more detail, run gradlew tasks --all
To see more detail about a task, run gradlew help --task <task>
BUILD SUCCESSFUL in 1s
1 actionable task: 1 executed
Ok, so with dockerfile described here : https://ncona.com/2018/07/android-development-with-docker-2/ I've been able to build an APK.
I should be able to help you when I'll receive my watch.
Thats great but why the hell you need docker for that?
I don't want to install Android SDK (or even Java) if I can avoid, hence I try to use Docker as most as possible.
That's a very good reason. I hate java so 馃憤
@Poulpatine
Please checkout amazfit-gtr-test and try to connect (needs auth key extracted from mi fit)
Thanks, I'll do that once I'll have it :smile:
Basic, incomplete and somehow broken support landed in master. But the device connects and does something.
I have added an incomplete stub to wiki, at least mentioning pairing. If anyone with this gadget can include list of supported features, for example by simply copying things from Bip or other device, it would be great.
In master notifications seem to work according to my contact ;)
I've been able to connect the Watch with Gadgetbridge compiled from master.
For the moment I can see that notifications and cardiac frequency/sleeping monitor are working correctly.
@Poulpatine
When you configure the visible menu items (they are surely wrong) with the gear icon on the device card in Gadgetbridge, does it change anything? Do you have missing menus? What are the menus and how was the default order?
@ashimokawa No, nothing changes, and yes some of them are missing.
Here are the lists (ordered):
On gadgetbridge :
Alipay (shortcut)
Weather (shortcut)
State
Activity
Weather
Alarms
Timer
Compass
Settings
Alipay
On the watch :
State
Notifications
Music
Cardiac frequency
Weather
Sport
Activity
Alarms
Reminder
More
Settings
Most helpful comment
I don't want to install Android SDK (or even Java) if I can avoid, hence I try to use Docker as most as possible.