SethBon's Light Bar for Prusa i3 Mk3/S/+ model is a fun electronics project and a really well-designed overhead printer light.
The rotary dimmer switch I had on-hand is too big to fit onboard so I made this housing and junction box. M3x8mm bolts with washers are used to mount the box using two of the tapped holes in the flat steel Z-axis frame.
Conductor wire enters and exits the junction box through channels cut into its top and bottom surfaces. These channels are positioned to keep the wire short and plum on its runs from the Einsy-Rambo enclosure and to the light assembly.
I recommend using 22 gauge wire for this project. The 20 gauge wire I used was difficult to work with because it fit too tightly inside the light bar supports.
The cover plate attaches to the box with four M3x5mm bolts and has a 10mm center hole for mounting a rotary dimmer switch. Model was designed in TinkerCad and should be pretty easy to edit for fitting a different switch.
Printed in PETG with .20mm layer height and supports on build plate only. A brim may also be needed to prevent corner lift.
The author remixed this model.