ChibiOS STM32F4 usb shell + Javascript interpreter

This forum is about you. Feel free to discuss anything is related to embedded and electronics, your awesome projects, your ideas, your announcements, not necessarily related to ChibiOS but to embedded in general. This forum is NOT for support.
mribelotta
Posts: 5
Joined: Sun Jul 14, 2013 11:36 pm

ChibiOS STM32F4 usb shell + Javascript interpreter

Postby mribelotta » Sun Jul 14, 2013 11:44 pm

Hi Guys.
I start this project (in very early stage) to build an enviroment for embedded scripting centered (but not limited) into javascript TinyJS interpreter trying to emulate the features found in Esrurino and eLua system but using a real RTOS under the interpreter.
https://github.com/martinribelotta/ChibiOS-JS
Any comments/ideas?

User avatar
Giovanni
Site Admin
Posts: 13008
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 742 times
Been thanked: 620 times
Contact:

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby Giovanni » Mon Jul 15, 2013 6:56 am

Hi,

Very interesting project, would the RTOS primitives be available from JS? I can imagine quite a few applications where such an hybrid system could be useful.

One common request is to have parts of the application "loadable" from external media, I imagine this could be solved by loading a script, is this scenario something you considered?

Giovanni

mribelotta
Posts: 5
Joined: Sun Jul 14, 2013 11:36 pm

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby mribelotta » Mon Jul 15, 2013 1:22 pm

Yes, the idea is load scripts from VFS (rom/fat/ram/nfs) but the project is in early stages (my time si very limited in to week)

Respect of the RTOS API exported to JS I am undecided between a direct export API one to one or opt for a POSIX abstraction layer (or similar)

Important note: At this moment, the most important problem is the JS memory manager because this use "new/delete" from the libstdc++ (wrapper for malloc/free) instead of ChibiOS pool allocator.

mabl
Posts: 417
Joined: Tue Dec 21, 2010 10:19 am
Location: Karlsruhe, Germany
Been thanked: 1 time
Contact:

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby mabl » Sat Jul 27, 2013 4:45 pm

I wonder if it is not a better idea to use a virtual machine and compile the program to P-Code first, like PAWN. Interestingly sombody had the idea already - even with ChibiOS:
http://airlab.elet.polimi.it/index.php/ ... _platforms

I wonder what came out of it?

mabl
Posts: 417
Joined: Tue Dec 21, 2010 10:19 am
Location: Karlsruhe, Germany
Been thanked: 1 time
Contact:

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby mabl » Sat Jul 27, 2013 4:53 pm

Digging further, there are other people doing stuff like this with Chibios!
https://code.google.com/p/chibios-embrio/

I did not notice these before!

mribelotta
Posts: 5
Joined: Sun Jul 14, 2013 11:36 pm

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby mribelotta » Wed Jul 31, 2013 11:51 pm

Other interesting project on this line:

https://github.com/mimaki/stm32-mruby

The first point of my project is provide a stand alone system (through support of VGA/PS2) usable on out-of-door enviroments. In this view, the interpreter-only support is not much atractive than elf-loader system.

chradev
Posts: 48
Joined: Sun Apr 28, 2013 6:52 am

Re: ChibiOS STM32F4 usb shell + Javascript interpreter

Postby chradev » Fri Feb 27, 2015 3:40 pm

Hi Everybody,

I am trying to build (in Eclipse on Windows 7 64bit) and run (on STM32F4Discovery and my own board with STM32F405) your project ChibiOS-JS. I am using gcc-arm-none-eabi-4_8-140405 (part of ChibiOS 2.6.5) to compile and link application but without success. I have tried many thing incl. makefile project based on ChibiOS demo STM32F4xx-USB_CDC and adding all staff from ChibiOS-JS without success as well.

After lot of probes the successfully built application hangs not returning from ngshell_init.

Could somebody pleased to help me in my attempts to build and run ChibiOS-JS?
I prefer to use free tool chain and makefile project whit the latest and unmodified ChibiOS version.

Sorry for posting on this very old thread but I cannot succeed to e-mail Martin.

Best regards
Chris


Return to “User Projects”

Who is online

Users browsing this forum: No registered users and 2 guests