• Models
  • Contests
  • Slicer
  • Login
  • Start Here
    thingiverse-iconprintables-iconcults3d-iconmakerworld-iconmyminifactory-icon

    3D GO

    3D ModelsContestsCollectionsSaved ModelsOn a mobile device?

3D GO

Privacy Policy
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Image 1
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Image 2
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Image 3
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Image 4
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Thumbnail 1
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Thumbnail 2
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Thumbnail 3
Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20 3D Printer File Thumbnail 4

Gridfinity Bin Labels Hexagon socket head cap screws ISO 4762 former DIN 912 M2.5, M3, M4, M5, M6, M8, M10, M12, M14, M16, M18, M20

Eistee avatarEistee

November 13, 2024

printables-icon
DescriptionCommentsTags

Description

The labels are for these gridfinity boxes: https://www.printables.com/model/592545-gridfinity-bin-with-printable-label-by-pred-parame

The bolts are to scale as far as possible. When the screws get too long for the label, the bolt figure is broken.

Print it at 0.2 mm layer height and make a filament change in layer 3.

 

--------------------------------------

I was asked multiple times how i generated these, so here is a short How-To using Fusion360:

You need two steps: 

  1. Parametrize your model
  2. Write a Script that loops through all your variants, saves them by a usefull name and zips them on its own. Additionally take a screenshot for a nice .gif.

1.) The tricky part is the parametric text, as Fusion does not (yet) support this. There is a “ParametricText” App in the Appstore, however this does NOT work with scripts. Go to the GitHub page and get the ext-trigger fork.
Once you got this installed by placing it inside "%appdata%\Autodesk\Autodesk Fusion 360\API\AddIns" you can use it in Autodesk. See the Appstore page for help.

Hint: After saving and loading, sometimes the app messes up and the format of the text is all over the place. Simply assign the sketch/text again to your parametric setup if you have trouble.

 

2.) in Fusion360, under Utilities/ADD-INS/Scripts and Add-Ins you can create yourself a python script that basically controlls Fusion360. 

It will open Visual Studio where you can create your script. You can take a look at mine and take it as a starting point. I am not programmer nor is this by any stretch an ideal script, but it works. The script below looks terrible here on printables, copy&paste it into Visual Studio for propper formatting and highlighting. I added some comments, I think it is easy to adapt. Use ChatGPT for help if necessary ;)

Once you got it set up you can lean back and watch your script run. Fusion runs quiet slow, my script took a couple hours for all variants, so better start with a small batch to make sure everything works fine.

#Author-
#@Eistee_158202


import adsk.core, adsk.fusion, adsk.cam, traceback
import os
import shutil

def run(context):
    ui = None
    try:
        app = adsk.core.Application.get()
        ui = app.userInterface
        design = adsk.fusion.Design.cast(app.activeProduct)
        
        # Get the root component of the active design
        rootComp = design.rootComponent

        # Specify the folder to write out the results.
        folder = 'C:/Temp/'

        # Get the parameters named "bolt_length_l" and "Box_width" which are defined in my parametric Fusion360 model and change them.
        MParam = design.allParameters.itemByName('M')
        bolt_lengthParam = design.allParameters.itemByName('bolt_length_l') # Parameter in Fusion360
        Box_widthParam = design.allParameters.itemByName('Box_width') # Parameter in Fusion360
        cnt=1 # counter for figures
        M = 3 # Modul of bolt
        Box_width = 1 # width of the label
        for M in (3, 4, 5, 6, 8, 10, 12, 14, 16, 18, 20): # list of Moduls to be looped through
            for Box_width in (1, 2): # make the labels in different width
                for length in range(4,200): # loop over length of bolt from 4 to 200
                    if length % 2 == 0 or length % 5 == 0: # only do bolt length if it is dividable by 2 or 5
                        Box_widthParam.expression = str(Box_width) # make this a string
                        MParam.expression = str(M) # make this a string 
                        bolt_lengthParam.expression = str(length) # make this a string
                        app.fireCustomEvent('thomasa88_ParametricText_Ext_Update')
                        adsk.doEvents()
                        adsk.doEvents()    # Don't know why, but it works only stable if you call it twice
                        # Construct the output filename.
                        newfolder_M = folder + "/" + "M" + str(M)
                        newfolder_width = newfolder_M + '/' + str(Box_width) + '_width'
                        os.makedirs(newfolder_M, exist_ok=True) # make a new folder
                        os.makedirs(newfolder_width, exist_ok=True) # make a new folder
                        variantname = str(Box_width) + 'width_M'+ str(M) + 'x' + str(length) 
                        filename = newfolder_width + '/' + variantname +'.stl'
                        
                        # Save the file as STL.
                        exportMgr = adsk.fusion.ExportManager.cast(design.exportManager)
                        stlOptions = exportMgr.createSTLExportOptions(rootComp)
                        stlOptions.meshRefinement = adsk.fusion.MeshRefinementSettings.MeshRefinementMedium
                        stlOptions.filename = filename

                        # Screenshot the variant and save to file
                        screenshotfilename= folder + '/' + str(f"{cnt:02d}") + "_" + variantname +'.jpg'
                        app.activeViewport.saveAsImageFile(screenshotfilename, 1600, 1000);
                        cnt=cnt+1
                        
                        exportMgr.execute(stlOptions)
                zip_file_path = folder + '/' + str(Box_width) + 'width_M'+ str(M) # zip folder to archive
                shutil.make_archive(zip_file_path, 'zip', newfolder_width)

        ui.messageBox('Finished.')
    except:
        if ui:
            ui.messageBox('Failed:\n{}'.format(traceback.format_exc()))

 

 

 

 

 

License:

Creative Commons — Attribution — Noncommercial

Related Models

Thor Mjolnir Hammer Bic Pen preview image

Thor Mjolnir Hammer Bic Pen

effektz profile image

effektz

9,090

Diverse Schilder / various labels  for hobby & makers preview image

Diverse Schilder / various labels for hobby & makers

RPK profile image

RPK

2

Cute Fluffy Puppy Figurine to Print preview image

Cute Fluffy Puppy Figurine to Print

bonowski. profile image

bonowski.

3

Vorpal The Hexapod Walking Robot preview image

Vorpal The Hexapod Walking Robot

vorpal profile image

vorpal

4,986

MakerZ – Open Source 1/28 RC Drift Chassis by Fails & Makes | Açık Kaynak 1/28 RC Drift Şasisi preview image

MakerZ – Open Source 1/28 RC Drift Chassis by Fails & Makes | Açık Kaynak 1/28 RC Drift Şasisi

Fails&Makes profile image

Fails&Makes

Customizable EU License Plate Keychain preview image

Customizable EU License Plate Keychain

John_M profile image

John_M

41

Snap-Together Mini Minecraft Jack-O-Lantern with integrated LED preview image

Snap-Together Mini Minecraft Jack-O-Lantern with integrated LED

scottrlindsey profile image

scottrlindsey

4,450

Small Parts Storage Drawers - Organizer preview image

Small Parts Storage Drawers - Organizer

GT 3D Makers profile image

GT 3D Makers

29

9