-
-
Notifications
You must be signed in to change notification settings - Fork 919
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
Add capacitor android #3955
Add capacitor android #3955
Conversation
✅ Deploy Preview for origin-betaflight-app ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
This comment has been minimized.
This comment has been minimized.
a58eb63
to
192f8bd
Compare
Quality Gate failedFailed conditions |
Rebased against master |
Would love a solution which not only includes Android but also IOS support |
True. I don't have Mac or Iphone devices, so other must do this work. But yes, the library selected for serial must be compatible with both systems to simplify things. |
192f8bd
to
8ba30a7
Compare
@haslinghuis rebased. If we plan to move forward with this, I think we need to merge this as is. I've tried to make this work (Betaflight in Android), but I was not able to make hot reload working with capacitor on Android. The app crashes. And without this, it's a nightmare to develop against this (I tried to add a serial library but without hot reloading it's very difficult and slow). I think is better to merge, and let others try with little PRs to make this advance. If for some reason we decide to remove this later, it's as easy as remove the I've added a little of branding with Betaflight icon to this PR, but it does not work too well, but for a first version it's ok while we make this work. |
It's only the basic code to start as base. It needs a lot of fixes/changes to make it functional.
8ba30a7
to
a0416e3
Compare
Rebased again against master... |
I think I have it working with "live reload", so it's a first step. The problem is that it needs some "manual" changes, that I can't push.
|
Added new commit with "basic" reload.
I will try to make the copy IP step automatic, but I don't know if I will be able. |
Sorry, it seems the --configuration parameter only works with the ionic command, not with the npx one. So I need to rethink this... |
947cb76
to
a0416e3
Compare
I reverted the latest change. We will need to do the live reload manually at this moment. The documentation says that the config file can be a .ts file, so it can be generated dynamically. I don't know if this can be a good approach. |
I've added some very basic instructions for Android to the README, only development at this stage, because it's not functional, but can help if someone want to give it a try. |
i had to
afterward, i could not continue the entire |
The result using PWA it's the same than with this PR if you build it. The problem it's the web serial, fails and crashes the loading. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- may need another rebase :( i saw flashing bar not on bottom; otherwise still works on PC.
- approving for the workflow
This is a PR trying to add Capacitor support to the Configurator.
I make it in a draft state because I was trying to make Serial working and I'm having problems to debug it. I've been trying to debug with an FC connected. I have tried wifi debug without luck with a real device, and usb passthrough with the emulator without luck neither. Maybe other with more knowledge (or luck) can give it a try.
I have three commits, to try to let the things clear and be able to divide this PR in parts in the future:
chrome
var here)webSerial.js
file, is where I was trying to do some tests.To test this PR you need to have Android Studio installed. You need some Virtual emulator created (or a real device connected in debug mode). I've added some commands to the
package.json
to make this easier. The steps are:0. Execute a
yarn install
to update the packages.yarn build
yarn cap:sync
yarn cap:android
(you can use too thenpx cap open android
command to open Android Studio with the app and execute from there).Alternativelly to test this faster I've added a
yarn android
command that does the steps 1-2-3 above in one. The hot deploy is not working in this version, it's in the todo list.