3D printing on OpenBSD? Sure, that’s a factor!
Contributed by
Ian Darwin
on
from the ‘What else are you able to do with it?’ dept.
Can you actually do 3D printing from OpenBSD? Cue suspenseful music
while I formulate my reply, which is: Sure.
In case you aren’t accustomed to the 3D printing course of, it’s divided
into a number of steps, vaguely analogous to writing, compiling and operating
a program in a compiled language.
- Design (CAD) The design device will get you from an thought to an
actual specification – like writing and enhancing a supply code file. The
commonest format for these is
STL,
standing for stereolithography,
what 3D printing was initially known as. - Slicing – convert to layers The “slicing” converts the file
from STL to‘g-code’,
analogous to compiling a program. These codes
signify every layer with a set of actions for the 3d print head to
comply with. The g-code format originated many years in the past to be used in numerical
managed machining, and the pioneers of 3D printing correctly adopted and
tailored this format for the wants of 3D printers. - Obtain to 3D printer The downloading is analogous to
loading a compiled program right into a program that may run it, like qemu or
the Java runtime. The g-code is interpreted by the 3D printer to make the
completed article.
Design
OpenSCAD has been in ports for fairly a while. At h2k23 I labored on
a port of one other 3D CAD device, solvespace, which I imported shortly
after. These are each “parametric” instruments, e.g., specify that these two
components should meet at precisely 45 levels, that this half shall be so many
items huge, and many others. OpenSCAD additionally has a really good menu system permitting you
to edit the parameters of the job. I’m utilizing this to make labels for a
membership I belong to, working from
Xavier Faraudo’s versatile name tag kit.
Having configured the mission as I need it, I can simply open
the file, enter the member’s first and final names, and hit
Render
. Moments later it spits out an STL file, prepared for
slicing.
Some folks use Blender (which has been in ports for ages) to do 3D
modelling. There are additionally web-based design instruments reminiscent of Tinkercad,
which is straightforward to make use of and free to make use of, however could also be a “portal drug” to the
proprietary CAD software program offered by Tinkercad’s sponsor, Autodesk.
Slicing
Whereas at h2k23, I used to be in contact by e mail by Johannes Tishman to work
on a port of
PrusaSlicer 2.6.1. There are a number of dependencies that make
it more durable to port to 2.6.1 in contrast with 2.5.2. I did some work on the
substitute for oce
wanted for two.6.1, however that wound down
inconclusively.
Then in Sept 2023, Renato Aguiar circulated his accomplished port of
PrusaSlicer 2.5.1. I wanted to do that out directly! I took the 45
minute print job formatted with openscad (see above underneath
Design), sliced it with Prusaslicer, and it printed wonderful. All
on OpenBSD.
With suggestions from Johannes and an OK from jcs@, I dedicated
this port into the tree in mid-September, 2023. This was the final main
step in finishing the flexibility to do 3D printing, for the reason that downloading
step (under) doesn’t want any new software program to be ported.
Observe that, regardless of being from Prusa, this software program can slice and cube
STL code for nearly any fashionable printer, both FDM (filament) or SLA
(resin). It comes with profiles for a wide range of printers, however even
in case your printer isn’t already identified, you possibly can in all probability configure it to
work. The truth is, some Prusa opponents like Bambu Labs make their very own
slicers… primarily based on PrusSlicer.
PrusaSlicer in flip was primarily based on an earlier slicer known as Slic3r.
Open supply works that method.
Downloading
The obtain step might be accomplished by sneakernet (placing the file
on a USB stick and strolling it over to the printer), however that’s fairly
low bandwidth. There are no less than two higher methods.
There’s a free open supply mission known as
OctoPrint that gives nice downloading and
monitoring of most 3D printers. This software program might be run on a Raspberry
PI (the place it’s known as OctoPI), connecting to most manufacturers of printers through
USB. There are additionally
downloads for other platforms
reminiscent of Android. The usual model is managed by an online
browser like Firefox in your desktop, and is used for sending recordsdata to
your printer, beginning and monitoring them, and many others.
With a Prusa MK4 printer, you don’t even want the Raspberry PI. Prusa
printer’s firmware features a built-in net server and an online app known as
PrusaLink. That is invoked out of your desktop simply by giving the
printer’s Ethernet or WiFi IP4 deal with because the browser URL, e.g.,
http://10.1.1.42/
. You log in with a username of
maker
and a password randomly chosen by the printer itself
(obtainable on the printer’s LCD display screen). There’s no UI for altering this
password, so one suspects it’s a hash of the printer’s serial quantity.
I’ve used PrusaLink rather a lot over wired Ethernet and it has been
dependable, although I’ve heard complaints from folks utilizing it over WiFi.
Glad Ending
I’m glad to say that we will now carry out the entire 3D print workflow
on OpenBSD. Use one of many design instruments openscad
or
solvespace
to generate the STL file. Use PrusaSlicer to
generate the g-code. Then use prusalink or octoprint through FireFox or
Chromium to feed the g-code out of your desktop to the printer, and to
begin and monitor the printing. All the pieces you want is now within the
OpenBSD ports tree, and will likely be included in packages quickly, in all probability by
the time you learn this.
Because of Johannes and Renato for work on PrusaSlicer, and to
everybody else who helps to make OpenBSD usable as one’s all-in-one
working system.
Future Work
The subsequent steps will in all probability be an improve of PrusaSlicer from 2.5.2
to 2.6.1 – this brings main enhancements – and the addition of
extra cad instruments, maybe FreeCAD.