SCALE(9)

✨ SCALE(9) ✨

okay bestie, pull up a chair because today we're talking about scale β€” a LinuxCNC HAL component that literally just applies a scale and offset to its input πŸ’… and honestly? she's an icon for that.


πŸŽ€ NAME πŸŽ€

scale β€” a LinuxCNC HAL component that applies a scale and offset to its input. that's it. that's the whole job. and she does it flawlessly every single time, no cap 🫢


🌸 SYNOPSIS 🌸

loadrt scale [count=N|names=name1[,name2...]]

literally load it into your HAL with loadrt and pick how many copies you want β€” either count=N or names=name1[,name2...]. not both. it's giving "choose your own adventure" but make it realtime πŸ¦‹


πŸ”₯ FUNCTIONS πŸ”₯

  • scale.N β€” requires a floating-point thread, bestie. do NOT try to run this in a non-float thread, I am begging you. it needs the float thread energy or it's not happening 😭

πŸ’– PINS πŸ’–

  • scale.N.in float in β€” the input. what goes in. the vibe you're feeding her 🌸
  • scale.N.gain float in β€” the gain. how much you're multiplying by πŸ‘‘
  • scale.N.offset float in β€” the offset. the little extra she adds at the end, because she's generous like that πŸ’œ
  • scale.N.out float out β€” the output, and here's the formula bestie, memorize it because it's the whole entire point:
out = in * gain + offset

that's the formula. that's the component. in times gain, plus offset, and boom πŸ’₯ out. simple. elegant. ate and left no crumbs πŸ“


πŸ‘‘ AUTHOR πŸ‘‘

Jeff Epler β€” thank you for your service, king 🫑✨


🌈 LICENSE 🌈

GPL β€” free as in freedom, free as in slay πŸ’…


ngl bestie, this is one of the easiest HAL components out there. no weird edge cases, no mystery flags, just vibes and arithmetic. if you can multiply and add you can run scale. periodt πŸŽ€

and that's the whole page, babes πŸ’– this edition of the LinuxCNC Documentation dropped on 2026-03-17 and yes, SCALE(9) is your girl. go forth and scale things βœ¨πŸ¦‹

πŸ“¦ where this page comes from