Exit Full View
Up

/Garden/FenceTopClip.foocad

FenceTopClip

This was first created, so that I could secure a squash plant along the top of a wooden fence. But I guess it could be used for lots of things.

Print Notes

I suggest lots of perimeters, because the strength is needed along the length (and it will be a 100% filled object due to the small thickness, so why not all perimeters?)

I printed these in PLA, and they are flexible enough. Time will tell if they hold their shape well enough.

FooCAD Source Code
class FenceTopClip : Model {
    
    @Custom
    var size = Vector3( 100, 6, 1 )

    @Custom
    var endSize = Vector2( 22, 18 )


    @Custom
    var keyholeD1 = 9
    @Custom
    var keyholeD2 = 5
    @Custom
    var keyholeL = 8
    
    override fun build() : Shape3d {



        val keyhole = Circle.hole( keyholeD2/2 ).translateX( -keyholeL ).hull(
                Circle.hole( keyholeD2/2 )
        ) + Circle( keyholeD1 / 2 )

        val end = Circle( endSize.x/2 )
            .scale( 1.0, endSize.y / endSize.x) -
            keyhole.centerX()

        val strip = Square( size.x, size.y ).center()
        val all = strip +
            end.translateX( -size.x / 2 - keyhole.size.x/2 ).mirrorX().also()
           
        val result = all.extrude( size.z )
        return result
    }
}