Custom battery tray maker
bigclivedotcom 0:43
50,568 views · 2,411 likes Watch on YouTube ↗
A handy 3D script and guide to adjusting the parameters to make a custom tray to store your batteries or other cylindrical objects in a compact manner.
There's a longer video with more details about using this script here:-
https://www.youtube.com/watch?v=dPa_6s1Vmjc
Openscad is a very interesting piece of open source software that lets you create 3D objects with a raw scripting language, allowing complex results from very tight code.
The openscad software can be downloaded here:-
https://openscad.org/
The script for this project is included at the bottom of this description. You literally just copy and paste it into the text box of openscad to adjust it as desired, and create your own custom STL file for your 3D printing system.
The six variables you can adjust are:-
Width - The number of battery cups wide.
Height - The number of battery cups high.
Depth - The depth of the battery cups.
Diameter - The internal diameter of the cups - slightly wider than your battery.
Thickness - The thickness of the cup walls.
Base - The thickness of the base.
When adjusting the values, be careful not to remove the "=" and ";" as they are part of the script.
To see your changes quickly, press the box with two arrows.
To build the final object press the box with an hourglass in it.
To save your custom STL file press STL. (After building with the hourglass button.)
The STL file can then be used with your preferred slicer (I use Cura) to make the gcode file for your choice of 3D printer.
I recommend making a single test cup (1X1) to test sizes before making a bigger tray of them.
You can also just choose a width and height of 1 to make a single large cup for other purposes.
If you enjoy these videos you can help support the channel with a dollar for coffee, cookies and random gadgets for disassembly at:-
http://www.bigclive.com/coffee.htm
This also keeps the channel independent of YouTube's advertising algorithms allowing it to be a bit more dangerous and naughty.
#ElectronicsCreators
Here's the openscad script. Copy and paste the text below into openscad to use it.
//Custom battery tray - bigclivedotcom
$fn=50;
//You can adjust these variables.
width=4; //number of horizontal cups
height=4; //number of vertical cups
depth=10; //internal depth of cups
diameter=15; //diameter of cylinder AA=15 AAA=11
thickness=1; //thickness of wall
base=1; //thickness of cup bases
//don't adjust stuff below here
columns=width-1;
rows=height-1;
wall=thickness*2;
dia=diameter+thickness;
cup=depth+base;
difference(){
union(){
//main body
for (x=[0:columns]){
for (y=[0:rows]){
translate([x*dia,y*dia,0])
cylinder(h=cup,d=diameter+wall);
}
}
}
//hollow cores
for (x=[0:columns]){
for (y=[0:rows]){
translate([x*dia,y*dia,base])
cylinder(h=cup,d=diameter);
}
}
}
There's a longer video with more details about using this script here:-
https://www.youtube.com/watch?v=dPa_6s1Vmjc
Openscad is a very interesting piece of open source software that lets you create 3D objects with a raw scripting language, allowing complex results from very tight code.
The openscad software can be downloaded here:-
https://openscad.org/
The script for this project is included at the bottom of this description. You literally just copy and paste it into the text box of openscad to adjust it as desired, and create your own custom STL file for your 3D printing system.
The six variables you can adjust are:-
Width - The number of battery cups wide.
Height - The number of battery cups high.
Depth - The depth of the battery cups.
Diameter - The internal diameter of the cups - slightly wider than your battery.
Thickness - The thickness of the cup walls.
Base - The thickness of the base.
When adjusting the values, be careful not to remove the "=" and ";" as they are part of the script.
To see your changes quickly, press the box with two arrows.
To build the final object press the box with an hourglass in it.
To save your custom STL file press STL. (After building with the hourglass button.)
The STL file can then be used with your preferred slicer (I use Cura) to make the gcode file for your choice of 3D printer.
I recommend making a single test cup (1X1) to test sizes before making a bigger tray of them.
You can also just choose a width and height of 1 to make a single large cup for other purposes.
If you enjoy these videos you can help support the channel with a dollar for coffee, cookies and random gadgets for disassembly at:-
http://www.bigclive.com/coffee.htm
This also keeps the channel independent of YouTube's advertising algorithms allowing it to be a bit more dangerous and naughty.
#ElectronicsCreators
Here's the openscad script. Copy and paste the text below into openscad to use it.
//Custom battery tray - bigclivedotcom
$fn=50;
//You can adjust these variables.
width=4; //number of horizontal cups
height=4; //number of vertical cups
depth=10; //internal depth of cups
diameter=15; //diameter of cylinder AA=15 AAA=11
thickness=1; //thickness of wall
base=1; //thickness of cup bases
//don't adjust stuff below here
columns=width-1;
rows=height-1;
wall=thickness*2;
dia=diameter+thickness;
cup=depth+base;
difference(){
union(){
//main body
for (x=[0:columns]){
for (y=[0:rows]){
translate([x*dia,y*dia,0])
cylinder(h=cup,d=diameter+wall);
}
}
}
//hollow cores
for (x=[0:columns]){
for (y=[0:rows]){
translate([x*dia,y*dia,base])
cylinder(h=cup,d=diameter);
}
}
}
Category (YouTube): Science & Technology
Playback is via YouTube's official embedded player. Data from YouTube; Exumo is not affiliated with YouTube.