Does anyone have a good idea to modify HAL?

More
6 years 2 months ago #177206 by Gorgc
i used to work on codesys, and I found that it has many similar ideas to linuxcnc hal. well, the code of codesys is much stronger, even if it is closed source, from its oem code, the organization is much stronger than that of hal. But hal can already be regarded as a good iec prototype.


I hope hal can have its own simple compilation environment to do some industrial process control. Also need to add function code area, global variables, if condition judgment, etc. Other modifications include module instantiation, variables and module pointers, module variables have a fixed area (input and output are no longer connected by pointers).

I want to know what hal has in-depth plans? Or has someone made some stronger mods?

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #177226 by Mike_Eitel
Sorry if i might offend you, but
I'd say i know codesys since a while (ca since 97) and was quite involved. And I totaly dissagree with your opinion of similarity to hal. But there is an easy free solution:

www.openplcproject.com/ They even have a nice modbus/tcp io module implementation for esp's.

Mike

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #177243 by tommylight
I never used Codesys, but jumping to conclusions is never a good idea.
From that title, what would be a "good idea" ?
Hal is very versatile and can be modified extensively, CNC IS and industrial process control, so yes it can do industrial process control, and LinuxCNC has a compilation "environment" for compiling real time components, if any already does not exist.
You could start here :
linuxcnc.org/docs/html/hal/components.html
LinuxCNC also has Classic Ladder if you are more familiar with PLC.

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #177244 by cmorley
Machinekit has extended HAL to include mutiiple instantiation of a module, among other things.
I know of no plans to expand linuxcnc's HAL in the future.

Chris

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago - 6 years 2 months ago #177247 by Cerna
Hmm, I don't know CODESYS, but at first glance at the website www.codesys.com it certainly does share similarities.

I hope hal can have its own simple compilation environment[...]

Could you be more specific what you mean by this?

Also need to add function code area, global variables, if condition judgment, etc.

I would say that all this is in current implementation of HAL. Global variables are in terms of HAL shared memory segment the HAL Pins, conditions can be had in HAL functions which are run as a part of main loop. (I don't know what to image under the add function code area.)

[...]include module instantiation, variables and module pointers, module variables have a fixed area[...]

LinuxCNC's HAL doesn't have instantiation (and probably never will), variables are HAL Pins. Could you specify what you mean by module pointers (how it could be used)?

Also, there is no real-time memory allocator, as far as I know, so fixed area for module variables will probably not change.

Thanks.
Last edit: 6 years 2 months ago by Cerna.

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #177250 by Mike_Eitel
Hi Tommy
I saw you discussing to touch a huge machining installation with 28 plc's. So i guessed you know a bit about codesys. This is probably the widest spread plattform of IEC 61131. If you do not go to a few suppliers like Siemens, B&R,.. it is the defacto plattform of coding serious plc's. Since some years (never tried it) it even includes some motion parts (a bit cnc). And since a few years they made the clever jump to support rpi, bbb. You pay low price for runtime systems on those, declaredas non proffesional, devices. 50-90€.
Mike
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

Time to create page: 0.088 seconds
Powered by Kunena Forum