Rando hal component collections

  • blazini36
  • Away
  • Platinum Member
  • Platinum Member
More
20 Jan 2025 12:57 #319457 by blazini36
Rando hal component collections was created by blazini36
There's some good hal components just floating around in this forum that were never submitted to linuxCNC. I just found one to "blink" an LED during a search since surprisingly, there isn't a simple way to do it in HAL at the moment. I tested it quick and it seems to work fine.
forum.linuxcnc.org/24-hal-components/29015-hal-blink-component

Not sure if a collection thread already exists but, I've found others over the years. One was just a lump of code that Andy threw in a thread that I copied out and had a friend improve a bit. I submitted that as the "spindle-monitor" component which I guess we forgot to credit so the maintainer just authored it eventually.

I figure there's some other useful components out there that are maybe not well tested, or maybe not 100% finished. If anything like that is floating around post it up!
The following user(s) said Thank You: tommylight, spumco

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

  • tommylight
  • tommylight's Avatar
  • Away
  • Moderator
  • Moderator
More
20 Jan 2025 18:23 #319479 by tommylight
Replied by tommylight on topic Rando hal component collections
Had i known it would be such a big deal i would have posted hal parts for monitoring Yaskawa servo drives i did when retrofitting the Hurco, used all 4 of 7i77 analog inputs, drives had a 3.3V output for 100% and i think it was 5V max for 150%, worked like a charm, had sliders with changing colors depending on load so i could see from across the shop if any drive or spindle is overloaded. Unfortunately had to change the drives as one was DOA and another one failed during testing. Changed the drives to Argon and changed the config that is attached on the Hurco retrofit page here on the forum but has no feedback.
-
if and when necessary, i will delete this post to keep it clean.

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

More
21 Jan 2025 01:43 #319513 by spumco
Replied by spumco on topic Rando hal component collections

There's some good hal components just floating around in this forum that were never submitted to linuxCNC. I just found one to "blink" an LED during a search since surprisingly, there isn't a simple way to do it in HAL at the moment. I tested it quick and it seems to work fine.
forum.linuxcnc.org/24-hal-components/29015-hal-blink-component

Not sure if a collection thread already exists but, I've found others over the years. One was just a lump of code that Andy threw in a thread that I copied out and had a friend improve a bit. I submitted that as the "spindle-monitor" component which I guess we forgot to credit so the maintainer just authored it eventually.

I figure there's some other useful components out there that are maybe not well tested, or maybe not 100% finished. If anything like that is floating around post it up!
 

I've suggested blink.comp be added to mainline (or stuck in a collection thread) ever since I found it.  It's a great component.

forum.linuxcnc.org/47-hal-examples/51805...nted?start=10#294160
forum.linuxcnc.org/qtpyvcp/48020-probe-b...atus?start=10#262593

Tommy - is there anywhere we can cook up a library with user components? Like on the necro-wiki page, but less obscure?

Of course an 'untested' disclaimer along with installation instructions would be helpful.

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

  • tommylight
  • tommylight's Avatar
  • Away
  • Moderator
  • Moderator
More
21 Jan 2025 02:28 #319516 by tommylight
Replied by tommylight on topic Rando hal component collections
Probably here, as far as i can tell, everything else will inevitably lead to here, and google still seems to find the forum easily.

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

  • blazini36
  • Away
  • Platinum Member
  • Platinum Member
More
21 Jan 2025 06:23 #319524 by blazini36
Replied by blazini36 on topic Rando hal component collections

I've suggested blink.comp be added to mainline (or stuck in a collection thread) ever since I found it.  It's a great component.

 

Yeah I was working with it today and it does what it's supposed to but I couldn't get it to do what I actually wanted, which was go into a solid on output without having to add a bunch of other components. I managed to cook up a new one called "flash"

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

  • rodw
  • rodw's Avatar
  • Away
  • Platinum Member
  • Platinum Member
More
21 Jan 2025 11:04 #319544 by rodw
Replied by rodw on topic Rando hal component collections
I just half wrote one here on the forum tonight forum.linuxcnc.org/49-basic-configuratio...-brake-with-linuxcnc
Blink could be improved a lot by using fperiod() so the on time and off time was specified in seconds if anybody wanted an intermediate project to practice on. :)

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

  • blazini36
  • Away
  • Platinum Member
  • Platinum Member
More
21 Jan 2025 13:39 #319566 by blazini36
Replied by blazini36 on topic Rando hal component collections

I just half wrote one here on the forum tonight forum.linuxcnc.org/49-basic-configuratio...-brake-with-linuxcnc
Blink could be improved a lot by using fperiod() so the on time and off time was specified in seconds if anybody wanted an intermediate project to practice on. :)
 

Well in the post the guy says it requires a floating point thread, but it is a nofp component, so you'd assume it was intended to run in a base thread.

My flash component started off with a counter, but wasn't very accurate timing. I'm using fperiod now, much better.

I say "my" component but really chatgpt wrote it lol. The nuances of comp trip it up pretty hard but you can get through it.
The following user(s) said Thank You: rodw

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

More
21 Jan 2025 14:04 #319567 by spumco
Replied by spumco on topic Rando hal component collections

Probably here, as far as i can tell, everything else will inevitably lead to here, and google still seems to find the forum easily.

What do you think about a new subfolder?
  • Configuring LinuxCNC
    • HAL
      • HAL Examples
      • User-written HAL Components
Maybe with a sticky at the top explaining what the deal is - i.e. non-mainstream HAL components that may or may not do what you want.

​​​​​​​If we just have a single thread called 'HAL User Components' it will instantly get polluted with random comments, tangents, and questions on how to use the component(s).

A sub-folder might help keep it clean(ish) for a little while.

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

  • blazini36
  • Away
  • Platinum Member
  • Platinum Member
More
21 Jan 2025 14:19 #319569 by blazini36
Replied by blazini36 on topic Rando hal component collections

Probably here, as far as i can tell, everything else will inevitably lead to here, and google still seems to find the forum easily.
What do you think about a new subfolder?
  • Configuring LinuxCNC
    • HAL
      • HAL Examples
      • User-written HAL Components



        Maybe with a sticky at the top explaining what the deal is - i.e. non-mainstream HAL components that may or may not do what you want.

        ​​​​​​​If we just have a single thread called 'HAL User Components' it will instantly get polluted with random comments, tangents, and questions on how to use the component(s).

        A sub-folder might help keep it clean(ish) for a little while.

Well anyone can just submit a component via pull request to the linuxcnc repo. Not sure if the maintainers test them at all other than making sure they compile. If it's a good an useful component, there's really no reason not to just submit it via pull request.

I suppose some people just post components they aren't really 100% sure about or haven't fully tested. It doesn't really require an unofficial repo to store them, maybe just a place where people can look at it, maybe test it themselves then submit it. They shouldn't just live in some out-of-repo place if they actually do something useful.
The following user(s) said Thank You: spumco

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

More
21 Jan 2025 15:07 #319572 by spumco
Replied by spumco on topic Rando hal component collections
It doesn't really require an unofficial repo to store them, maybe just a place where people can look at it, maybe test it themselves then submit it. They shouldn't just live in some out-of-repo place if they actually do something useful.

My thoughts exactly.  I was thinking of this sub-folder as a temp holding place for folks to post up components and maybe prove them out or work out the bugs before they - or someone else - submitted a pull request.  "User Component Sandbox"

And possibly there are components that are so edge-case that the LCNC devs aren't interested in adding it/them to mainline.  For those cases a components sub-folder keeps them from disappearing (as much) in the forum if someone later on has the same situation.

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

Time to create page: 0.068 seconds
Powered by Kunena Forum