Thursday, 26 December 2019

Raspberry-PI GPIO, Beaglebone GPIO, iMX6 GPIO C++/Scripting

GPIO RASPBERRY PI, Beaglebone

PWM RASPBERRY PI, Beaglebone

I2C RASPBERRY PI, Beaglebone




Rembix, engine, a simple no dependencies scripting engine for 

GPIO, PWM,I2C, SPI, UART

and

CURL,SSH,TCP


code excerpt

var l1 = PIO(26,  DIR_OUT, LOW,  "led");
var l2 = PIO(19,  DIR_OUT, HIGH, "led2");
var l3 = PIO(13,  DIR_OUT, LOW,  "led3");

function main(ctx)
{
    l1.set_value(0);
    l2.set_value(1);
    l3.set_value(1);
    return run_loop(program,1000);
}

function program(ctx, devs)
{
   l4.toogle(); 
   l1.toogle(); 
   l2.toogle(); 
   l3.toogle();  
   return true;
}
 

 

 

 



Check:

https://gist.github.com/comarius




No comments:

Post a Comment