Search in Pinguino World !!

Thursday, November 25, 2010

Pinguino Contest is Open

Hi Guys,

Pinguino contest is open !!
This contest was initiated by ARDE and Boops.


We are pleased to announce that Microchip is sponsoring this contest. So, if you want to be the winner, you need now to fill in the form to join all the competitors.

What can you win ?

First prize: the best !!
PicKit3 programmer
Pinguino 2550 ARDE on a breadboard
GPS development board

3 blank 18F4550
Second prize the best optimisation !!

Pinguino 2550 ARDE

Solar cell 5V 250 mAH

3 blank 18F4550
3 blank 18F2550
Third prize: Special prize of the jury !!

Pinguino 2550 ARDE


3 blank 18F2550

Everybody can join us for this challenge. More info will be published soon on www.hackinglab.org.
For spanish translation and complete rules of the contest, please visit this link.

Have fun !!
Jean-Pierre


Tuesday, November 16, 2010

Pinguino CDC and Processing

Hi guys,

On linux, we have some problems to use the Serial object to communicate with Pinguino CDC.
Unfortunately, the RXTXbin module of JAVA don't recognize the /dev/ttyACM0 port.
I found a solution to fix this problem, and a simple working example is detailed here.

Create a symbolic link from /dev/ttyACM0 to a more popular name for a serial device ( i chose /dev/ttyS20 )

sudo ln -s /dev/ttyACM0 /dev/ttyS20

Now the Pinguino side of my fantastic application !!
// Pinguino cdc with processing
// Jean-Pierre Mandon 2010

unsigned char i;

void setup()
{
for (i=0;i<4;i++)
{
pinMode(i,OUTPUT);
digitalWrite(i,LOW);
}
}

unsigned char receivedbyte;
unsigned char rxstr[64];

void loop()
{
// Use the run led to check if a terminal is connected
if (CONTROL_LINE) PORTAbits.RA4=1;
else PORTAbits.RA4=0;

// receive a string from the USB uart and send it on the uart
receivedbyte=CDC.read(rxstr);
if (receivedbyte>0)
{
rxstr[receivedbyte]=0; // to make received character(s) a string
switch (rxstr[0])
{
case 'S':switch(rxstr[1]) // SET
{
case '0': digitalWrite(0,HIGH); // Pin 0 ON
break;
case '1': digitalWrite(1,HIGH); // Pin 1 ON
break;
case '2': digitalWrite(2,HIGH); // Pin 2 ON
break;
case '3': digitalWrite(3,HIGH); // Pin 3 ON
break;
}
break;
case 'R':switch(rxstr[1]) // RESET
{
case '0': digitalWrite(0,LOW); // Pin 0 OFF
break;
case '1': digitalWrite(1,LOW); // Pin 1 OFF
break;
case '2': digitalWrite(2,LOW); // Pin 2 OFF
break;
case '3': digitalWrite(3,LOW); // Pin 3 OFF
break;
}
break;
}
}
}
The processing side assume that /dev/ttyS20 is used as the first serial port:
import processing.serial.*;

Serial myPort;
String port[];
int i;

void setup()
{
port=Serial.list();
println(port[0]);
myPort=new Serial(this,port[0],115200);
}

void draw()
{
for (i=0;i<4;i++)
{
myPort.write("S"+str(i));
delay(50);
myPort.write("R"+str(i));
delay(50);
}
}

void stop()
{
myPort.stop();
}

And now the schematic:


Have fun
Jean-Pierre

Monday, November 15, 2010

Pinguino Board available in USA

Pinguino 4550 is now available in USA at EDTP store.

You can contact Fred for more info.

EDTP ELECTRONICS

Sunday, November 14, 2010

Pinguino32X pinout


This is the first pinout for Pinguino 32 bits. The digitalw.c library is in progress.
74 I/O on this board !!

Monday, November 8, 2010

Pinguino Contest

Yet another event organised by ARDE and Boops. This spanish robotic association is very active and want to boost the development of Pinguino.
A Pinguino Contest is now open !!
If you plan to build a nice robot or drive your home with a Pinguino, it's time to fill the form on boops website.

The contest rules are in spanish but will be soon translated to english.

Boops blog with complete rules

Thursday, November 4, 2010

Pinguino drive a led display.

Olivier drive this led display with a 18F2550 Pinguino.
Maybe this library could be incorporated in the next IDE version with his support.



I would like build a such display for Christmas !!

More info on Olivier website.

Wednesday, November 3, 2010

PartyBot !!



Jesus and ARDE designed this nice robot to show robotic technology in Campus Party.
Pinguino is used as the brain.
Their wiki is well documented with nice 3D view.

Tuesday, November 2, 2010

Pinguino PIC32


Now development is really started on PIC32. We are working with the UBW32 board and Brian ( designer of this board ) like the idea of Pinguino with his UBW32 board.
This board is cheap and can be purchased on the net.
We are developing some libraries to release Pinguino with PIC32 support. At the beginning, only digital I/O and serial will be implemented, some peripheral libraries will be easy to port ( servo, LCD ).

Monday, November 1, 2010

Pinguino as a real time clock

The timer 1 can be used as a real time clock. I wrote this simple example to test this function.
It will be incorporated to the tutorial website.



and this is the code to start the clock and display the result on the serial:


// Real time clock with a 18F2550 and Pinguino
// Jean-Pierre Mandon 2010
byte hours,mins,secs;
void setup()
{
// configure TIMER 1 to be used as RTCC
TMR1H=0x80;
TMR1L=0;
T1CON=0b00001111;

// init current time
hours=12;
mins=0;
secs=0;

// init interrupt for RTCC module
PIE1bits.TMR1IE=1;
INTCONbits.PEIE=1;
INTCONbits.GIE=1;

// init Serial to display time
Serial.begin(9600);
Serial.print("\r\n");
Serial.print("Pinguino clock\r\n");
}


// timer 1 is interrupt driven
void UserInterrupt()
{
TMR1H=0x80;
PIR1bits.TMR1IF=0;
secs++;
if (secs==60)
{
secs=0;
mins++;
if (mins==60)
{
mins=0;
hours++;
if (hours==24) hours=0;
}
}
}

// The main loop display time on a serial terminal
void loop()
{
if (hours<10) Serial.print("0");
Serial.print(hours,DEC);
Serial.print(":");
if (mins<10) Serial.print("0");
Serial.print(mins,DEC);
Serial.print(":");
if (secs<10) Serial.print("0");
Serial.print(secs,DEC);
Serial.print("\r");
}