Skip to content

neonious/low_native_api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

low_native_api

Support library for native modules for low.js writting in C/C++. These modules can be loaded by low.js programs, allowing the programs to be written in a mixture of JavaScript and C/C++.

Documentation

The full documentation can be found here: https://www.neonious.com/lowjs/documentation/lowjs-native-api.html

Example using a native module:

ON ESP32 MICROCONTROLLER OR LOW.JS SERVER WITH NEONIOUS IDE

Step 1: Compile the native module:

cd example
make clean
make esp32

Step 2:

Copy index.js and native.so (compiled in Step 1) to microcontroller via lowsync or neonious IDE and run!

ON PC WITH PLAIN LOW.JS

Step 1: Compile the native module:

cd example
make clean
make

Step 2: Run low.js script:

You can download the low binary from https://www.neonious.com/lowjs/downloads.html

low index.js

To see what is happening, take a look at index.js. It loads native.so which is compiled from native.cpp by the Makefile.

About

Library for native modules

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published