Skip to content

Instantly share code, notes, and snippets.

@scruss
Created February 25, 2026 10:16
Show Gist options
  • Select an option

  • Save scruss/e0a619e5ed9997c761b97b11b6e880b5 to your computer and use it in GitHub Desktop.

Select an option

Save scruss/e0a619e5ed9997c761b97b11b6e880b5 to your computer and use it in GitHub Desktop.
MicroPython logo keychain in OpenSCAD
/*
OpenSCAD MicroPython keychain - scruss, 2026-02 - WTFPL
based on a design shared by Kritish Mohapatra in the
February 2026 Melbourne MicroPython Meetup
you will need the logo SVG from:
https://commons.wikimedia.org/wiki/File:MicroPython_new_logo.svg
sizes were guessed badly at 04:00 in the morning so may not be
practical for actual use.
TODO:
1) fix sizes to be useful;
2) (maybe) replace fragile ring with stronger channel through logo;
3) (maybe) replace imported SVG with drawn elements.
- see ssd1306.rst in the ESP8266 tutorial
*/
// things you can edit
size = 32; // mm
thickness = 4;
// things you can also edit, but also break
// if you don't know what you're doing
// original SVG extents
bbox = [ 342, 342 ];
minima = [ 0, -221.350006 ];
module logo_3d() {
// generate logo, size * size mm wide/high, thickness mm thick
// with origin translated to (0, 0)
linear_extrude(thickness) scale(size / bbox.x) translate(-minima)
import("MicroPython_new_logo.svg");
}
module ring() {
// make a small ring half the thickness of the main part,
// outer diameter: (main part size) / 4 + 4mm
// inner diameter: (main part size) / 4
linear_extrude(thickness / 2) difference() {
circle(d = (size / 4) + 4);
circle(d = size / 4);
}
}
// create the logo fused with the ring
union() {
logo_3d();
translate([ 0, size, 0 ]) ring();
}
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@scruss
Copy link
Author

scruss commented Feb 27, 2026

There is a much improved version here: Improved MicroPython logo keychain in OpenSCAD

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment