Giter Site home page Giter Site logo

fullcontrolxyz / fullcontrol Goto Github PK

View Code? Open in Web Editor NEW
623.0 25.0 67.0 10.4 MB

Python version of FullControl for toolpath design (and more) - the readme below is best source of information

License: GNU General Public License v3.0

Python 57.28% Jupyter Notebook 42.72%

fullcontrol's Introduction

FullControl

FullControl - unconstrained design

fullcontrol allows you to control 3D printers, or other cnc systems, in ways that are not possible using conventional software

you design everything about the print path and print settings, giving you the design freedom to do anything you want

get started without installing anything: go through the interactive tutorial notebooks then use the design template - or install and run things locally as described below

(youtube playlist)


think beyond 'normal' 3D printing

intro

the conventional method to generate gcode is: create cad model -> export stl -> slice into layers -> create paths for each layer -> output path as gcode

FullControl offers a different approach where the print path is explicitly designed. imagine being given a hotmelt glue-gun and told to move it around to 'print' layers resulting in a 30-mm cube. you could design lots of different paths that would achieve the cube. FullControl allows you to design and preview print paths and convert them to machine-code instructions for a 3D printer (a gcode file)

the overall printing procedure may be considered to be predominantly a stream of points. then a few extra things are sprinkled in occasionally, like changes to speed, temperature, fans, etc.

all of these things together (points and the extra things) are referred to as state in FullControl. state is basically any property of interest that can change

FullControl allows designs to be created that control changes the state of things, where things are anything with state - this initial release of FullControl is focused on the thing being an extrusion 3D printer that is instructed by gcode. however, things really could be anything (laser cutters, assembly lines, non-physical things like a 3D visualization, etc.)

FullControl history

"FullControl gcode designer" (2020) (website, github, journal paper)

  • users generate gcode by directly designing geometric 'features' and custom gcode 'features'
  • microsoft excel used as the user interface for design creation. FullControl algorithms written in visual basic. gcode previewed in other software (e.g. repetier host)
  • targeted researchers and people experimenting with printers and other gcode-based hardware, who need to explicitly design print paths with 'full control'

"www.fullcontrol.xyz" (2022):

  • users generate and download gcode parametrically for pre-created designs directly from a website
  • no need for experience of printing, gcode, CAD, toolpath design, python, etc.
  • demo models created with the python implementation of FullControl (i.e. this repository)

"FullControl" (2023) - this repository:

  • users design, preview, and export gcode for custom print paths for extrusion 3D printing, all in a python environment
  • 'designs' are python scripts or jupyter notebooks
  • the initial release (March 2023) is a gcode-focused implementation of the broader FullControl concept to design changes to the state of things

using FullControl

jupyter notebooks are provided in the tutorials folder of this github repository (repo) to introduce FullControl and demonstrate its use - browse tutorials: github / colab

you can either use a cloud-based jupyter notebook environment like google colab, or run things locally by installing python and then either jupyterlab or vscode with python and jupyter extensions

a future update of this repo will give more details about the python code

installation

new to python? don't install - just use the colab design template and get designing straight away online

alternatively, to run locally, install miniconda/anaconda/python and git - if you run into any installation problems, update your versions of python/git/pip

pip install git+https://github.com/FullControlXYZ/fullcontrol

you can also clone this git repo and run "pip install ." from the repo directory

use

to use FullControl, create a python script or jupyter notebook and import the fullcontrol package

import fullcontrol as fc

structure of the repository

the FullControl repository is organized as follows:

  • tutorials: jupyter notebooks describing FullControl and its use. For more details, check the readme here or jump straight in to the 1-minute demo
  • fullcontrol: the FullControl python package. For more details, check the readme here
  • models: example models that use FullControl. For more details, check the readme here
  • lab: the FullControl lab python package for experimental features. For more details, check the readme here
  • bin: scripts for FullControl development activities

workflow for new content

the anticipated workflow for new content is:

  1. demonstrate new ideas with github gists (quick and dirty)
  2. gists inform new additions to the FullControl lab (a little more polished)
  3. lab informs new additions to the main fullcontrol package or models subdirectory

feedback

please use the github issues tab for this repository to give feedback.

pull requests

please submit pull requests for bugfixes, optimizations, documentation corrections/clarifications, etc., and for minor additions and new features such as functions, objects, and modules that fit into the existing package structure

for revisions that change the structure, behaviour, or usage of the software, please email us ([email protected]) prior to submitting a pull request. this is to ensure alignment between the changes and any planned/unpublished revisions already in progress. note that this version of FullControl is not targeted at developers - the structure of the repo may change and more information about the code structure will be provided at a later date to accommodate contribution more readily

note that the tutorials folder of this repo contains tutorial notebooks. executing cells in these notebooks leads to timestamp changes, even if the cell content remains unchanged. this may cause unexpected issues and complications for pull requests. until a more automated solution is implemented, consider two options before submitting a pull request:

  1. create a fresh clone of the FullControl repo and copy the relevant changes across (recommended)
  2. use the git stash operation on the tutorials folder (be careful not to unintentionally stash any of your proper changes though)

license

FullControl is released under the GPL v3 License.

copyright

FullControl, FullControlXYZ, copyright 2023 Andrew Gleadall and Dirk Leas

references

until the journal paper for FullControl is available, please cite the paper for 'FullControl GCode Designer':

Gleadall, A. (2021). FullControl GCode Designer: open-source software for unconstrained design in additive manufacturing. Additive Manufacturing, 46, 102109.

contact

fullcontrol's People

Contributors

andyglx avatar conifarad avatar darigovresearch avatar es-alexander avatar frostifish avatar fullcontrol-xyz avatar garyvdm avatar keelan-moore avatar miwaniza avatar ppak10 avatar toh-10 avatar vorpalblade avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fullcontrol's Issues

gyroid infill

Hello,
I am wondering if there is any pre-defined function to create gyroid infill.
if no, could you please give me any hints about how to create it?
Thank you very much in advance

Kind regards,
Mohsen

[suggestion] string art example

I just came across string/thread art and thought it was really cool, so figured I'd note it down here for future reference (by me or whoever decides to pick it up) as something it'd be neat to have an example of.

There are apparently some pretty crazy string art pieces, and I suspect we can likely do something similar either with a plotter (e.g. #15) and/or as a printed border with bridge lines in between (e.g. as a fancy case of #23). There are a variety of existing free and paid tools that we could adapt the output of (which is likely good as a starting point), but it could also be fun to have our own open-source algorithm implementation 🤷‍♂️

For reference,

[QUESTION] How can I create infill within a custom geometry?

What are you trying to do?
I'd like to create a pyramid (3 faces) with an infill, making possible to adjust the dimension of this pyramid without breaking the infill. All of this in a continuous path.

What have you done so far?
I succeeded creating the first two layers of the pyramid but struggle with the next layers as followed:

Capture d’écran 2024-01-17 à 10 48 12 Capture d’écran 2024-01-17 à 10 48 18

What do you still need to do?
I'd to complete the pyramid and getting that continuous path.

What is your question
I'm looking for technical advice using FullControl, such as which feature is better to use in that case and how to achieve it.

Thank you!

Tim

[infrastructure] Add issue and pull request templates

Github has quite extensive support for Issue and PR templates, which can be quite helpful for recommending a particular structure for suggestions and bug reports/fixes and the like, while also automatically adding some labels to them.

This isn't particularly critical for a small project, but guided steps lower the barrier for entry to newcomers making valuable suggestions and contributions, and becomes more important as the number of submissions grows.

If it's of interest, these are the issue templates my work uses.

[feature] Mesh Export

It was raised in #18 that it could be desirable to export the generated mesh of the printed extrusion, potentially as an STL file or similar.

Conceptually that should mostly involve a small amount of data wrangling to create data in an appropriate format, but I think it's important to establish the context and desired features first, so we can determine which file format(s) are most valuable to support exporting as.

A few potential considerations as a starting point for discussion:

  • Some applications require closed meshes
    • This should be achievable using the capped option in tube_mesh.py
    • I'm unsure whether there could be issues if the mesh is self-intersecting
  • Generated extrusion paths can have multiple parts
    • This may not be supported by all file types and may be precluded by / incompatible with a closed mesh requirement
  • The data we generate is more extensive than just geometry, and it may be valuable to be able to save some/all of the extra information
    • Colours is a potentially big one here, along with things like travel movements, temperature/speed changes, and possibly things like tool type and/or orientation as use-cases expand
  • Different file types have varying degrees of data compression, and small files are likely desirable (especially for large models)

I think we should make a list of features we care about, then turn that into a comparison table for viable file type options, and use that to determine which file types make the most sense to implement. Here's a quick first pass:

File Type Colours? Normals? Lines? Multi-part? Physical Units? Animation? File Size? Expected
Implementation
Difficulty?
STL Non-standard Required No ? Non-standard No Ascii: big
Binary: small
Easy-ish
(need normals)
OBJ Yes
(external)
Optional Yes ? Non-standard No big-ish Easy-ish
PLY Optional Optional Optional Optional Non-standard No Ascii: big
Binary: small-ish
?
AMF Optional Implicit No Yes ? No XML: big
zipped: small
?
3MF Optional ? ? Yes Yes ? XML: big-ish? ?
glTF Yes Optional ? Yes ? Yes ASCII/JSON: small-ish?
binary: small
Likely complicated

Physical realism coverage

Somewhat following on from #18, why stop at physical volumes? Perhaps it's worth considering additional features that would turn the gcode tool-path into a physically realistic display.

I'm opening this issue as a general/overview thread, with the intent that in-depth discussion of any given feature can be split off into a separate issue / PR. It's possible some ideas will be out of scope for what this project is intended to do/include (e.g. if overly focused on 3D printing).

Some starting ideas

  • filament path -> extrusion volume (#18)
  • collision detection (#21)
  • workspace / machine visualisation
  • tool-path/extrusion animations
  • timing estimates
    • needs an understanding of machine speed and acceleration limits
    • valuable for both manual and automated optimisations
  • material droop simulation
    • would need modelling of material bending properties (including tensile strength when bridging), possibly across some kind of temperature curve (in which case there'd need to be some form of thermal simulation)
    • could be incredibly valuable for predicting the appearance of prints from more exotic materials (e.g. clay/ceramics, glass, chocolate, etc)
  • thermal warp path correction
    • e.g. Relativity Space does this for their 3D printed rocket engines

SVG import

SVG import function will be awesome. I want to integrate typography and other shapes to use in FC to create some cool designs.

I think this will be very useful for those using FC with a laser cutter, pen plotter, and vinyl cutter(?).

Thank you!

Printing complexe biomaterials/ custom printer

Hi everyone,
I'm trying to print foamy material using FullControl. However and as I'm new to it, I encountered some difficulties.
I'm using an Artillery SWX2 printer, on which I've installed a print head (motor-driven piston syringe). The syringe has a capacity of 300mL and the extruded material is foamy. This is cold printing. I'd also like to be able to create a single print layout.

Would you have any idea on how I could:
-Correctly fill-in the parameters of this type of bespoke printer in the sheet
-Handle the flow rate of foamy material during the print

Thank you very much in advance,
All the best,

Tim

[suggestion] 2D plotter / drawing / printing option

It'd be nifty for people to be be able to put in some text or an image and get a meaningful gcode output, for things like drawing with a pen (or painting) on a page, or printing a design onto some fabric, or printing as a top layer that then gets painted or used as a stamp.

A couple of spit-balled ideas:

  1. allow text input that draws the letters with single width passes (instead of the doubled borders a slicer would tend to make)
    • would require one or more fonts to be included, which could either be manually defined as points, or (more advanced) automatically converted from common computer font files
    • to some extent this is covered by #11, but I'm thinking of filled fonts rather than letter outlines
  2. allow (raster) image input that gets drawn in some interesting way
    • Canny edge detection would be a quite simple option, to draw just the detected edges from the image
    • more advanced/artistic approaches could do some form of shading using things like
      • variable width parallel lines with even spacing
      • squiggly non-crossing fixed width lines that use some form of iterative point adjustments to create lighter and darker regions by density
      • variably spaced hatches
      • variably oriented straight lines that each cover the darkest remaining line in the image
      • variably sized filled circles, either in a grid or haphazardly packed
      • something Voronoi based
    • this kind of thing might require Pillow or opencv as a dependency, in which case it could be useful to create multiple install targets depending on what features people want (e.g. pip install fullcontrol[all] vs pip install fullcontrol[minimal] and such)

[FR] Colors transition off

I'm using color_type='manual' to highlight property changes (e.g. speed) in the design. The transition between the different colors make the result look wrong.
Is there a way to have a hard cut over to a new color?

[QUESTION] Pen Plotting with Rotating Tool (2.5 Axis)

I am designing a variable line width pen plotter with a rotating z axis. The line thickness is determined by the rotation of the marker tool. (perpendicular/90deg to tool path tangent = on/full width)

0001-0240.mp4

I am using Blender's geometry nodes to pre-visualize/design a variable line width plot. I'm then exporting as an indexed, 3 coordinate list. Below is a sample of the .ply data from Blender (X, Y, Rotation in Radians)

ply #concise coordinate in meters, x,y,rotation
format ascii 1.0
comment Created in Blender version 4.0.2
element vertex 9216
property float x
property float y
property float z #radians
element edge 9088
property int vertex1
property int vertex2
end_header
5.5847714e-08 1.8739383 0.676805 #first coordinate with rot value
0.014846257 1.8739147 0.67858016 #second...
0.029689893 1.8737563 0.6825235
0.04452504 1.8733462 0.68454605
0.05934261 1.8725877 0.6866971
0.074131355 1.8714039 0.6933933
0.08887847 1.8697386 0.702613
0.103570454 1.8675553 0.708761
0.118194 1.864838 0.7144503

I plan on building a CoreXY rig with a stepper at the head controlling marker rotation, converting that z coordinate into degrees rotation. Currently, I'm appending/replacing the z coordinate with the calculated rotation (based off of the sampled image/curve tangent) out of convenience. This format could change, it would just be a matter of appending the rotation value to one of the 3 color coordinates that .ply can also store. Whatever makes more sense for this implementation.

I don't have Excel and was reading the overview doc for the python implementation. Are there objects/templates that allow for the import of a coordinate list like the one above (or any indexed coordinate list, was using .ply as a debug) for it to be properly read by FC?

Additionally, curious how you all would approach the z-axis rotation. That would be messing with the FC design, as this plotter is a thing that does not factor in states associated with FDM. (working exclusively in travel paths, no layer heights, etc.). I am a complete python/scripting novice, so would appreciate a layman's response (if possible).

Thanks
dhumpo

About adding a new printer

Hello, I wanted to know if there is documentation of how to add a new printer. I have an Ender-6. Thank you in advance.

[Q] Multiple Walls

I have described a profile via its point coordinates that represents the outer wall of a design. Is there an elegant way to turn these steps into multiple walls, each correctly offset in x and y by the extrusion width?

True Arc Commands (G02 G03)

Quite a few 3D printers today support true arc commands which have some worthwhile benefits. These GCODE commands (G03 and G03) produce smooth arcs with significantly less GCODE which eliminates faceting on model surfaces during prints, makes for less machine jerking, and in some printers, helps with buffer overflow.

Some slicers today implement these movements either by accepting vector model files (step for example) or by utilizing ArcWelder and similar approaches to transform sets of 2D moves that look like arcs back into proper arc commands.

As a simple example of how this plays out, this draws 4 circles in a row (my example here was based around experiments for making FullControl parameterized battery pack cell holders):

from math import tau
steps = []
cell_diameter = 21.2
segments = 90
clockwise = True
for i in range(4):
  circle_center = fc.Point(x=50 + (cell_diameter*i), y=50, z=0)
  steps.extend(fc.travel_to(fc.geometry.polar_to_point(circle_center, cell_diameter/2, 0.25*tau)))
  steps.extend(fc.circleXY(
    circle_center, cell_diameter/2, 0.25*tau, segments, clockwise
  ))

fc.transform(steps, 'plot')

The GCODE produced from this, excluding all the printer start/prime/stop stuff, is something to the tune of 364 commands.

Here's the same result (minus E amount, I don't know how to calculate that):

G21 ; set units to millimeters
G91 ; relative positioning, makes the below coordinate movement easier
G0 X21.2 Y21.2
G2 I0 J-10.6
G0 X21.2 Y0
G2 I0 J-10.6
G0 X21.2 Y0
G2 I0 J-10.6
G0 X21.2 Y0
G2 I0 J-10.6

The end result of 4 printed circles is the same, but the G2 commands will produce much better print results.

[suggestion] support FFF lathe machine type

Came across this video and found it interesting.

Haven't seen / thought of that type of machine before, but it seems like the kind of thing that could benefit from a full-control gcode creation process. It's like a polar printer, but instead of having a rotating circular platform as its base, it has a rotating cylinder that the filament attaches to and is built up around, which makes it possible to make some interesting shear- and bending-resistant springs and tubes and the like.

Pydantic version issue

Issue Description:
The project is not working with pydantic version 2.0.2. I guess v2 and above. At import (import fullcontrol as fc) the following ValidationError is thrown:

  File "~\Projects\fullcontrol\fullcontrol\gcode\state.py", line 24, in State
    point: Optional[Point] = Point()
  File "~\Projects\fullcontrol\.venv\lib\site-packages\pydantic\main.py", line 150, in __init__ 
__pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__)
pydantic_core._pydantic_core.ValidationError: 3 validation errors for Point
x
  Field required [type=missing, input_value={}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.1.2/v/missing
y
  Field required [type=missing, input_value={}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.1.2/v/missing
z
  Field required [type=missing, input_value={}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.1.2/v/missing

Current Environment:
Commit 0e89b2f
Pydantic version: 2.0.2
Other dependencies: plotly, numpy

Expected Behavior:
No error at import.

Steps to Reproduce:
Install Pydantic version 2.0.2.
Run import fullcontrol as fc
Should cause a ValidationError.

Fix Proposal:
Include the recommended version ranges in the requirements.txt file (eg. pydantic<2.0.0) or update the type definitions so that pydantic v2 is happy. I tested and verified it is working with the versions pydantic-1.10.11 and pydantic-1.10.5.

If you require any further details, please let me know.

btw. really love your work, can't wait to try it, thank you!

offset_path

Hello,
Thank you for the useful program.
Just one thing,
I am trying to use offset_path on my laptop but I am receiving following error:
module 'lab.fullcontrol' has no attribute 'offset_path'
I have added Fullcontrol package by following command again, but there is still the error mentioned above.

pip install git+https://github.com/FullControlXYZ/fullcontrol

Thank you
Mohsen

GCODE save filename date and time

Is there is a way to turn off the automatic appending of the date and time to the gcode file name?

I would like to have FC export the gcode the same as the design name only without the date and time so it fits within my workflow.

Thank you!

Addressing Offset Path Function Behavior Near Corners

The current implementation of the offset path function exhibits undesired behavior near corners, where points that are close together result in an offset that may not align with user expectations. This is primarily due to the function offsetting each point normal to the instantaneous path direction.

371491743_641498467892943_7292232246143806782_n

[Q] Extrusion thickness vs. nozzle diameter (extrusion_width)?

I'm hoping to make something of a "Vase Mode" object by describing the path with FullControl, which is relatively straightforward, but I'd like to be able to vary the amount of material extruded to get a thicker line. Similar to the way the Pin Support Challenge has a parameter for Pillar Diameter.

I'd appreciate any help in finding the direction to start. If I could replicate just that pillar, I think I'd be a bit on my way to the solution I'm seeking.

I think I want to have some multiplier for the E parameter in a G1 code, but I'm not sure if that's the right direction, nor how to express that with this library.

Any guidance would be appreciated. Thanks!

angleXY_between_3_points returns outside angle

Hi there!
I created an implementation for an arc which goes through three points, it is functioning in my fork of fullcontrol, it's called three_point_arcXY. It has several added functions to achieve this. It uses arcXY to draw the final arc, with the arc_angle being obtained from the angleXY_between_3_points. In three out of four cases, the arc_angle is displayed correctly, however, one out of four cases has the outside angle around three points displayed.

Case 1:
WhatsApp Image 2023-09-17 at 18 55 02_26ffdcca

Case 2:
WhatsApp Image 2023-09-17 at 18 57 29_cbe39527

Case
WhatsApp Image 2023-09-17 at 18 57 43_7adf8af1
3:

Case 4:
WhatsApp Image 2023-09-17 at 18 56 48_89083743

I could not resolve this, so I added an invert option to three_point_arcXY in the meantime.
My guess is that this is because of something in angleXY_between_3_points going wrong.

Hope you can help me out :)

Best regards,
Hannah

README suggestion

This is very minor but may I suggest adding slightly more detailed information for using the notebooks locally. I'm just thinking about newcomers and beginners wanting to dip their toes into FC.

I'm currently using the FC notebooks with VSCODE (with python and jupyter extensions) and works great.

SVG Export

I've been getting some really cool shapes in FC and want to export it to SVG.
Since FC can do SVG import now, is it possible to export the paths/points in FC to SVG?

Thank you!

[suggestion] two-colour lithophane alternative / hologram example

  1. Base layer is full blank
  2. Middle layer is straight lines of the contrast colour, only covering every second column
  3. Top layer is wiggly lines of the blank colour, stacked on the middle layer lines, where deviating from the column centre shows more of the contrast colour

Idea originally shown and explained by u/Vicckkky on Reddit.

Most illustrative snippet of their posted video:

Screen.Recording.2023-09-09.at.9.48.18.pm.mov

Safety Check Function?

2023-04-28 00 40 57

The above model was created with FC Web using the ripple texture demo and printed on a Prusa MK3S+.
The flat surface that you see is caused by the model exceeding the printable area.

Would it possible to integrate a "safety check" function where the design is evaluated against the printer profile such as the bedsize and other hardware limits (temperature, travel speed)?

Thank you for making FC!

Z Travel Speed

Is there a way to set the travel speed to a different value for the z axis?

Ive got a unique printer and it can run at pretty high travel speeds (18000 mm/min) but the z axis needs to move considerably slower (1000 mm/min)

Thanks
-Ben

Documentation for installation

Please note minimum Python version:

ERROR: Package 'fullcontrol' requires a different Python: 3.8.13 not in '>=3.9'

For Windows note that it will be necessary to install:

and it would be very helpful to have a specific link to a complete, minimal working example, as well as notes on how the G-code will be previews.

Fun with projective perspective (+ seeds of a new logo/icon?)

I've seen some cool projective perspective examples recently where depending on the angle an object is looked at it can show different things. I had some offline time on a flight and decided to try my hand at it for "Full Control", and thought the result was worth sharing:
https://gist.github.com/ES-Alexander/84a0f12d097d409bf70fed07f252ae91

Currently this is a relatively low level example of tube mesh generation, but if we wanted to we could turn it into a gcode example that then goes through the standard plotting process, with the caveat that although it looks cool it's likely not particularly practical as a 3D print.


No idea if there's interest in changing the project logo, but my idea there is it could be fun/interesting to have an icon/image that starts with F_U_L_L at the top, then shows one or more transition angles below, followed by CONTROL at the bottom. In my head that (for some reason I don't understand) feels like a nice indicator of what kinds of things can be created/done with the project.

e.g. something like the following (left ones have a transparent background, bottom ones have thicker letters and shrunken transition displays):

FullControl_alpha                FullControl_dark


FullControl_alpha2                FullControl_dark2

[BUG] PlotControls style='tube get errors line not

this line;
fc.transform(steps, 'plot',fc.PlotControls(style='line')) works perfectly but,
fc.transform(steps, 'plot',fc.PlotControls(style='tube')) couse errors;

TypeError Traceback (most recent call last)

in <cell line: 33>()
32
---> 33 fc.transform(steps, 'plot',fc.PlotControls(style='tube'))
34

/usr/local/lib/python3.10/dist-packages/numpy/lib/function_base.py in diff(a, n, axis, prepend, append)
1445 op = not_equal if a.dtype == np.bool_ else subtract
1446 for _ in range(n):
-> 1447 a = op(a[slice1], a[slice2])
1448
1449 return a

TypeError: unsupported operand type(s) for -: 'float' and 'NoneType'

code link: https://colab.research.google.com/drive/1fwnmY33js1wj_RPKJqOIKz8EYxWbbSyh?usp=sharing

Printing between fc.move repeats

When using fc.move to repeat a part (or segment of a part in this case) in the x,y plane, a print line is created between the parts.

Is the a way to make this a travel move?

I have the list of commands being repeated ending with
rep.append(fc.Extruder(on=False))

it ends up looking something like this
image

Many thanks

[feature] Rounded Square wave

I made a new wave type, its basically a square wave with circular peaks and troughs. It was just for a small test project I was trying but figured it may have use elsewhere so I have made a gist for the wave and included example output below showing that it has the same flexibility as the existing square wave.

image

Let me know what you all think

[FEATURE REQUEST] Add security policy

Is your feature request related to a problem? Please describe.
There appears to be no way to understand what to do if there is a security bug

Describe the solution you'd like
Add a policy to the security tab

Describe alternatives you've considered
Can be in the readme but the security tab is probably best

Additional context
NA

Documentaion / Reference website

Thank you for all the work put into creating the examples in the python notebooks.

I'd imagine you'd be adding much more functions to FC. Going forward, may I suggest creating a wiki?
I always found the doc pages for Processing to be very convenient to use.

Thank you!

[suggestion] two-colour gradient (woven dithering) example

Technique presented by u/Vicckkky on Reddit, and

based on a research paper called Dual-Color Mixing for Fused Deposition Modeling Printers by Tim Reiner, Nathan Carr, Radomír Mech, Ondrej Štava, Carsten Dachsbacher & Gavin Miller.

Illustrative screenshots taken from the posted video:

woven dithering results woven dithering internals

I haven't looked at the paper, but from the display it seems to be two anti-phase-locked sinusoids of different colours that are offset, and either the offset or amplitude is varied to provide a variable proportion between the two colours. The technique could be applied to a flat shape, but for structural stability during printing it likely makes sense to include some base curvature unless it's part of an existing more stable structure.

[suggestion] Collision detection

This could be varying degrees of difficult depending on how it's approached, but it seems like a valuable feature for any kind of tool-path generation software.

My personal preference would be the codebase being refactored such that everything stems from a base Machine class, which has 3D Printer as a sub-class, and 3D printer types can have specified frame and bed geometries, and get initialised with a particular nozzle. The tool-path generation and plotting could both be handled by the selected machine, which should simplify plotting different types of machines (and animations once that's relevant) and should also simplify the logic for when a collision could occur (because e.g. a cartesian printer will have some different collision opportunities compared to a delta or polar printer).

That said, I'm sure it's also possible by adding a more general collision detection module into the existing functionality-focused abstraction.

Helix requires Z to be defined

I ran into a issue that took me a bit to figure out. if you create a helix without defining a z coordinate (even if its starting at the same point as the previous line) the helix is flattened into a circle or a spiral if the helix is tapered.

I resolved my issue by defining the z coordinate in the helix center point

Disable extrusion for moving to start point of circle or other shape

I'm wondering if there's a way to disable extrusion when the print head is moving to the starting point of a circle. I'm using using a custom printer with custom start and end gcode and a custom primer, and then want to go into my actual print. I've noticed that when I define a circle, the line from where I am at the end of my primer to the beginning of the circle is extruding.

The obvious workaround is to do a travel_to to the starting point of the circle but then I have to code in that starting point based on the center point, start angle and radius. Not the end of the world but I could see this getting cumbersome for more complex shapes & gcodes.

image

Adding to the printer_library

I have been attempting to my printer to the printer_library but have been running into some problems. I followed the steps in the read me:

  1. copy an existing module (e.g. ultimaker2plus.py)
  2. rename it to your printer name
  3. change 'printer_overrides', 'starting_procedure_steps' and 'ending_procedure_steps' - leave the rest of the module unchanged
    1. in your design set 'printer_name' in a GcodeControls object to be the name of the new module

However, when I run my design I keep getting this error:
ModuleNotFoundError: No module named 'fullcontrol.gcode.printer_library.singletool.ender_3copy'

I initially got this with my printer profile (UDIO) but to check it wasn't something I broke in the printer module, I ran it with a unchanged copy of the ender 3 profile titled ender_3copy (saved in the same singletool folder). It runs fine when I set my gcodeControls object to the ender_3 module, but get that error when I use the idential module titled ender3_copy.

Im not sure if im doing something wrong with the GcodeComand in my design or if im missing a step in making the new module for my printer.
Or something else?

Thanks

Grid /plate design using square waves

I made a practical design for use as a LED Matrix diffusor.
https://colab.research.google.com/gist/scamiv/92495fe963bf4ebaec8c7f5f459fb99d/fullcontrol_ledMatrix_grid.ipynb
Thing: https://www.printables.com/model/709532-fast-print-fully-parametric-led-matrix-cover-diffu

I would greatly appreciate any feedback on how to solve this more elegantly.
Problems i had/have:
Currently the size of the base plate wave seems slightly smaller than expected.
Is there a function the get the last point in a step list? Especially if the last object is a settings change rather then a move?
Could the rectangle direction be expressed as a vector?
Midpoint or bounding box for Square-Wave would be super useful.

Add repo description

Please add a repository description here on GitHub. For example, just copy the first sentence from your README there.
Among other places, this description shows up in "social Media Preview" of the repo, so for example when you post the link to the repo on Telegram.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.