Post processor python scientefic notation --> decimal notation

Here's the place for discussion related to CAM/CNC and the development of the Path module.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
karlnick
Posts: 54
Joined: Sat Jul 25, 2020 9:33 am

Post processor python scientefic notation --> decimal notation

Post by karlnick »

Programmed in C and sometimes C++ many years but in python I have a really hard time to figure out data types and structures for variables. Have rewritten a post processor so it work for a FangLing controller it seems controller do not accept scientefic notation or example 2.13e-14 but if I manually edit to ordinary number format it works.

Documentation is sparse but anyone familiar with data model used to store things will probably figure it out fast. File is attached and caught the problem for G2 command J parameter. Could see the parameter is accessed on rows 334 and 340 but find it hard to figure out which functions are available for the "c" variable/structure except Name which I could see is used.

Need to find the parameter values for X,Y,I,J and possible others and convert from scinetefic notation to ordinary dot format.
Attachments
FangLing_post.py
(17.74 KiB) Downloaded 24 times
Post Reply