3D-printed holder for magnetic spheres built with OpenSCAD

When I built the low-cost and precise rotary encoder with magnetic spheres I used 21 spheres because they fitted nicely in the other parts of the build I had around.

However, if an arbitrary number of spheres is to be used then an appropriate holder must be built.

The magnetic spheres are 5mm in diameter. Knowing the number and the radius of the external spheres it is possible to calculate the radius of a circle surrounded by adjacent circles by using the inverse formula for the Numbers of circles around a circle.

I firstly wrote a test program (draw_circle_surrounded_by_circles.py) as a proof of concept, and then used the same math to build a 3D model with OpenSCAD.

OpenSCAD makes it easy to build parametric objects:

OpenSCAD - Tetramag spheres holder animation

I chose a number of spheres to match a minimum internal radius that was needed to fit the holder on a bike wheel, the nine couples of square holes are for tying the holder to the spokes.

The source code is in the OpenSCAD-Tetramag_spheres_holder git repository.

The end result is not bad and fits the wheel quite nicely:

Tetramag spheres holder mounted on a bike wheel

Tetramag spheres holder mounted on a bike wheel


CommentsSyndicate content

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account associated with the e-mail address you provide, it will be used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
a
Y
2
j
e
Y
Enter the code without spaces.