Skip to content

Commit

Permalink
new head, cylinder and lamp+ new raspberry base
Browse files Browse the repository at this point in the history
  • Loading branch information
jgrizou committed May 6, 2015
1 parent b62adaa commit d5f2ff1
Show file tree
Hide file tree
Showing 7 changed files with 254 additions and 10 deletions.
29 changes: 24 additions & 5 deletions hardware/poppy_ergo_jr.scad
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ use <robotis-scad/dynamixel/xl320.scad>

use <specific_frames/base_frame.scad>
use <specific_frames/pen_holder_frame.scad>
use <specific_frames/cylinder_head_frame.scad>
use <specific_frames/lamp_head_frame.scad>
use <specific_frames/raspberry_pi_Bplus_base_frame.scad>


Expand All @@ -17,8 +19,13 @@ use <robotis-scad/frames/U_three_ollo_to_horn_frame.scad>

use <MCAD/rotate.scad>

module poppy_ergo_jr(){
xl320();
module poppy_ergo_jr(direction="front", endTool="pen_holder"){
if (direction == "front")
xl320();
if (direction == "back")
rotate([0,0,180])
xl320();

translate_to_xl320_top()
verticalize_U_horn_to_horn_frame(A){
U_horn_to_horn_frame(A);
Expand Down Expand Up @@ -50,14 +57,23 @@ module poppy_ergo_jr(){
translate_to_box_back()
translate([0,OlloSpacing/2,0])
rotate([180,90,0])
pen_holder_frame(length=F);
add_end_tool(endTool);
}
}
}
}
}
}

module add_end_tool(endTool) {
if (endTool=="pen_holder")
pen_holder_frame(length=F);
if (endTool=="cylinder_head")
cylinder_head_frame(length=F);
if (endTool=="lamp_head")
lamp_head_frame(length=F);
}

// Testing
echo("##########");
echo("In poppy_ergo_jr.scad");
Expand All @@ -67,14 +83,17 @@ echo("##########");
p = 1;
if (p==1) {
circular_base_frame(BaseRadius, BaseHeight);
poppy_ergo_jr();
poppy_ergo_jr(endTool="cylinder_head");

translate([100,0,0]) {
translate([0, - RaspberryPiBplusWidth/2 - RaspberryPiBplusFrameDistanceBoardToMotor - MotorLength + MotorAxisOffset, -MotorHeight/2-ollo_segment_thickness(1)])
raspberry_pi_Bplus_base_frame_with_raspberry_board();

poppy_ergo_jr();
poppy_ergo_jr(endTool="pen_holder");
}

translate([200,0,0]) {
poppy_ergo_jr(endTool="lamp_head");
}

}
4 changes: 2 additions & 2 deletions hardware/poppy_ergo_jr_def.scad
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ BaseHeight = CircularBaseFrameHeight+FrameTolerance;

A = 25;
B = 30;
C = OlloSpacing+FrameTolerance;
C = OlloSpacing/2+ollo_segment_thickness(1);
D = 30;
E = 30;
F = OlloSpacing+FrameTolerance;
F = OlloSpacing/2+2*ollo_segment_thickness(1);
35 changes: 35 additions & 0 deletions hardware/specific_frames/cylinder_head_frame.scad
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
include <specific_frame_def.scad>

include <../robotis-scad/frames/frame_def.scad>
include <../robotis-scad/dynamixel/xl320_def.scad>
include <../robotis-scad/ollo_segments/ollo_segments_def.scad>

use <../robotis-scad/frames/U_three_ollo_frame.scad>
use <../robotis-scad/ollo_segments/ollo_straight_segment.scad>
use <../segment-scad/elliptic_segment.scad>

use <../MCAD/rotate.scad>;

module cylinder_head_frame(length=OlloSpacing/2+ollo_segment_thickness(1)){

add_U_three_ollo_frame(length)
translate([0,-ollo_segment_thickness(1),0])
rotate([-90,0,0])
cylinder(h=ollo_segment_thickness(1), r=CylinderHeadRadius);
}

// Testing
echo("##########");
echo("In cylinder_head_frame.scad");
echo("This file should not be included, use ''use <filemane>'' instead.");
echo("##########");

use <../robotis-scad/dynamixel/xl320.scad>

p = 1;
if (p==1) {
xl320();
translate([0,-4*OlloSpacing,0])
rotate([0,90,180])
cylinder_head_frame();
}
48 changes: 48 additions & 0 deletions hardware/specific_frames/lamp_head_frame.scad
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
include <specific_frame_def.scad>

include <../robotis-scad/frames/frame_def.scad>
include <../robotis-scad/dynamixel/xl320_def.scad>
include <../robotis-scad/ollo_segments/ollo_segments_def.scad>

use <../robotis-scad/frames/U_three_ollo_frame.scad>
use <../robotis-scad/ollo_segments/ollo_straight_segment.scad>
use <../segment-scad/elliptic_segment.scad>

use <../MCAD/rotate.scad>;

module lamp_head_frame(attachLength=OlloSpacing/2+ollo_segment_thickness(1), lampLength=LampHeadLength, lampStartRadius=LampHeadStartRadius, lampEndRadius=LampHeadEndRadius,wallThickness=ollo_segment_thickness(1),cableHoleRadius=OlloSpacing){

difference(){
union() {
U_three_ollo_frame(attachLength);
translate([0,attachLength-ollo_segment_thickness(1),0])
rotate([-90,0,0]) {
difference() {
cylinder(h=LampHeadLength, r1=lampStartRadius, r2=lampEndRadius);
cylinder(h=LampHeadLength, r1=lampStartRadius-wallThickness, r2=lampEndRadius-wallThickness);
}
cylinder(h=ollo_segment_thickness(1),r=lampStartRadius);
}
}
translate([0,attachLength-ollo_segment_thickness(1),0])
rotate([-90,0,0])
cylinder(h=ollo_segment_thickness(1),r=cableHoleRadius);
}

}

// Testing
echo("##########");
echo("In lamp_head_frame.scad");
echo("This file should not be included, use ''use <filemane>'' instead.");
echo("##########");

use <../robotis-scad/dynamixel/xl320.scad>

p = 1;
if (p==1) {
xl320();
translate([0,-4*OlloSpacing,0])
rotate([0,90,180])
lamp_head_frame();
}
91 changes: 89 additions & 2 deletions hardware/specific_frames/raspberry_pi_Bplus_base_frame.scad
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,21 @@ include <specific_frame_def.scad>

include <../robotis-scad/ollo/ollo_def.scad>
include <../robotis-scad/dynamixel/xl320_def.scad>
include <../robotis-scad/ollo_segments/ollo_segments_def.scad>
include <../raspberry-scad/raspberry_pi_Bplus_def.scad>

use <../segment-scad/elliptic_segment.scad>
use <../robotis-scad/ollo/ollo_tools.scad>
use <../robotis-scad/frames/U_horn_to_horn_frame.scad>
use <../raspberry-scad/raspberry_pi_Bplus_tools.scad>

use <../../../poppy-4wheels-mini/hardware/poppy_4wheels_mini.scad>

use <base_frame.scad>
use <wheel_tools.scad>


use <../MCAD/rotate.scad>;

module raspberry_pi_Bplus_plate_sharp(nLayer=1) {

Expand Down Expand Up @@ -39,7 +48,7 @@ module raspberry_pi_Bplus_plate(cornerRadius=RaspberryPiBplusFrameCornerRadius,

}

module raspberry_pi_Bplus_base_frame(boardHeight=5, holeType="spike", cornerRadius=RaspberryPiBplusFrameCornerRadius, nLayer=1) {
module raspberry_pi_Bplus_base_frame(boardHeight=5, holeType="spike", cornerRadius=RaspberryPiBplusFrameCornerRadius, cameraDistFromEnd=RaspberryPiBplusFrameCameraDistFromEnd, nLayer=1, withHole=false) {

thickness = ollo_segment_thickness(nLayer);

Expand All @@ -48,11 +57,14 @@ module raspberry_pi_Bplus_base_frame(boardHeight=5, holeType="spike", cornerRadi
raspberry_pi_Bplus_plate(cornerRadius, nLayer);

translate([0,baseYPos,RaspberryPiBplusFrameHeight+thickness])
base_frame(RaspberryPiBplusFrameHeight);
base_frame(RaspberryPiBplusFrameHeight, withHole=withHole);

translate([0,0,thickness])
raspberry_pi_Bplus_hole_support(boardHeight, holeType, center=true);

translate([0,RaspberryPiBplusFrameLenght-RaspberryPiBplusWidth/2-cameraDistFromEnd,thickness])
add_raspberry_camera_holder();

}

module raspberry_pi_Bplus_base_frame_with_raspberry_board(boardHeight=5, holeType="spike", cornerRadius=RaspberryPiBplusFrameCornerRadius, nLayer=1) {
Expand All @@ -64,6 +76,50 @@ module raspberry_pi_Bplus_base_frame_with_raspberry_board(boardHeight=5, holeTyp

}

module circular_vertical_raspberry_pi_Bplus_base_frame(radius=CircularBaseFrameRadius, boardHeight=5, boardDistFromCenter=7+MotorHeight/2+2*OlloLayerThickness, cameraDistFromCenter=12+MotorLength-MotorAxisOffset, nLayer=1) {

rotate([0,0,180])
circular_base_frame(radius=CircularBaseFrameRadius, withHole=true);

/*difference() {*/
translate([0,-boardDistFromCenter,-MotorHeight/2])
add_side_support(boardHeight);
/*translate([0,0,-MotorHeight/2])
rotate([90,0,0])
elliptic_segment(RaspberryPiBplusWidth, width=4*CircularBaseFrameRadius, heigth=4*CircularBaseFrameRadius, wallThickness=CircularBaseFrameRadius);
}*/
translate([0,cameraDistFromCenter,-MotorHeight/2])
add_raspberry_camera_holder();
}

module circular_vertical_raspberry_pi_Bplus_base_frame_with_raspberry_board(radius=CircularBaseFrameRadius, boardHeight=5, boardDistFromCenter=7+MotorHeight/2+2*OlloLayerThickness, cameraDistFromCenter=12+MotorLength-MotorAxisOffset, nLayer=1) {

circular_vertical_raspberry_pi_Bplus_base_frame(radius, boardHeight, boardDistFromCenter, cameraDistFromCenter, nLayer);

rotate([-90,0,180])
translate([0,-boardHeight-RaspberryPiBplusWidth/2+MotorHeight/2,boardDistFromCenter])
add_raspberry_pi_Bplus();


}



module raspberry_pi_Bplus_base_frame_with_wheels() {

difference() {
raspberry_pi_Bplus_base_frame();

translate([RaspberryPiBplusFrameWidth/2-MotorHeight/2,0,ollo_segment_thickness(1)/2])
wheels_holes();
translate([-RaspberryPiBplusFrameWidth/2+MotorHeight/2,0,ollo_segment_thickness(1)/2])
wheels_holes();

translate([0,RaspberryPiBplusFrameLenght-RaspberryPiBplusWidth/2-RaspberryPiBplusFrameCameraDistFromEnd,ollo_segment_thickness(1)/2])
wheels_holes(withCableHole=false, spaceBetweenHoles=2*OlloSpacing);
}
}

// Testing
echo("##########");
echo("In raspberry_pi_Bplus_base_frame.scad");
Expand All @@ -75,4 +131,35 @@ use <../robotis-scad/dynamixel/xl320.scad>
p = 1;
if (p==1) {
raspberry_pi_Bplus_base_frame_with_raspberry_board();

translate([150,0,0]) {
circular_vertical_raspberry_pi_Bplus_base_frame_with_raspberry_board();
rotate([0,0,180]){
xl320();
translate_to_xl320_top()
verticalize_U_horn_to_horn_frame(30){
rotate([0,60,0]){
U_horn_to_horn_frame(30);
xl320_two_horns();
}
}
}
}

translate([-150,0,0]) {
raspberry_pi_Bplus_base_frame_with_wheels();

translate([0,RaspberryPiBplusWidth+RaspberryPiBplusFrameDistanceBoardToMotor,MotorHeight/2+ollo_segment_thickness(1)])
xl320();
translate([0,RaspberryPiBplusFrameLenght-RaspberryPiBplusWidth/2-RaspberryPiBplusFrameCameraDistFromEnd,0])
passive_wheel();

translate([-RaspberryPiBplusFrameWidth/2+MotorHeight/2,1.5*OlloSpacing,-MotorHeight/2])
rotate([0,-90,0])
add_wheel("lego");

translate([RaspberryPiBplusFrameWidth/2-MotorHeight/2,1.5*OlloSpacing,-MotorHeight/2])
rotate([0,90,0])
add_wheel("lego");
}
}
10 changes: 9 additions & 1 deletion hardware/specific_frames/specific_frame_def.scad
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,24 @@ CircularBaseFrameHeight = MotorHeight/2;

PenHolderInnerDiameter = 12;

CylinderHeadRadius = CircularBaseFrameRadius/2;

LampHeadStartRadius = 20;
LampHeadEndRadius = 35;
LampHeadLength = 50;

RaspberryPiBplusFrameWidth = RaspberryPiBplusLength;

RaspberryPiBplusFrameDistanceBoardToMotor = 10;
RaspberryPiBplusFrameDistanceMotorToEnd = 20;
RaspberryPiBplusFrameDistanceMotorToEnd = 30;
RaspberryPiBplusFrameEndWidth = MotorWidth + 10;

RaspberryPiBplusFrameCameraDistFromEnd = 15;

RaspberryPiBplusFrameLenght = RaspberryPiBplusWidth + RaspberryPiBplusFrameDistanceBoardToMotor + MotorLength + RaspberryPiBplusFrameDistanceMotorToEnd;

RaspberryPiBplusFrameCornerRadius = 3;

RaspberryPiBplusFrameHeight = MotorHeight/2;

RaspberryPiBplusFramecameraDistFromEnd = 10;
47 changes: 47 additions & 0 deletions hardware/specific_frames/wheel_tools.scad
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
include <../robotis-scad/ollo/ollo_def.scad>
include <../robotis-scad/dynamixel/xl320_def.scad>
include <../robotis-scad/ollo_segments/ollo_segments_def.scad>

use <../robotis-scad/ollo/ollo_tools.scad>

use <../MCAD/rotate.scad>;

legoWheelDiameter = 30.5;

module wheels_holes(withCableHole=true, nLayer=1, spaceBetweenHoles=3*OlloSpacing) {

translate([0,spaceBetweenHoles/2,0])
threeOlloHoles(nLayer=nLayer);
translate([0,-spaceBetweenHoles/2,0])
threeOlloHoles(nLayer=nLayer);

if (withCableHole == true) {
cube([1.5*OlloSpacing,2*OlloSpacing, ollo_segment_thickness(nLayer)], center=true);
}
}

module passive_wheel(height=MotorHeight/2+legoWheelDiameter/2, diameter=25, spaceBetweenHoles=2*OlloSpacing) {

difference() {
translate([0,0,-height+diameter/2]) {
cylinder(h=height-diameter/2, d=diameter);
sphere(diameter/2);
}
translate([0,0,-ollo_segment_thickness(1)/2])
wheels_holes(withCableHole=false, spaceBetweenHoles=2*OlloSpacing);
}
}

// Testing
echo("##########");
echo("In wheel_tools.scad");
echo("This file should not be included, use ''use <filemane>'' instead.");
echo("##########");

use <../robotis-scad/dynamixel/xl320.scad>

p = 1;
if (p==1) {
/*xl320();*/
passive_wheel();
}

0 comments on commit d5f2ff1

Please sign in to comment.