My Customized iPhone_Case_Globus_MakerBot
thingiverse
This is a Python script for generating G-Code from STL (STereoLithography) files, likely used in additive manufacturing such as FDM (Fused Deposition Modeling). Here's a breakdown of the script and how to write it by hand. **Loading an STL File** To start generating G-code from your own STL file, you will need Python 2 or higher installed on your computer. Downloading PyMCADCNC.py to create a local version can simplify loading large files into Pygame. You must install either Cheetah (Cheetah.Python.org) for running on non-Unix systems and then import it by typing import cdpkg. or use apt-get in Ubuntu: apt-get update & apt-get install pycdata Once your .py file is created you need to save all code in the one text document before saving a Pygame (the free source open graphics) version. Open PyGame version, go under the project then file to save this in it then find “projectname”-py or -html depending what system youre running Finally you should be able see .gcode outputted out at top To generate G-code using PyMCADCNC.py from a hand-generated code here's what you need: ### Section 1: Define Variables and Modules ``` # This defines an array containing coordinates to guide movement. coords_array = [[9.999984,10.002983], [9.999987,10.003998],...] pattern_widths_and_heights = {'Layer1':[100,'Laser'],"layer_4":[75,"red"],"Custom-layer2" :['green',45]] # To print with an offset pattern (i.e. different laser power for certain positions), pattern_positions=[['posn5',[12.1,-3,50],[35.2,56,6]], ['layer5-0-2' , [12,11,25] ,[20,-55,14]]] def write_code(f): ``` This function prints all G-code commands from given variables, including all necessary G28 home moves, Z0 layer leveling for printing at specified heights (z-positions). **Note:** Please modify coordinates within lists so your laser knows exactly where you are working with PyMCADCNC or just use any Python module able to make those lists of numbers easily accessible and alter these numbers directly. In conclusion, With custom data defined in "coordinates_list" this Gcode will be printed. To create one simply load this G-code and follow directions below:
With this file you will be able to print My Customized iPhone_Case_Globus_MakerBot with your 3D printer. Click on the button and save the file on your computer to work, edit or customize your design. You can also find more 3D designs for printers on My Customized iPhone_Case_Globus_MakerBot.