-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Architecture LinuxCNC-block-diagram - update #3718
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
I am surprised to see spindles in EMCIO. I am pretty sure those are in EMCMOT. So the whole EMCIO block is probably not there any more. |
|
I am interested only aboat 2.10 version. I made quick modification:
If I understand correctly, here are the HAL pins of the TASK: linuxcnc/src/emc/task/taskclass.cc Lines 46 to 70 in 764655e
|
|
Yes, though the lube pins don't exist any more. (They didn't have any useful behaviour) The tool-change pins are missing from the diagram. (change / changed and number for both tools and pockets). They always have been despite being the main point of emcio. |
|
@c-morley disagrees with me that HALUI should not be associated with GUI
I understand the functional reasons, but I would be interested in others' opinions from the perspective of preserving the architecture. |
|
If we are going to replace this diagram I suggest to
|
|
HALUI should not really be in this view. |
Do you have a model of what you would like the LCNC architecture to look like? Do you know of any open-source projects with architecture? Do you prefer graphviz or mermaid? I have no experience with software architecture, but I am convinced that we need it. At least do it in reverse. |
HALUI is part of LCNC. It is an inseparable part of Gmoccapy. We can discuss:
I am interested in both states. How it is and how it should ideally be. I want to update this picture mainly because of HALUI. HALUI is a specific component and therefore I would like to know its current function and whether we want to continue using it this way. The abbreviation HALUI is "HAL User Interface", but at the moment HALUI serves more as an engine for Gmoccapy. If I removed HALUI from the architecture, I would de facto stick my head in the sand like an ostrich. Maybe no one will want to discuss it. |
|
I didn't find the source of the architecture diagram, I guess at some point in time it originated in xfig. Some translations also translated this diagram and even colorized it. With a vector format, we could do better and make that consistent. I played around a bit with draw.io, will attach a draft later. |
|
This diagram is to show the basic architecture of linuxcnc. It is not to show a typical setup. HALUI is equivalent to the GUI and so just adds detail that is not needed. I would suggest making another diagram that shows a typical setup maybe including Mesa card/ spindle control/ ethernet servo? In this diagram one might show task/motion as just one box called motion controller. If Gmoccapy requires HALUI to be useful then IMHO a undisearable limiting choice has been made. One should be able to use a different program the HALUI such as panelui or a custom program. |
It is.
It really shouldn't be.... I am curious what Gmoccapy relies on in HALUI that isn't available to it from the Python interface? Maybe this is a throwback to the fact that Mocca was written in Pascal ( https://forum.linuxcnc.org/41-guis/1813-new-gui-for-emc-available-for-testing?limit=6&start=0#1813 ) and we have no LinuxCNC Pascal interface. |
I agree that some of the HAL pins created in Gmoccapy make sense, for example this: linuxcnc/src/emc/usr_intf/gmoccapy/gmoccapy.py Lines 6188 to 6197 in 781023e
But creating pins like these seems weird to me: linuxcnc/src/emc/usr_intf/gmoccapy/gmoccapy.py Lines 6271 to 6276 in 781023e
For the other pins created by Gmoccapy, I can't determine whether they are there just because of Python interface shortcomings, or whether they have a purpose.
I dont know what is available to it from the Python interface. Here are halui pins in Gmoccapy: linuxcnc/src/emc/usr_intf/gmoccapy/gmoccapy.py Lines 3797 to 3812 in 781023e
I don't know if this is about using hal signals in the glade file. But they are called hal: linuxcnc/src/emc/usr_intf/gmoccapy/gmoccapy.glade Lines 180 to 202 in 781023e
|
I guess I'm wrong. Gmoccapy uses a function named "def _update_halui_pin(self):" , but it doesn't use halui pins. Edit: |
|
To rmu75: |
|
My two cents, while draw.io has been around for a while mermaid or LaTeX might be preferable so it can be maintained with the source code. |
|
I redrawn the diagram in drawio. linuxcnc.architecture.drawio |
|
I don't think that there is a PID in Motion, the ones I know of are in HAL components. (there is a simple one in stepgen as well as the the standalone PID) |
(Possibly spindle-synch motion) |
|
Again, I believe you are adding too much information for what this diagram is for. |
spindle sync does not use PID |
|
I must say though - the drawings do look much nicer! |
|
That really starts to look very nice -- thanks a lot!. Some comments:
|
|
Now I'm at the stage where I redrawn the image in drawio and added HALUI there. I consider adding HALUI very important because many Pull Requests are created that do not respect the original concept of HALUI and GUI. I myself was confused about this, thinking that HALUI was part of Gmoccapy. There may be a change, for example, HALUI may be canceled, or HALUI and GUI may communicate with each other, or ...... But now at least we have the current state. I've done the simplest thing. The difficult part is just beginning. Chris:
Give me a chance to convince you that the amount of information I want to put in this diagram is right. I understand that the more information I put in this diagram, the more work I will have to maintain it. On the other hand, I believe that the maintenance of this diagram outweighs its benefits. I expect that developers will contact me and I will modify the diagram in the future. If I stop enjoying it, it will be easy to simplify the diagram. Chris:
I agree. I made extra diagram for integrators and begginers. #3738 rmu75:
I would be happy if you could help me with this. rmu75:
I thought so, but I didn't solve it during the phase of redrawing the diagram into drawio. rmu75:
My goal is to make a diagram where the heart of LCNC is the TASK module and the interface is the HAL layer. This diagram should be intended mainly for developers. Moreover, the boundary from TASK to HAL is always the same, or similar. The boundary from HAL to hardware is unique for each integration. I do not want to draw the boundary from HAL to hardware here, or only very simplified as in the upper part of the figure (non-realtime hardware). I want to delete the lower part of the figure "Example of Hardware". I think that most LCNC applications do not use an encoder on the axis. If someone wants to draw a diagram for integrators with specific hardware, I can do it, but it would be another diagram tied to this core. |
just remove "NML" from the arrows or replace with "FIFO" (first in first out).
don't overthink this, i just meant another rectangle just like the "JOINT 0" group around "encoder counter", "D/A converter" (notice also typo there), I would call that "INTERFACE". and perhaps add "field I/O" and connect the switches box. I would have done that myself but the .drawio you attached seems to be my initial draft? |


I tried to update the block diagram of the LinuxCNC architecture. I would like the image to include both the ideal state and the current unwanted state that has arisen.
I am currently observing that some problems are being solved at the frontend level, instead of being solved at the background level.
When I started with LinuxCNC, I was missing a display where the HAL is. So I drew it.
If anyone knows how other parts of LCNC should work that would be good to draw. Feel free to send them to me drawn with a pencil on paper and photographed with a mobile phone. I can then draw them in the image.
I will be happy if there is a discussion about my proposal.