Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[androiddebugbridge] add fallback to start package channel #49

Merged
merged 5 commits into from
Apr 2, 2021

Conversation

GiviMAD
Copy link
Contributor

@GiviMAD GiviMAD commented Mar 26, 2021

Add fallback to the start package channel, using monkey command to open applications instead of am on devices which doesn't support the -n parameter (devices under android 8).

@J-N-K J-N-K requested a review from Trinitus01 March 26, 2021 11:16
@Trinitus01
Copy link
Contributor

Does the openURL work on your device? (Because of the -a and -d parameters? Or does it also need a fallback?

@Trinitus01
Copy link
Contributor

Should i remove all the result empty checks (except the one for the logcat result) in a new pr or will you change it?

@GiviMAD
Copy link
Contributor Author

GiviMAD commented Mar 28, 2021

Hi,
The openURL channel is working correctly on my device (android 7.1.2) so no need for a fallback on my side.
And yes I think that we can remove those empty results and raised exception exceeding the ones that depends on a log rotation as you explained to me earlier on a separate pr.

Trinitus01
Trinitus01 previously approved these changes Mar 31, 2021
@Trinitus01
Copy link
Contributor

tested and works like it should

@J-N-K
Copy link
Member

J-N-K commented Mar 31, 2021

I‘m not sure why this happened, but can you please rebase on main? There are some changes which do not belong here.

@Trinitus01
Copy link
Contributor

Trinitus01 commented Mar 31, 2021

There is some irobot binding stuff?!?

Signed-off-by: Miguel <miguelwork92@gmail.com>
Signed-off-by: Miguel <miguelwork92@gmail.com>
@GiviMAD
Copy link
Contributor Author

GiviMAD commented Mar 31, 2021

My fault, it's fixed now.

Trinitus01
Trinitus01 approved these changes Mar 31, 2021
@GiviMAD GiviMAD requested a review from J-N-K April 1, 2021 08:56
@Trinitus01
Copy link
Contributor

For isHDMIOn() it seems the first command can fail sometimes but the fallback command is not supported by the device. If this happens it never goes back to the first command. I don't know why it can fail, maybe the result is empty between it switches from 0 to 1 and the cat fetches the result between the two states?!? To get out of the fallback we could remove the fallback from the map if the fallback method runs into an exception. So it will try both (or more fallbacks in the future) again. What do you think about that? How to ensure it tries the first command again if both method fail?

Signed-off-by: Miguel <miguelwork92@gmail.com>
Signed-off-by: Miguel <miguelwork92@gmail.com>
@J-N-K J-N-K merged commit ed88407 into smarthomej:main Apr 2, 2021
@J-N-K J-N-K added this to the 3.1.1 milestone Apr 2, 2021
@J-N-K J-N-K added the enhancement New feature or request label Apr 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants