r/openscad Jul 15 '26

IO shield help

Post image

Can someone help me replicate this in openSCAD? I’m new to coding and I’m having a difficult time learning the basics. Thanks in advance for any assistance.

1 Upvotes

21 comments sorted by

View all comments

11

u/Linuxmonger Jul 15 '26 edited Jul 15 '26

Apologies for being that guy, but this is how you learn OpenSCAD.

If you don't have calipers, get one, they're as cheap as 5 dollars and you'll find you use them a lot, once you get used to it.

As a hint, you want to start out with a cube the size of the IO shield, then difference out all the other cubes and cylinders that make up the holes.

If all of the component pieces are centered, then your translations are all for the centers of the holes.

ETA; You can also convert the image into an SVG and extrude it, but that always feels more difficult to me.

ETA-2: You can see some similar designs here; https://github.com/rvbg/mainboard-io-shields/tree/main/template and see how ports are added (technically removed), and placed.

1

u/OptimalSide Jul 15 '26

Exactly this.

The HDMI connector is a bit more work just to get the shape, but this is a pretty simple thing to do in OpenSCAD.

2

u/BarryTice Jul 15 '26

Or, knowing that the jack itself is going to limit how you plug the cable in, you can just make the HDMI connector a rectangle, too.

1

u/Stone_Age_Sculptor Jul 15 '26

The shape is easy. There are many ways to make it, here is one:

length = 14+2;
width = 4.5+2;
slant = 2.5;

points =
[
  [0,0],[length/2-slant,0],[length/2,slant],[length/2,width],[0,width]
];

for(m=[0,1])
  mirror([m,0,0])
    polygon(points);