Skip to content

Conversation

@andrebstv
Copy link

I`ve created a specific alarm detection for InMotion. This wheel has some internal overload alarms that are transmitted through the bluetooth connection. My patch sifts through then and presents the user with an audible alarm if it so chooses to enable it in the preferences tab.

implementation 'com.github.PhilJay:MPAndroidChart:v3.0.0'
implementation "com.github.hotchemi:permissionsdispatcher:2.2.0"
annotationProcessor "com.github.hotchemi:permissionsdispatcher-processor:2.2.0"
compile fileTree(dir: 'libs', include: ['*.jar'])
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

compile instruction deprecated, please update Android studio/graddle

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was probably added automatically... or stayed there when I merged with your most current code. Will update.

android:key="@string/alarms_enabled"
android:title="Enable Alarms"
android:summary="Allow the phone to vibrate as a warning" />

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure that it is good idea to put inmotion-specific option to general menu. Maybe it's better to move it to inmotion_preferences, or at least make it disabled by default?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Youre right. Ill move it.

break;
case GENERAL:
if (mp.isPlaying() == false) {
mp = MediaPlayer.create(mContext, R.raw.bicycle_bell);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why bicycle_bell? I think it should be separate sound, something like inmotion sound.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a //TODO to change it. Will do, use the SCV default sound for that.

@@ -1,12 +1,15 @@
package com.cooper.wheellog;

import android.app.Activity;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure that it is needed?
import android.app.Activity;
import android.app.Application;

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably not. Will check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants