Communication is managed by Stephane Cousot Library and USB link.
Stephane example program is loaded in the Pinguino with the IDE.
A led is connected on PIN 0 of Pinguino.
// How to blink a led on PIN 0 with processing
// Jean-pierre Mandon 2010
import hypermedia.pinguino.*; // import library
Pinguino board; // pinguino object
void setup() {
size( 380, 180 ); // size the window application
board = new Pinguino( this ); // connect to Pinguino board
}
void draw() {
background(0);
fill(0);
if (board.digitalRead(0)==Pinguino.LOW)
board.digitalWrite(0,Pinguino.HIGH); // PIN 0 = 1
else
{ board.digitalWrite(0,Pinguino.LOW); // PIN 0 = 0
fill(255,0,0);
}
rect(170,70,40,40);
delay(100);
}
Stephane processing Library can be downloaded here.
The pinguino side program is here.