Page 1 of 1

MicroPython.js usage?

Posted: Sat Feb 08, 2020 4:38 pm
by jedie
Has somebody made a web page with the JavaScript port?

I know the pyboard emulator page.

Re: MicroPython.js usage?

Posted: Sun Feb 09, 2020 3:25 am
by jimmo
I posted a working example a few days ago here: viewtopic.php?f=2&t=7659

Note that the Pyboard emulator page is completely unrelated to micropython.js (i.e. the JavaScript port). It's based instead on running an ARM port in unicorn.js (i.e. a cut down qemu running in the browser). See https://github.com/micropython/micropython-unicorn

Re: MicroPython.js usage?

Posted: Sun Feb 09, 2020 2:55 pm
by jedie
Hm, okay. So nobody use it.

I like to try using it to get my old 6809 CPU Emulator running in the Browser : https://github.com/6809/MC6809

Re: MicroPython.js usage?

Posted: Mon Feb 10, 2020 4:43 pm
by jedie
I can't compile:

Code: Select all

...
In file included from mpconfigport.h:27:
In file included from /usr/lib/llvm-6.0/lib/clang/6.0.0/include/stdint.h:61:
/usr/include/stdint.h:26:10: fatal error: 'bits/libc-header-start.h' file not found
#include <bits/libc-header-start.h>
         ^~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [build/genhdr/qstr.i.last] Error 1
make: *** Deleting file 'build/genhdr/qstr.i.last'
I have libc6-dev installed. This packaged should have the missed file 'bits/libc-header-start.h' :?:

Re: MicroPython.js usage?

Posted: Mon Feb 10, 2020 9:55 pm
by jimmo
jedie wrote:
Sun Feb 09, 2020 2:55 pm
Hm, okay. So nobody use it.
I think (but may be mistaken) that it's used by Numworks for their simulator???
jedie wrote:
Mon Feb 10, 2020 4:43 pm
I can't compile
Need more information. Version of emscripten, linux distro, etc. How you're running make, etc, have you got any local modifications to the Makefile.

I was able to build it recently with the current emscripten Arch Linux package, the only issue I ran into was a very out-of-date ~.emscriptenrc which was telling it to still use fastcomp.

Re: MicroPython.js usage?

Posted: Mon Feb 10, 2020 10:12 pm
by jedie
I try to compile it via https://github.com/jedie/docker-micropython ... So i must install some more decencies...