Hi guy!
Now you can see the PRU's head with eyes and ears...
All servo are mounted, now I need a neck...
Something like that.
Do you like it?
Saturday, September 22, 2012
Wednesday, September 19, 2012
The head - prototype
Monday, September 17, 2012
Why only two wheels?
When this project was born, I immediately asked me what kind of traction.
A real cat would have four legs, but implement them properly, ensuring proper locomotion, would require a very careful construction and a considerable difficulty in achieving movements.
But since I wanted to make it work and I did not want to stop by excessive technical problems, I decided to reduce everything to a system with two wheels and a jockey wheel.
After all, my sources of inspiration were two:
My cat "Ciccio" and K9, the faithful and robotic friend of Doctor Who.
Make It Simple, Stupid!
:)
Tuesday, September 11, 2012
Pan & Tilt preview
The head can pan and tilt, this movement is ensured by two servos.
In this image you can see the study plans of preliminary mechanical parts.
The final draft envisages the creation of a single sheet of acrylic co parts made of laser cut and related joints.
Monday, September 10, 2012
The Modbus library
The head source uses a lib for modbus slave protocol.
The source is here:
https://sites.google.com/site/jpmzometa/Home
Using the new IDE 1.0.1 there are two error:
1) in file ModbusSlave.h the line
#include "WProgram.h"
must change with
#include "Arduino.h"
2) in file ModbusSlave.cpp the line 250
Serial.print(query[i], BYTE);
must change with
Serial.write(query[i]);
The source is here:
https://sites.google.com/site/jpmzometa/Home
Using the new IDE 1.0.1 there are two error:
1) in file ModbusSlave.h the line
#include "WProgram.h"
must change with
#include "Arduino.h"
2) in file ModbusSlave.cpp the line 250
Serial.print(query[i], BYTE);
must change with
Serial.write(query[i]);
see you soon...
Friday, September 7, 2012
Thursday, September 6, 2012
The head - firmware beta release
This is the beta version of the firmware insde the Head-Arduino
[code]
/*
P.R.U. Personal Robotic Unit
A robot with cat's personality
------------------------------
Head firmware:
Head Pan & tilt
2 ears servo rotating
2 eyes 4 led
*/
#include <Servo.h>
#include <ModbusSlave.h>
/* First step MBS: create an instance */
ModbusSlave mbs;
Servo EarLeft;
Servo EarRight;
Servo Pan;
Servo Tilt;
/* slave registers */
enum {
MB_PAN,
MB_TILT,
MB_R_EYE,
MB_L_EYE,
MB_R_EAR,
MB_L_EAR,
MB_REGS /* total number of registers on slave */
};
int regs[MB_REGS];
unsigned long wdog = 0; /* watchdog */
unsigned long tprev = 0; /* previous time*/
void set_eye(char eye, boolean l1, boolean l2, boolean l3, boolean l4);
void setup()
{
/* the Modbus slave configuration parameters */
const unsigned char SLAVE = 10;
const long BAUD = 19200;
const char PARITY = 'e';
const char TXENPIN = 7;
/* Second step MBS: configure */
mbs.configure(SLAVE,BAUD,PARITY,TXENPIN);
pinMode(9, OUTPUT);
pinMode(10, OUTPUT);
pinMode(A4, OUTPUT);
pinMode(A5, OUTPUT);
pinMode(2, OUTPUT);
pinMode(3, OUTPUT);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
pinMode(A0, OUTPUT);
pinMode(A1, OUTPUT);
pinMode(A2, OUTPUT);
pinMode(A3, OUTPUT);
Pan.attach(9);
Tilt.attach(10);
EarLeft.attach(A4);
EarRight.attach(A5);
}
void loop()
{
/* Third and las step MBS: update in loop*/
if(mbs.update(regs, MB_REGS))
wdog = millis();
if ((millis() - wdog) > 5000) { /* no comms in 5 sec */
// to do
}
/* the values in regs are set by the modbus master */
// Test Pan
if(regs[MB_PAN] != Pan.read())
Pan.write(regs[MB_PAN]);
// Test Tilt
if(regs[MB_TILT] != Tilt.read())
Tilt.write(regs[MB_TILT]);
// Test Ear Left
if(regs[MB_L_EAR] != EarLeft.read())
EarLeft.write(regs[MB_L_EAR]);
// Test Ear Right
if(regs[MB_R_EAR] != EarRight.read())
EarRight.write(regs[MB_R_EAR]);
// Test Left Eye
switch(regs[MB_L_EYE]) {
case 0: // Ronf
set_eye(1, LOW, LOW, LOW, LOW);
break;
case 10: // Mmmmmaaaoooo
set_eye(1, LOW, HIGH, HIGH, LOW);
break;
case 11: // Look R
set_eye(1, LOW, HIGH, LOW, LOW);
break;
case 12: // Look R
set_eye(1, LOW, LOW, HIGH, LOW);
break;
case 13: // Look Up
set_eye(1, HIGH, LOW, LOW, LOW);
break;
case 14: // Looh D
set_eye(1, LOW, LOW, LOW, HIGH);
break;
case 15: // OMG
set_eye(1, HIGH, HIGH, HIGH, HIGH);
break;
}
// Test Right Eye
switch(regs[MB_R_EYE]) {
case 0: // Ronf
set_eye(0, LOW, LOW, LOW, LOW);
break;
case 10: // Mmmmmaaaoooo
set_eye(0, LOW, HIGH, HIGH, LOW);
break;
case 11: // Look R
set_eye(0, LOW, HIGH, LOW, LOW);
break;
case 12: // Look R
set_eye(0, LOW, LOW, HIGH, LOW);
break;
case 13: // Look Up
set_eye(0, HIGH, LOW, LOW, LOW);
break;
case 14: // Looh D
set_eye(0, LOW, LOW, LOW, HIGH);
break;
case 15: // OMG
set_eye(0, HIGH, HIGH, HIGH, HIGH);
break;
}
}
void set_eye(char eye, boolean l1, boolean l2, boolean l3, boolean l4)
{
if (eye==0) {
digitalWrite(A0, l1);
digitalWrite(A1, l2);
digitalWrite(A2, l3);
digitalWrite(A3, l4);
}
if (eye==1) {
digitalWrite(2, l1);
digitalWrite(3, l2);
digitalWrite(4, l3);
digitalWrite(5, l4);
}
}
[/code]
[code]
/*
P.R.U. Personal Robotic Unit
A robot with cat's personality
------------------------------
Head firmware:
Head Pan & tilt
2 ears servo rotating
2 eyes 4 led
*/
#include <Servo.h>
#include <ModbusSlave.h>
/* First step MBS: create an instance */
ModbusSlave mbs;
Servo EarLeft;
Servo EarRight;
Servo Pan;
Servo Tilt;
/* slave registers */
enum {
MB_PAN,
MB_TILT,
MB_R_EYE,
MB_L_EYE,
MB_R_EAR,
MB_L_EAR,
MB_REGS /* total number of registers on slave */
};
int regs[MB_REGS];
unsigned long wdog = 0; /* watchdog */
unsigned long tprev = 0; /* previous time*/
void set_eye(char eye, boolean l1, boolean l2, boolean l3, boolean l4);
void setup()
{
/* the Modbus slave configuration parameters */
const unsigned char SLAVE = 10;
const long BAUD = 19200;
const char PARITY = 'e';
const char TXENPIN = 7;
/* Second step MBS: configure */
mbs.configure(SLAVE,BAUD,PARITY,TXENPIN);
pinMode(9, OUTPUT);
pinMode(10, OUTPUT);
pinMode(A4, OUTPUT);
pinMode(A5, OUTPUT);
pinMode(2, OUTPUT);
pinMode(3, OUTPUT);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
pinMode(A0, OUTPUT);
pinMode(A1, OUTPUT);
pinMode(A2, OUTPUT);
pinMode(A3, OUTPUT);
Pan.attach(9);
Tilt.attach(10);
EarLeft.attach(A4);
EarRight.attach(A5);
}
void loop()
{
/* Third and las step MBS: update in loop*/
if(mbs.update(regs, MB_REGS))
wdog = millis();
if ((millis() - wdog) > 5000) { /* no comms in 5 sec */
// to do
}
/* the values in regs are set by the modbus master */
// Test Pan
if(regs[MB_PAN] != Pan.read())
Pan.write(regs[MB_PAN]);
// Test Tilt
if(regs[MB_TILT] != Tilt.read())
Tilt.write(regs[MB_TILT]);
// Test Ear Left
if(regs[MB_L_EAR] != EarLeft.read())
EarLeft.write(regs[MB_L_EAR]);
// Test Ear Right
if(regs[MB_R_EAR] != EarRight.read())
EarRight.write(regs[MB_R_EAR]);
// Test Left Eye
switch(regs[MB_L_EYE]) {
case 0: // Ronf
set_eye(1, LOW, LOW, LOW, LOW);
break;
case 10: // Mmmmmaaaoooo
set_eye(1, LOW, HIGH, HIGH, LOW);
break;
case 11: // Look R
set_eye(1, LOW, HIGH, LOW, LOW);
break;
case 12: // Look R
set_eye(1, LOW, LOW, HIGH, LOW);
break;
case 13: // Look Up
set_eye(1, HIGH, LOW, LOW, LOW);
break;
case 14: // Looh D
set_eye(1, LOW, LOW, LOW, HIGH);
break;
case 15: // OMG
set_eye(1, HIGH, HIGH, HIGH, HIGH);
break;
}
// Test Right Eye
switch(regs[MB_R_EYE]) {
case 0: // Ronf
set_eye(0, LOW, LOW, LOW, LOW);
break;
case 10: // Mmmmmaaaoooo
set_eye(0, LOW, HIGH, HIGH, LOW);
break;
case 11: // Look R
set_eye(0, LOW, HIGH, LOW, LOW);
break;
case 12: // Look R
set_eye(0, LOW, LOW, HIGH, LOW);
break;
case 13: // Look Up
set_eye(0, HIGH, LOW, LOW, LOW);
break;
case 14: // Looh D
set_eye(0, LOW, LOW, LOW, HIGH);
break;
case 15: // OMG
set_eye(0, HIGH, HIGH, HIGH, HIGH);
break;
}
}
void set_eye(char eye, boolean l1, boolean l2, boolean l3, boolean l4)
{
if (eye==0) {
digitalWrite(A0, l1);
digitalWrite(A1, l2);
digitalWrite(A2, l3);
digitalWrite(A3, l4);
}
if (eye==1) {
digitalWrite(2, l1);
digitalWrite(3, l2);
digitalWrite(4, l3);
digitalWrite(5, l4);
}
}
[/code]
Wednesday, September 5, 2012
The head inside
The PRU's head is very complex.
The electronic hearth is a board arduino-like, the source code is open.
You can add new features and share with the community.
8 led for two eyes, may expressions, funny element.
A hypothesis protocol provides several commands to the various expressions like:
@EL1F# (Eye Left (led 1) (maximum brightness))
Another possibility is uil Modbus protocol and the various registers to control eyes
4 servos (2 for ears and 2 for pan & tilt)
Same hypothesis for the pan & tilt control protocol.
simple or modbus?
Big question... :)
The electronic hearth is a board arduino-like, the source code is open.
You can add new features and share with the community.
8 led for two eyes, may expressions, funny element.
A hypothesis protocol provides several commands to the various expressions like:
@EL1F# (Eye Left (led 1) (maximum brightness))
Another possibility is uil Modbus protocol and the various registers to control eyes
4 servos (2 for ears and 2 for pan & tilt)
Same hypothesis for the pan & tilt control protocol.
simple or modbus?
Big question... :)
Monday, September 3, 2012
Saturday, September 1, 2012
C'mon to the locomotion
There are many methods of locomotion for a robot: legs, wheels and tracks.
PRU is a very simple robot, designed for home use, so I decided to use just two wheels and a ball caster.
The motor are simple gearmotor and the wheels have silicone tires and measure 60 mm (2.36") in diameter.
PRU is a very simple robot, designed for home use, so I decided to use just two wheels and a ball caster.
The motor are simple gearmotor and the wheels have silicone tires and measure 60 mm (2.36") in diameter.
Thursday, August 30, 2012
The body
I like cats... :)
I like fat cats...
This is the idea for the body
Do you like?
The head is very complex, with many movements and the body is simple, round and inspires tenderness.
Or not? :)
I like fat cats...
This is the idea for the body
Do you like?
The head is very complex, with many movements and the body is simple, round and inspires tenderness.
Or not? :)
The brain
I like Linux ;)
I like embedded circuits
The PRU's brain will be a very usefull board:
Aria G25 from ACME System in Rome.
FEATURES
I like embedded circuits
The PRU's brain will be a very usefull board:
Aria G25 from ACME System in Rome.
- ARM9 @ 400Mhz CPU Atmel AT91SAM9G25
- 128MB or 256MB of DDR2 RAM
- 10/100 Mbit Ethernet interface
- up to 3 USB 2.0 host ports:
- one hi-speed host/device
- one hi-speed host
- one full-speed
- up to 6 serial lines
- up to 2 I2C buses
- up to 2 SPI buses
- up to 60 GPIO lines
- 4 A/D converter @ 10 bit
- Power consumption: 0.3 Watt
- Operative temperature range: 0-70 °C
- Size: 40 x 40 mm
- RoHS compliant
- Low EMI
- I/O voltage: 3.3 volt
- Pads: pitch 1.27 mm
- User configurable led on board
- Single line power supply at 3.3 volt
- Debian Linux on bootable microSD
Wednesday, August 29, 2012
The eyes
For the eyes I like a duoble cross with four leds
With this configuration we can express many situation, like this:
Combined with the ears rotation about 180 degrees and the head's pan & tilt, I hope you like the set.
With this configuration we can express many situation, like this:
Combined with the ears rotation about 180 degrees and the head's pan & tilt, I hope you like the set.
The beginning
I love robots and cats too.
The idea is simple:
to develop a funny robot with cat's personality.
I'm thinking about a simple robot with two wheels and an head with pan & tilt, two mobile ears and bright eyes led.
Something like this.
Or not...
The idea is simple:
to develop a funny robot with cat's personality.
I'm thinking about a simple robot with two wheels and an head with pan & tilt, two mobile ears and bright eyes led.
Something like this.
Or not...
Subscribe to:
Posts (Atom)