Search in Pinguino World !!

Saturday, February 21, 2009

Pinguino with LA FONERA

we worked Friday with Benoit espinola on the link beetween LA FONERA and Pinguino. It Works !!
The FONERA was flashed with openwrt 7.09 and the ser2net package was installed. A small interface was build to convert 3,3V signal from the ttyS0 to 5V for the PIC UART.
The last step is to link a FONERA 2 with Pinguino but it seems that i must write a driver for USB.
Benoit Espinola wrote a small processing sketch to test the link:

boolean onoff;

Client c;
String data;

void setup() {
size(200, 200);
onoff = true;
c = new Client(this, "", 2001); // Connect to FONERA on port 2001
c.write("W01"); // write W output (0) state of the output (1)
// this is the protocol we defined in the pinguino program

void draw() {
if (c.available() > 0) { // If there's incoming data from the client...
data = c.readString(); // ...then grab it and print it

// press the mouse change the state of the output

void mousePressed(){
onoff = !onoff;
c.write("W0" + int(onoff));

// the led is darked when program stop

void stop(){

Nice job Benoit !!

No comments: