Generating coil spring drawings from a web application
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
Be nice to others! Read the FreeCAD code of conduct!
Generating coil spring drawings from a web application
Dear Friends,
I am new to FreeCAD. I am developing a Web application for designing coil springs (Compression, tension, torsion). Like this one (this is in the early stage of development) https://mani-developer.github.io/springdesigner/ . Instead of having a static image of the spring, we would like to generate the drawing using FreeCAD based on the customer input parameters and display the same on the screen (either as image or pdf). Have any one tried anything similar to this ? Could you please guide me on how to proceed ?
I am new to FreeCAD. I am developing a Web application for designing coil springs (Compression, tension, torsion). Like this one (this is in the early stage of development) https://mani-developer.github.io/springdesigner/ . Instead of having a static image of the spring, we would like to generate the drawing using FreeCAD based on the customer input parameters and display the same on the screen (either as image or pdf). Have any one tried anything similar to this ? Could you please guide me on how to proceed ?
Re: Generating coil spring drawings from a web application
hi
c'est beau ça
for FreeCAD i make this macro Macro_FCSpring_Helix_Variable and simulate animation Macro_Spring (without sweep)
convert it in Java ...
mario
c'est beau ça
for FreeCAD i make this macro Macro_FCSpring_Helix_Variable and simulate animation Macro_Spring (without sweep)
convert it in Java ...
mario
Maybe you need a special feature, go into Macros_recipes and Code_snippets, Topological_data_scripting.
My macros on Gist.github here complete macros Wiki and forum.
My macros on Gist.github here complete macros Wiki and forum.
Re: Generating coil spring drawings from a web application
Hi,mani_gs wrote: ↑Thu Apr 30, 2020 3:56 am Dear Friends,
I am new to FreeCAD. I am developing a Web application for designing coil springs (Compression, tension, torsion). Like this one (this is in the early stage of development) https://mani-developer.github.io/springdesigner/ . Instead of having a static image of the spring, we would like to generate the drawing using FreeCAD based on the customer input parameters and display the same on the screen (either as image or pdf). Have any one tried anything similar to this ? Could you please guide me on how to proceed ?
I did a lot of similar stuff, run FreeCAD at backend and show recomputed model to user on web browser.
I suggest you to use https://hub.docker.com/r/amrit3701/freecad-cli docker image for your web application. In this image, I compiled FreeCAD without GUI and it gives better performance.
You can use OBJ format as communication between FreeCAD and Web.
To render OBJ file on web browser you can use Three.js. Here is the example of how to load OBJ file in three.js (https://threejs.org/docs/#examples/en/loaders/OBJLoader)
How does the whole cycle work?
Get parameter from frontend -> Change parameter values in FreeCAD -> Recomputed model -> Export OBJ file -> Send OBJ file to frontend -> Three.js load OBJ file and render your model on web browser.
Thanks,
Re: Generating coil spring drawings from a web application
@amrit3701 Nice!amrit3701 wrote: ↑Thu Apr 30, 2020 9:37 am I suggest you to use https://hub.docker.com/r/amrit3701/freecad-cli docker image for your web application. In this image, I compiled FreeCAD without GUI and it gives better performance.
Perhaps we can add this to Compile_on_Docker or some variant page?
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Re: Generating coil spring drawings from a web application
Even for somebody so far away from web applications as me, this really sounds cool!
- sliptonic
- Veteran
- Posts: 3459
- Joined: Tue Oct 25, 2011 10:46 pm
- Location: Columbia, Missouri
- Contact:
Re: Generating coil spring drawings from a web application
CADCloud is the most advanced FreeCAD-powered web application I've seen so far.
The production reference implementation is at justyour.parts.
Here's a torsion spring project I made. The 3D view shows a rendering problem that I think has been resolved now.
The github repo can be found at https://github.com/CADCloud/CADCloud
A gitter community to discuss it also exists.
@vejmarie is the guy to know.
The production reference implementation is at justyour.parts.
Here's a torsion spring project I made. The 3D view shows a rendering problem that I think has been resolved now.
The github repo can be found at https://github.com/CADCloud/CADCloud
A gitter community to discuss it also exists.
@vejmarie is the guy to know.
vejmarie wrote: ping
Re: Generating coil spring drawings from a web application
No, I created apps for commercial companies and all the things are closed source. Anyway, now I am thinking to create a most simple FreeCAD web-based project which illustrates how to use FreeCAD as a CAD engine for 3D web application and share here soon.
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Generating coil spring drawings from a web application
@bernd, and @amrit3701 this is closed to what CADCloud is doing except I am using xeogl as a renderer for the Wavefront OBJ object. We can easily re-implement amrit3701 idea. It is not the intend of CADCloud which is targeting more a github for open hardware project, but that might be a funny feature to add. Latency might be the challenge.
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Generating coil spring drawings from a web application
Thanks for the support. Your bug is going to be fixed pretty soon. I am using on the server side the FreeCAD snap that I maintain (got more than 20k users now !). I just updated it to 0.19 (was soon running 0.19) but with many enhancement like OCCT 7.4 (which was required to fix the mesh generation of the Torsion Spring), qt5, python3 and latest master commit. I just finished to polish it tonight and released it on the snap store as a latest/release.sliptonic wrote: ↑Sun May 03, 2020 5:52 pm CADCloud is the most advanced FreeCAD-powered web application I've seen so far.
The production reference implementation is at justyour.parts.
Here's a torsion spring project I made. The 3D view shows a rendering problem that I think has been resolved now.
The github repo can be found at https://github.com/CADCloud/CADCloud
A gitter community to discuss it also exists.
@vejmarie is the guy to know.vejmarie wrote: ping