The idea is to create a simple web-based GUI that will:
- show the current contents of the screen
- let the user click on the screen and send those clicks as taps to the emulator
- log each tap so they can then be replayed with a script
@migueldar is working on this in D1354
There are some issues with preact, to which I will look into ASAP
@migueldar I’ve sent an update to your diff at D1354.
The preact build script works now. Please see the changes I’ve made at https://hub.sealcode.org/D1354?vs=6340&id=6341#toc.
I changed the file from jsx to tsx, so we can use typescript there.
I moved it to ./src subdirectory, and made the output go to ./dist subdirectory - that’s a pattern you can see in many different projects, where there is a designated directory to keep compiled code in.
I put the build script in the package.json, so it can be simply run with
npm run build.
And most importantly - I’ve fixed the React dependencies thing. By adding
--jsx-factory=h --jsx-fragment=Fragment to the esbuild script, it now know to use Preact instead of the (sadly default) React
I tested it locally (by just setting up a static http server in the
http_server/code directory and it worked!
Should now work from Docker, as well, hopefully without any further adjustments
how can i pull the changes you did to the diff??
On your work directory, run
arc patch D1354 - it will create a new branch and put the latest state of the diff in it.
(In case you want to rewind to a different version of the diff in the future, you can copy the diff ID from the second column of this table:
arc patch --diff 6340, for example)
@migueldar I’ve requested some changes in D1354. I had trouble getting the endpoints to activate
@kuba-orlik , the task is not complete, i just pushed it a while ago as a draft because i had some problems with jsx and you told me to push it for you to take a look, whenever i finish it i will ping you to check it.
Aaaah, ok. I remember now, sorry. I’ll make sure to remind you to mark it as “planned changes” next time
Nevertheless, I’ve also added some other comments which you might want to take into consideration
yes i saw it, will take into consideration
@migueldar ping D1354. Unfortunately it times out for me
I know there are still some things to do, but i wanted to point out that the protocol of transmition between android and http_server should be taken from layer 3 communication to layer 4(tcp) communication, it will make everything so much easier…
Oh, what is it using now? Not TCP?
you are right, but i think im somehow not using the protocol to the fullest, i must think about it more
If I’m not mistaken, we use “raw” TCP sockets. Maybe we could switch to HTTP to make it more manageable?
no no, i wanna be working on layer 4, but i have studied the tcp protocol recently and think i can improve some things
added some comments on D1354, ping me when you answer them :), btw sorry for taking so long, uni is requiring quite some time now
@migueldar I’ve replied to your comments, hope it helps!
Hello @kuba-orlik, can you please reply to the top comment:
(I just tryed running it myself and it gives no problems, however i cannot manage to clone the latest version, but i took the one i have locally, removed everything that wasnt committed (all the .gitignore has), and had no problems, it didnt timeout. Please try again but run npm i && npx zx start.mjs down && npx zx start.mjs up, also tell me how can i clone the latest version. If the issue persists we should schedule a call to see whats wrong.)
It was the most important one and you didnt reply. Also i added some new comments.
Ah! Sorry about that. Testing it right now.