« Back to home

Parametric PCB Holder

Here is a simple, parametric, PCB holder that you can print out. I've added the object to Thingiverse so you can access it there as well as directly downloading the code from my Git repository.

A Tobi Board

This design is useful in the prototyping stage where you have existing boards that you need to protect from accidental shorting or to keep them steady on a more firm platform. As provided the OpenSCAD source defines a suitable holder for a Raspberry Pi Model B board, in the comments I've also provided settings for the Tobi and Chestnut43 boards from Gumstix (I use these at work a fair bit so they are immediately useful to me).

Raspberry Pi

This object was inspired by the Raspberry Pi Plate and the XClip objects on Thingiverse. Neither of these provided source to make them modifiable for different PCB sizes and both of them are susceptible to slightly unbalanced print beds and low resolution prints. This design is far less aesthetic but much more functional and forgiving.

The design is fairly simple - you have a base plate (a simple rectangular outline) which has four mount points with notches to hold your PCB. The key variables to change are at the top of the file:

 PCB_WIDTH     = 56;  // Width of the PCB in mm     PCB_BREADTH   = 86;  // Length of the PCB in mm     PCB_HEIGHT    = 1;   // Height of the board itself     PCB_CLEARANCE = 4;   // Gap between the base of the PCB and the base plate.     PCB_EDGE_CLIP = 2;   // Gap for the clip in the mounts     MOUNT_SIZE    = 4;   // Size of the mounts (they are square)     MOUNT_EXTRA   = 2;   // Extra space above the clip hole     FUDGE_FACTOR  = 0.3; // Extra space when using PCB clip holes

A Tobi Board

The PCBWIDTH, PCBBREADTH and PCBHEIGHT are simply measured from the board you want to hold (be generous with these values, if the length looks like a bit over 115mm use 116 as the value). The PCBCLEARANCE value is the gap between the top of the baseplate and the bottom of the PCB - if you have extra connectors on the bottom of your PCB you need to increase this to accommodate them accordingly.

The PCBEDGECLIP value sets the gap on the corners of your PCB which the mounts can grab on to. Some PCB's have components very close to the corners, if the gap between these components and the edge of the board is less than 1mm then this object probably won't work for you.

The MOUNT_EXTRA variable sets the height of the mount point that extends above the gap for the PCB. Keep this at 2mm or more, any less and it may not print properly. You may want to modify this if you want to stack PCB holders on top of each other.

Raspberry Pi

The FUDGE_FACTOR variable provides some wriggle room - the notches for the PCB's are made larger in each dimension by this amount. I generally set this to the print resolution I'm using - you can always use a file to grind away any extraneous plastic if you need to expand this gap.

I've tried to comment the code enough so you can modify it to your own needs, one of the most common requirements would be to add mounting holes to affix the PCB to a more solid foundation. For this there is I've provided a module you can modify that is already called when the object is generated:

 /* Modify the base plate     **     ** The objects defined here will be subtracted from the base plate. You can     ** use this to define mounting holes, etc. The example code given here     ** creates holes for M3 mounting bolts - if you want to do this you should     ** increase the value of 'BASE_PLATE_EXTRA' to 5 or more.     */     module modify_baseplate() {     /* Sample code to create M3 mounting holes     **     ** See notes above for more details.     **       mid_width = (BASE_PLATE_HOLE_WIDTH / 2) + ((BASE_PLATE_WIDTH - BASE_PLATE_HOLE_WIDTH) / 4);       mid_breadth = (BASE_PLATE_HOLE_BREADTH / 2) + ((BASE_PLATE_BREADTH - BASE_PLATE_HOLE_BREADTH) / 4);       // Generate mounting holes for M3 bolts on each edge of the frame       translate(v = [ 0, mid_breadth, 0 ]) {         cylinder(r = 1.5 + (2 * FUDGE_FACTOR), h = 3 * BASE_PLATE_HEIGHT, center = true, $fs = 0.3);         }       translate(v = [ 0, -mid_breadth, 0 ]) {         cylinder(r = 1.5 + (2 * FUDGE_FACTOR), h = 3 * BASE_PLATE_HEIGHT, center = true, $fs = 0.3);         }       translate(v = [ mid_width, 0, 0 ]) {         cylinder(r = 1.5 + (2 * FUDGE_FACTOR), h = 3 * BASE_PLATE_HEIGHT, center = true, $fs = 0.3);         }       translate(v = [ -mid_width, 0, 0 ]) {         cylinder(r = 1.5 + (2 * FUDGE_FACTOR), h = 3 * BASE_PLATE_HEIGHT, center = true, $fs = 0.3);         }     */       }

The code is commented out but, if enabled, would generate a set of mounting holes for M3 bolts in the center of each edge of the base plate (you do need to modify the BASEPLATEEXTRA variable to add some additional plate space to accommodate the holes without weakening the structure). Any object generated by this module will be subtracted from the base plate. This, combined with modifications to the main variables, gives you a fair bit of flexibility to adjust the object to your needs.

More generally I've recently added a glass bed to my printer by simply buying a cheap photo frame of around the right size and using bulldog clips to attach it. I had to adjust the limit switch detecting the zero level of the bed and then re-align the bed balancing (a process that has taken several hours so far and is not yet complete). The end result has been well worth it - the glass bed sticks well during the printing phase (I start with 95C for the first layer and then drop to 85C for the remaining layers) but makes it far easier to remove the printed objects once they are done (a few seconds of cooling and they practically fall off). It's also a lot easier to clean the print bed - I can remove it completely and use cotton balls soaked in acetone (at the moment I'm using fingernail polish remover that is about 80% acetone) to clean it before re-attaching.

At the moment I'm having some problems balancing the print bed correctly - I don't think the cheap glass is entirely uniform in thickness. Because the glass extends beyond the print area it is acting like a heat sink and bleeding heat from the edges - prints that push to the limit of my print bed area are peeling at the edges. Some more experimentation to go I think.