diff --git a/VERSION b/VERSION
index 72e5166f076..d5de4396c40 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
-2.10.0~pre1
+2.10.0~pre2
diff --git a/configs/apps/gladevcp/complex/complex.py b/configs/apps/gladevcp/complex/complex.py
index db694758b37..98dd9a449af 100644
--- a/configs/apps/gladevcp/complex/complex.py
+++ b/configs/apps/gladevcp/complex/complex.py
@@ -124,7 +124,7 @@ def _hal_setup(self,halcomp, builder):
# standard hal pins not associated with any widget
self.halcomp.newpin("example-out", hal.Type.BOOL, hal.Dir.OUT)
- self.halcomp.newpin("example-in", hal.HAL_S32, hal.Dir.IN)
+ self.halcomp.newpin("example-in", hal.Type.SINT, hal.Dir.IN)
# hal pins with change callback. Also unrelated to any HAL widget.
# When the pin's value changes the callback is executed.
diff --git a/configs/attic/unclaimed/plasma-thc/mp1000A.hal b/configs/attic/unclaimed/plasma-thc/mp1000A.hal
index c4935bdc3a5..59e72834910 100644
--- a/configs/attic/unclaimed/plasma-thc/mp1000A.hal
+++ b/configs/attic/unclaimed/plasma-thc/mp1000A.hal
@@ -16,7 +16,7 @@ loadrt or2 count=9
loadrt scale
loadrt sum2 count=5
loadrt xor2 count=4
-loadrt conv_s32_float
+loadrt conv_sint_real
loadrt edge count=2
# Attach realtime hal components to a realtime thread
@@ -32,7 +32,7 @@ addf and2.8 servo-thread
addf comp.0 servo-thread
addf comp.1 servo-thread
addf comp.2 servo-thread
-addf conv-s32-float.0 servo-thread
+addf conv-sint-real.0 servo-thread
addf edge.0 servo-thread
addf edge.1 servo-thread
addf flipflop.0 servo-thread
@@ -178,8 +178,8 @@ net FeedHold xor2.0.out => motion.feed-hold
net CHLSwitched xor2.2.out => and2.1.in1
net ArcOKTimer oneshot.2.out => xor2.1.in0
net PierceLatch flipflop.1.out => mux2.0.sel oneshot.0.in
-net IgnitionCounterS32 updown.0.count => conv-s32-float.0.in
-net IgnitionCounterFloat conv-s32-float.0.out => comp.2.in1
+net IgnitionCounterS32 updown.0.count => conv-sint-real.0.in
+net IgnitionCounterFloat conv-sint-real.0.out => comp.2.in1
net IgnitionTimerOff oneshot.1.out-not => updown.0.countup
net TorchOff not.2.out => flipflop.1.reset
net TorchTurnedOffOrTimeout or2.7.out => or2.6.in1
diff --git a/configs/attic/unclaimed/plasma-thc/mp1000B.hal b/configs/attic/unclaimed/plasma-thc/mp1000B.hal
index a65f06ebe11..94bfbbf2a10 100644
--- a/configs/attic/unclaimed/plasma-thc/mp1000B.hal
+++ b/configs/attic/unclaimed/plasma-thc/mp1000B.hal
@@ -16,7 +16,7 @@ loadrt or2 count=9
loadrt scale
loadrt sum2 count=5
loadrt xor2 count=4
-loadrt conv_s32_float
+loadrt conv_sint_real
loadrt edge count=2
# Attach realtime hal components to a realtime thread
@@ -32,7 +32,7 @@ addf and2.8 servo-thread
addf comp.0 servo-thread
addf comp.1 servo-thread
addf comp.2 servo-thread
-addf conv-s32-float.0 servo-thread
+addf conv-sint-real.0 servo-thread
addf edge.0 servo-thread
addf edge.1 servo-thread
addf flipflop.0 servo-thread
@@ -178,8 +178,8 @@ net FeedHold xor2.0.out => motion.feed-hold
net CHLSwitched xor2.2.out => and2.1.in1
net ArcOKTimer oneshot.2.out => xor2.1.in0
net PierceLatch flipflop.1.out => mux2.0.sel oneshot.0.in
-net IgnitionCounterS32 updown.0.count => conv-s32-float.0.in
-net IgnitionCounterFloat conv-s32-float.0.out => comp.2.in1
+net IgnitionCounterS32 updown.0.count => conv-sint-real.0.in
+net IgnitionCounterFloat conv-sint-real.0.out => comp.2.in1
net IgnitionTimerOff oneshot.1.out-not => updown.0.countup
net TorchOff not.2.out => flipflop.1.reset
net TorchTurnedOffOrTimeout or2.7.out => or2.6.in1
diff --git a/configs/attic/unclaimed/plasma-thc/thc300.hal b/configs/attic/unclaimed/plasma-thc/thc300.hal
index 8a3d838e509..37950d48b61 100644
--- a/configs/attic/unclaimed/plasma-thc/thc300.hal
+++ b/configs/attic/unclaimed/plasma-thc/thc300.hal
@@ -16,7 +16,7 @@ loadrt or2 count=9
loadrt scale
loadrt sum2 count=5
loadrt xor2 count=4
-loadrt conv_s32_float
+loadrt conv_sint_real
loadrt edge count=2
# Attach realtime hal components to a realtime thread
@@ -32,7 +32,7 @@ addf and2.8 servo-thread
addf comp.0 servo-thread
addf comp.1 servo-thread
addf comp.2 servo-thread
-addf conv-s32-float.0 servo-thread
+addf conv-sint-real.0 servo-thread
addf edge.0 servo-thread
addf edge.1 servo-thread
addf flipflop.0 servo-thread
@@ -178,8 +178,8 @@ net FeedHold xor2.0.out => motion.feed-hold
net CHLSwitched xor2.2.out => and2.1.in1
net ArcOKTimer oneshot.2.out => xor2.1.in0
net PierceLatch flipflop.1.out => mux2.0.sel oneshot.0.in
-net IgnitionCounterS32 updown.0.count => conv-s32-float.0.in
-net IgnitionCounterFloat conv-s32-float.0.out => comp.2.in1
+net IgnitionCounterS32 updown.0.count => conv-sint-real.0.in
+net IgnitionCounterFloat conv-sint-real.0.out => comp.2.in1
net IgnitionTimerOff oneshot.1.out-not => updown.0.countup
net TorchOff not.2.out => flipflop.1.reset
net TorchTurnedOffOrTimeout or2.7.out => or2.6.in1
diff --git a/configs/by_interface/mesa/hm2-modbus/bldc_and_wavebox.mbccs b/configs/by_interface/mesa/hm2-modbus/bldc_and_wavebox.mbccs
index 389e7818c71..9205c6b0ed6 100644
--- a/configs/by_interface/mesa/hm2-modbus/bldc_and_wavebox.mbccs
+++ b/configs/by_interface/mesa/hm2-modbus/bldc_and_wavebox.mbccs
@@ -28,7 +28,7 @@
-
+
@@ -36,19 +36,19 @@
diff --git a/configs/by_interface/mesa/hm2-modbus/brushless-dc-motor-driver.mbccs b/configs/by_interface/mesa/hm2-modbus/brushless-dc-motor-driver.mbccs
index b5ce958b4ac..4806441b8cc 100644
--- a/configs/by_interface/mesa/hm2-modbus/brushless-dc-motor-driver.mbccs
+++ b/configs/by_interface/mesa/hm2-modbus/brushless-dc-motor-driver.mbccs
@@ -36,7 +36,7 @@
-
+
@@ -44,19 +44,19 @@
-
- Will create a HAL_U32 pin
+ Will create a HAL_UINT pin
- (in) hm2_modbus.0.watcher
The 'count' is implicit 1. The data is mapped to U_AB and is clamped.
The data is sent every time (resend=1), regardless whether the HAL pin
@@ -533,7 +539,7 @@ Recognized '/' attributes:
The HAL pin type for interactions. You do not need to specify this attribute
for the Modbus functions read/write coil(s) or inputs, `R_COILS` (`1`),
`R_INPUTS` (`2`), `W_COIL` (`5`) and `W_COILS` (`15`), as these always use
- the 'HAL_BIT' type.
+ the 'HAL_BOOL' type.
*interval* [once,0..3600000000]::
The command repeat interval in micro-seconds. This is the time between
repeating this ''. An interval shorter than the time it takes to work
@@ -564,12 +570,12 @@ Recognized '/' attributes:
*scale* [Boolean]::
Add scaling HAL pins. Modbus read functions `R_REGISTERS` (`3`) and `R_INPUTREGS` (`4`)
add extra HAL pins *pin.name.offset* (in, 64-bit 'haltype'), *pin.name.scale*
- (in, 'HAL_FLOAT') and *pin.name.scaled* (out, 'HAL_FLOAT'). +
+ (in, 'HAL_REAL') and *pin.name.scaled* (out, 'HAL_REAL'). +
The Modbus write functions `W_REGISTER` (`6`) and `W_REGISTERS` (`16`) create
extra HAL pins *pin.name.offset* (in, 64-bit 'haltype') and *pin.name.scale*
- (in, 'HAL_FLOAT'). +
- The 'scale' attribute is only supported for 'HAL_FLOAT', 'HAL_S32' and 'HAL_S64'.
- Default is true for 'HAL_FLOAT' and false for others. The *scale* pin is
+ (in, 'HAL_REAL'). +
+ The 'scale' attribute is only supported for 'HAL_REAL' and 'HAL_SINT'.
+ Default is true for 'HAL_REAL' and false for others. The *scale* pin is
initialized to one (1.0) and the *offset* pin is initialized to zero (0). +
Scaling is always multiplicative to prevent division-by-zero. The offset is
always subtracted before scaling. The scaling action performed and subject to
@@ -621,25 +627,25 @@ attributes and can be overridden by adding them to the '' tag.
-
+
----
diff --git a/docs/src/man/man1/mitsub_vfd.1.adoc b/docs/src/man/man1/mitsub_vfd.1.adoc
index efdf6fe8b40..c9d9f475e65 100644
--- a/docs/src/man/man1/mitsub_vfd.1.adoc
+++ b/docs/src/man/man1/mitsub_vfd.1.adoc
@@ -74,32 +74,32 @@ In this case pins such as up-to-speed, amps, alarm and status bits are not usefu
== PINS
-_VFD_NAME_**.fwd** (bit, in):: Forward/reverse pin
-_VFD_NAME_**.run** (bit, in):: Run/stop pin
-_VFD_NAME_**.debug** (bit, in):: Set debug mode pin.
+_VFD_NAME_**.fwd** (bool, in):: Forward/reverse pin
+_VFD_NAME_**.run** (bool, in):: Run/stop pin
+_VFD_NAME_**.debug** (bool, in):: Set debug mode pin.
This will print many messages to the terminal.
-_VFD_NAME_**.monitor** (bit, in):: Set monitor mode pin.
+_VFD_NAME_**.monitor** (bool, in):: Set monitor mode pin.
If false, request-status command will not be sent to VFD.
Status, amps, power, motor-feedback, and alarm would then not be useful.
-_VFD_NAME_**.estop** (bit, in):: Set E-stop mode pin.
+_VFD_NAME_**.estop** (bool, in):: Set E-stop mode pin.
This will stop the VFD. Restarting requires the run pin to cycle.
-_VFD_NAME_**.fwd** (bit, out):: Up-to-speed status pin. Motor is at requested speed within VFD's settings tolerance.
-_VFD_NAME_**.alarm** (bit, out):: Alarm status pin
-_VFD_NAME_**.motor-cmd** (float, in):: The requested motor speed, in Hertz (Hz)
-_VFD_NAME_**.motor-fb** (float, out):: The motor feedback speed (from VFD) in Hertz (Hz)
-_VFD_NAME_**.motor-amps** (float, out):: The motor current, in amperes (A)
-_VFD_NAME_**.motor-power** (float, out):: The motor power
-_VFD_NAME_**.scale-cmd** (float, in):: Motor command's scale setting defaults to 1
-_VFD_NAME_**.scale-cmd** (float, in):: Motor command's scale setting defaults to 1
-_VFD_NAME_**.scale-cmd** (float, in):: Motor command's scale setting defaults to 1
-_VFD_NAME_**.stat-bit-0** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-1** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-2** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-3** (bit, out):: Raw status bit. Configure the VFD so that the function 'Up to frequency' or 'motor-at-speed' is assigned to status bit 3 (parameter 191 for 700 series).
-_VFD_NAME_**.stat-bit-4** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-5** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-6** (bit, out):: Raw status bit
-_VFD_NAME_**.stat-bit-7** (bit, out):: Raw status bit. Configure the VFD so that the function 'alarm' is assigned to status bit 7 (parameter 195 for 700 series).
+_VFD_NAME_**.fwd** (bool, out):: Up-to-speed status pin. Motor is at requested speed within VFD's settings tolerance.
+_VFD_NAME_**.alarm** (bool, out):: Alarm status pin
+_VFD_NAME_**.motor-cmd** (real, in):: The requested motor speed, in Hertz (Hz)
+_VFD_NAME_**.motor-fb** (real, out):: The motor feedback speed (from VFD) in Hertz (Hz)
+_VFD_NAME_**.motor-amps** (real, out):: The motor current, in amperes (A)
+_VFD_NAME_**.motor-power** (real, out):: The motor power
+_VFD_NAME_**.scale-cmd** (real, in):: Motor command's scale setting defaults to 1
+_VFD_NAME_**.scale-cmd** (real, in):: Motor command's scale setting defaults to 1
+_VFD_NAME_**.scale-cmd** (real, in):: Motor command's scale setting defaults to 1
+_VFD_NAME_**.stat-bit-0** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-1** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-2** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-3** (bool, out):: Raw status bit. Configure the VFD so that the function 'Up to frequency' or 'motor-at-speed' is assigned to status bit 3 (parameter 191 for 700 series).
+_VFD_NAME_**.stat-bit-4** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-5** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-6** (bool, out):: Raw status bit
+_VFD_NAME_**.stat-bit-7** (bool, out):: Raw status bit. Configure the VFD so that the function 'alarm' is assigned to status bit 7 (parameter 195 for 700 series).
== SAMPLE HAL
diff --git a/docs/src/man/man1/mqtt-publisher.1.adoc b/docs/src/man/man1/mqtt-publisher.1.adoc
index 09b9af86114..a0c520fd76b 100644
--- a/docs/src/man/man1/mqtt-publisher.1.adoc
+++ b/docs/src/man/man1/mqtt-publisher.1.adoc
@@ -72,16 +72,16 @@ The loop reading HAL values and publishing MQTT messages.
== PINS
-*mqtt-publisher*.*enable* bit input::
+*mqtt-publisher*.*enable* bool input::
When TRUE, publish messages to MQTT broker.
When FALSE, do not publish messages.
Default is TRUE.
-*mqtt-publisher*.*period* u32 input::
+*mqtt-publisher*.*period* uint input::
The number of seconds to sleep between publishing MQTT messages to the broker.
Default is 10 seconds.
-*mqtt-publisher*.*lastpublish* u32 output::
+*mqtt-publisher*.*lastpublish* uint output::
When the last MQTT publication was published in number of seconds since EPOC.
If no publication has taken place, the value is zero.
diff --git a/docs/src/man/man1/mtconnect-agent.1.adoc b/docs/src/man/man1/mtconnect-agent.1.adoc
index c3ef1a5e2ff..a829832b8b9 100644
--- a/docs/src/man/man1/mtconnect-agent.1.adoc
+++ b/docs/src/man/man1/mtconnect-agent.1.adoc
@@ -95,11 +95,11 @@ Non-standard types and non-SAMPLE categories are skipped with a warning.
== HAL PINS
-*mtconnect-agent.enable* (bit, in):: Gate polling and publishing (default TRUE).
-*mtconnect-agent.sample-hz* (u32, in):: Override *SAMPLE_HZ*.
-*mtconnect-agent.active* (bit, out):: TRUE while polling and serving.
-*mtconnect-agent.connected* (bit, out):: TRUE while the MQTT broker link is up.
-*mtconnect-agent.heartbeat* (u32, out):: Increments on each poll.
+*mtconnect-agent.enable* (bool, in):: Gate polling and publishing (default TRUE).
+*mtconnect-agent.sample-hz* (uint, in):: Override *SAMPLE_HZ*.
+*mtconnect-agent.active* (bool, out):: TRUE while polling and serving.
+*mtconnect-agent.connected* (bool, out):: TRUE while the MQTT broker link is up.
+*mtconnect-agent.heartbeat* (uint, out):: Increments on each poll.
== EXTENSION SCHEMA
diff --git a/docs/src/man/man1/sendkeys.1.adoc b/docs/src/man/man1/sendkeys.1.adoc
index 2be06abcb19..8a2d5c68f47 100644
--- a/docs/src/man/man1/sendkeys.1.adoc
+++ b/docs/src/man/man1/sendkeys.1.adoc
@@ -73,22 +73,22 @@ To generate keystrokes from other sources note that a keydown is simply `0xC0 &
== PINS
-**sendkeys.**_N_**.keycode** u32 in::
+**sendkeys.**_N_**.keycode** uint in::
Connect to scancode generator.
-**sendkeys.**_N_**.current-event** s32 out::
+**sendkeys.**_N_**.current-event** sint out::
Shows the current scancode without keyup / keydown markers.
-**sendkeys.**_N_**.init** bit in::
+**sendkeys.**_N_**.init** bool in::
Set this pin TRUE once all the event parameters have been set.
== PARAMETERS
-**sendkeys.**_N_**.scan-event-_MM_** u32 in::
+**sendkeys.**_N_**.scan-event-_MM_** uint in::
Assign the uinput event codes associated with each scancode.
-**sendkeys.**_N_**.pin-event-_MM_** u32 in::
- Assign the uinput codes associated with each HAL bit pin.
+**sendkeys.**_N_**.pin-event-_MM_** uint in::
+ Assign the uinput codes associated with each HAL bool pin.
== EXAMPLE
diff --git a/docs/src/man/man1/shuttle.1.adoc b/docs/src/man/man1/shuttle.1.adoc
index e9e55240409..52476129cbb 100644
--- a/docs/src/man/man1/shuttle.1.adoc
+++ b/docs/src/man/man1/shuttle.1.adoc
@@ -62,16 +62,16 @@ So if you (for example) push one of the buttons at startup, the jog-wheel will w
All HAL pin names are prefixed with `shuttle` followed by the index of the device
(the order in which the driver found them), for example `shuttle.0` or `huttle.2`.
-_(prefix).button-(number)_ (bit out)::
-_(prefix).button-(number)-not_ (bit out)::
+_(prefix).button-(number)_ (bool out)::
+_(prefix).button-(number)-not_ (bool out)::
The momentary buttons. "(number)" identifies which button corresponds to the HAL pin.
The "button-(number)" pins are True when the button is pushed, the "button-(number)-not" pins are True when the button is not pushed.
-_(prefix).counts_ (s32 out)::
+_(prefix).counts_ (sint out)::
Accumulated counts from the jog wheel (the inner wheel).
-_(prefix).spring-wheel-s32_ (s32 out)::
+_(prefix).spring-wheel-s32_ (sint out)::
The current deflection of the spring-wheel (the outer wheel).
It's 0 at rest, and ranges from -7 at the counter-clockwise extreme to +7 at the clockwise extreme.
-_(prefix).spring-wheel-f_ (float out)::
+_(prefix).spring-wheel-f_ (real out)::
The current deflection of the spring-wheel (the outer wheel).
It's 0.0 at rest, -1.0 at the counter-clockwise extreme, and +1.0 at the clockwise extreme.
(The Shuttle devices report the spring-wheel position as an integer from -7 to +7, so this pin reports only 15 discrete values in its range.)
diff --git a/docs/src/man/man1/sim-torch.1.adoc b/docs/src/man/man1/sim-torch.1.adoc
index 6e8a9e31aad..d8907fd5534 100644
--- a/docs/src/man/man1/sim-torch.1.adoc
+++ b/docs/src/man/man1/sim-torch.1.adoc
@@ -17,27 +17,26 @@ _VERSION:_ +
== PINS
-*sim-torch-rt.cut-noise-in* float in (default: _0.75_)::
+*sim-torch-rt.cut-noise-in* real in (default: _0.75_)::
the maximum amount of noise during cutting (volts)
-*sim-torch-rt.cycles-in* s32 in::
+*sim-torch-rt.cycles-in* sint in (default: _200_)::
the number of cycles that the arc voltage overshoots the cut voltage (cycles)
- (default: _200_)
-*sim-torch-rt.on-delay-in* s32 in::
+*sim-torch-rt.on-delay-in* sint in (default: _10_)::
the time from turn on until overshoot begins (cycles)
- (default: _10_)
-*sim-torch-rt.offset-in* float in::
+*sim-torch-rt.offset-in* real in::
the cut voltage offset(volts)
-*sim-torch-rt.overshoot-in* s32 in::
+*sim-torch-rt.overshoot-in* sint in (default: _50_)::
the percentage of the cut voltage that the arc voltage overshoots (percent)
- (default: _50_)
-*sim-torch-rt.ramp-noise-in* float in (default: _5_)::
+*sim-torch-rt.ramp-noise-in* real in (default: _5_)::
the maximum amount of noise during overshoot (volts)
-*sim-torch-rt.ramp-up-in* s32 in (default: _80_)::
+*sim-torch-rt.ramp-up-in* sint in (default: _80_)::
percent of 'cycles_in' that the arc voltage ramps up (percent)
-*sim-torch-rt.start* bit in:: start the arc
-*sim-torch-rt.voltage-in* float in:: the cut voltage (volts)
- (default: _100_)
-*sim-torch-rt.voltage-out* float out:: output voltage (volts)
+*sim-torch-rt.start* bool in::
+ start the arc
+*sim-torch-rt.voltage-in* real in (default: _100_)::
+ the cut voltage (volts)
+*sim-torch-rt.voltage-out* real out::
+ output voltage (volts)
== AUTHOR
diff --git a/docs/src/man/man1/sim_pin.1.adoc b/docs/src/man/man1/sim_pin.1.adoc
index 61a5697e1ca..1d80d5363e8 100644
--- a/docs/src/man/man1/sim_pin.1.adoc
+++ b/docs/src/man/man1/sim_pin.1.adoc
@@ -13,13 +13,13 @@ _Options_:
- *--help* (shows help text)
- *--title* _title_string_
-For bit items, the name may include a /mode= specifier:
+For bool items, the name may include a /mode= specifier:
_namei_/*mode=*[*pulse* | *toggle* | *hold*] (default is toggle)
== DESCRIPTION
-HAL boolean items (bit) and numerical items (u32, s32, float) are
+HAL boolean items (bool) and numerical items (uint, sint, real) are
supported.
If the named input is a numerical type, the GUI displays:
@@ -28,14 +28,14 @@ If the named input is a numerical type, the GUI displays:
*Set*:: Pushbutton to set new value from Entry (or use ).
*Reset*:: Pushbutton to reset to the value present on initiation.
-If the input is a *bit* type, the GUI shows a single pushbutton that is
+If the input is a *bool* type, the GUI shows a single pushbutton that is
controlled by radio-button selectors:
- mode=**pulse** Pulse input to 1 for each pushbutton press. +
- mode=**toggle** Toggle input for each pushbutton press. +
- mode=**hold** Set input to 1 while pushbutton pressed.
-If the bit item mode begins with an uppercase letter, the radio buttons
+If the bool item mode begins with an uppercase letter, the radio buttons
for selecting other modes are not shown
== NOTES
diff --git a/docs/src/man/man1/svd-ps_vfd.1.adoc b/docs/src/man/man1/svd-ps_vfd.1.adoc
index b28b15d25fc..45ec4629549 100644
--- a/docs/src/man/man1/svd-ps_vfd.1.adoc
+++ b/docs/src/man/man1/svd-ps_vfd.1.adoc
@@ -73,54 +73,54 @@ PD-06 = 0 (Current resolution)
== PINS
-*svd-ps_vfd.period* (float, in)::
+*svd-ps_vfd.period* (real, in)::
The period for the driver's update cycle, in seconds.
This is how frequently the driver will wake up, check its HAL pins, and communicate with the VFD.
Must be between 0.001 and 2.000 seconds.
Default: 0.1 seconds.
-*svd-ps_vfd.speed-cmd* (float, in)::
+*svd-ps_vfd.speed-cmd* (real, in)::
The requested motor speed, in RPM.
-*svd-ps_vfd.speed-fb* (float, out)::
+*svd-ps_vfd.speed-fb* (real, out)::
The motor's current speed, in RPM, reported by the VFD.
-*svd-ps_vfd.at-speed* (bit, out)::
+*svd-ps_vfd.at-speed* (bool, out)::
True when the drive is on and at the commanded speed (within 2%),
False otherwise.
-*svd-ps_vfd.freq-cmd* (float, out)::
+*svd-ps_vfd.freq-cmd* (real, out)::
The requested output frequency, in Hz.
This is set from the `.speed-cmd` value, and is just shown for debugging purposes.
-*svd-ps_vfd.freq-fb* (float, out)::
+*svd-ps_vfd.freq-fb* (real, out)::
The current output frequency of the VFD, in Hz. This is reported from the VFD to the driver.
-*svd-ps_vfd.spindle-on* (bit, in)::
+*svd-ps_vfd.spindle-on* (bool, in)::
Set this pin True to command the spindle on, at the speed requested on the `.speed-cmd` pin.
Set this pin False to command the spindle off.
-*svd-ps_vfd.output-voltage* (float, out)::
+*svd-ps_vfd.output-voltage* (real, out)::
The voltage that the VFD is current providing to the motor, in Volts.
-*svd-ps_vfd.output-current* (float, out)::
+*svd-ps_vfd.output-current* (real, out)::
The current that the motor is currently drawing from the VFD, in Amperes.
-*hsvd-ps_vfd.output-power* (float, out)::
+*hsvd-ps_vfd.output-power* (real, out)::
The power that the motor is currently drawing from the VFD, in Watts.
-*svd-ps_vfd.dc-bus-voltage* (float, out)::
+*svd-ps_vfd.dc-bus-voltage* (real, out)::
The current voltage of the VFD's internal DC power supply, in Volts.
-*svd-ps_vfd.modbus-errors* (u32, out)::
+*svd-ps_vfd.modbus-errors* (uint, out)::
A count of the number of modbus communication errors between the driver and the VFD.
The driver is resilient against communication errors, but a large or growing number here indicates a problem that should be investigated.
-*svd-ps_vfd.input-terminal* (float, out):: The VFD's input terminal register.
+*svd-ps_vfd.input-terminal* (real, out):: The VFD's input terminal register.
-*svd-ps_vfd.AI1* (float, out):: The VFD's AI1 register.
+*svd-ps_vfd.AI1* (real, out):: The VFD's AI1 register.
-*svd-ps_vfd.AI2* (float, out):: The VFD's AI2 register.
+*svd-ps_vfd.AI2* (real, out):: The VFD's AI2 register.
== AUTHOR
diff --git a/docs/src/man/man1/vfdb_vfd.1.adoc b/docs/src/man/man1/vfdb_vfd.1.adoc
index eb82e07aafb..64d227bcb13 100644
--- a/docs/src/man/man1/vfdb_vfd.1.adoc
+++ b/docs/src/man/man1/vfdb_vfd.1.adoc
@@ -95,93 +95,93 @@ MOTOR_HZ, MOTOR_RPM::
== PINS
-.at-speed (bit, out)::
+.at-speed (bool, out)::
True when drive is at commanded speed (see _speed-tolerance_ below)
-.enable (bit, in)::
+.enable (bool, in)::
Enable the VFD. If False, all operating parameters are still read but control is released and panel control is enabled (subject to VFD setup).
-.frequency-command (float, out)::
+.frequency-command (real, out)::
Current target frequency in HZ as set through speed-command (which is in RPM), from the VFD.
-.frequency-out (float, out)::
+.frequency-out (real, out)::
Current output frequency of the VFD.
-.inverter-load-percentage (float, out)::
+.inverter-load-percentage (real, out)::
Current load report from VFD.
-.is-e-stopped (bit, out)::
+.is-e-stopped (bool, out)::
The VFD is in emergency stop status (blinking "E" on panel).
-.is-stopped (bit, out)::
+.is-stopped (bool, out)::
True when the VFD reports 0 Hz output.
-.jog-mode (bit, in)::
+.jog-mode (bool, in)::
1 for ON and 0 for OFF, enables the VFD-B 'jog mode'.
Speed control is disabled. This might be useful for spindle orientation.
-.max-rpm (float, out)::
+.max-rpm (real, out)::
Actual RPM limit based on maximum frequency the VFD may generate, and the motors nameplate values.
For instance, if _nameplate-HZ_ is 50, and _nameplate-RPM_ is 1410, but the VFD may generate up to 80Hz, then _max-rpm_ would read as 2256 (80*1410/50).
The frequency limit is read from the VFD at startup.
To increase the upper frequency limit, the UL and FH parameters must be changed on the panel.
See the VFD-B manual for instructions how to set the maximum frequency.
-.modbus-ok (bit, out)::
+.modbus-ok (bool, out)::
True when the Modbus session is successfully established and the last 10 transactions returned without error.
-.motor-RPM (float, out)::
+.motor-RPM (real, out)::
Estimated current RPM value, from the VFD.
-.motor-RPS (float, out)::
+.motor-RPS (real, out)::
Estimated current RPS value, from the VFD.
-.output-voltage (float, out)::
+.output-voltage (real, out)::
From the VFD.
-.output-current (float, out)::
+.output-current (real, out)::
From the VFD.
-.speed-command (float, in)::
+.speed-command (real, in)::
Speed sent to VFD in RPM. It is an error to send a speed faster than
the Motor Max RPM as set in the VFD.
-.spindle-on (bit, in)::
+.spindle-on (bool, in)::
1 for ON and 0 for OFF sent to VFD, only on when running.
-.max-speed (bit, in)::
+.max-speed (bool, in)::
Ignore the loop-time parameter and run Modbus at maximum speed, at the
expense of higher CPU usage. Suggested use during spindle positioning.
-.status (s32, out)::
+.status (sint, out)::
Drive Status of the VFD (see the VFD manual). A bitmap.
-.error-count (s32, out)::
+.error-count (sint, out)::
Total number of transactions returning a Modbus error.
-.error-code (s32, out)::
+.error-code (sint, out)::
Most recent Error Code from VFD.
-.frequency-limit (float, out)::
+.frequency-limit (real, out)::
Upper limit read from VFD setup.
== PARAMETERS
-.loop-time (float, RW)::
+.loop-time (real, RW)::
How often the Modbus is polled (default interval 0.1 seconds).
-.nameplate-HZ (float, RW)::
+.nameplate-HZ (real, RW)::
Nameplate Hz of motor (default 50). Used to calculate target frequency
(together with _nameplate-RPM_ ) for a target RPM value as given by
speed-command.
-.nameplate-RPM (float, RW)::
+.nameplate-RPM (real, RW)::
Nameplate RPM of motor (default 1410)
-.rpm-limit (float, RW)::
+.rpm-limit (real, RW)::
Do-not-exceed soft limit for motor RPM (defaults to _nameplate-RPM_ ).
-.tolerance (float, RW)::
+.tolerance (real, RW)::
Speed tolerance (default 0.01) for determining whether spindle is at speed (0.01 meaning: output frequency is within 1% of target frequency).
== USAGE
diff --git a/docs/src/man/man1/vfs11_vfd.1.adoc b/docs/src/man/man1/vfs11_vfd.1.adoc
index 7590fb0f5b9..57cdda7e1cd 100644
--- a/docs/src/man/man1/vfs11_vfd.1.adoc
+++ b/docs/src/man/man1/vfs11_vfd.1.adoc
@@ -39,123 +39,123 @@ This component reads and writes to the vfs11 via a Modbus connection.
== PINS
-.acceleration-pattern (bit, in)::
+.acceleration-pattern (bool, in)::
when true, set acceleration and deceleration times as defined in registers F500 and F501 respectively.
Used in PID loops to choose shorter ramp times to avoid oscillation.
-.alarm-code (s32, out)::
+.alarm-code (sint, out)::
non-zero if drive is in alarmed state.
Bitmap describing alarm information (see register FC91 description).
Use _err-reset_ (see below) to clear the alarm.
-.at-speed (bit, out)::
+.at-speed (bool, out)::
when drive is at commanded speed (see _speed-tolerance_ below)
-.current-load-percentage (float, out)::
+.current-load-percentage (real, out)::
Reported from the VFD.
-.dc-brake (bit, in)::
+.dc-brake (bool, in)::
Engage the DC brake. Also turns off spindle-on.
-.enable (bit, in)::
+.enable (bool, in)::
Enable the VFD. If false, all operating parameters are still read but
control is released and panel control is enabled (subject to VFD setup).
-.err-reset (bit, in)::
+.err-reset (bool, in)::
Reset errors (alarms a.k.a Trip and e-stop status).
Resetting the VFD may cause a 2-second delay until it's rebooted and Modbus is up again.
-.estop (bit, in)::
+.estop (bool, in)::
Put the VFD into emergency-stopped status.
No operation possible until cleared with _err-reset_ or powercycling.
-.frequency-command (float, out)::
+.frequency-command (real, out)::
Current target frequency in Hz as set through speed-command (which is in RPM), from the VFD.
-.frequency-out (float, out)::
+.frequency-out (real, out)::
Current output frequency of the VFD.
-.inverter-load-percentage (float, out)::
+.inverter-load-percentage (real, out)::
Current load report from VFD.
-.is-e-stopped (bit, out)::
+.is-e-stopped (bool, out)::
The VFD is in emergency stop status (blinking "E" on panel).
Use _err-reset_ to reboot the VFD and clear the e-stop status.
-.is-stopped (bit, out)::
+.is-stopped (bool, out)::
True when the VFD reports 0 Hz output
-.jog-mode (bit, in)::
+.jog-mode (bool, in)::
1 for ON and 0 for OFF, enables the VF-S11 'jog mode'.
Speed control is disabled, and the output frequency is determined by register F262 (preset to 5 Hz).
This might be useful for spindle orientation.
-.max-rpm (float, R)::
+.max-rpm (real, R)::
Actual RPM limit based on maximum frequency the VFD may generate, and the motors nameplate values.
For instance, if _nameplate-HZ_ is 50, and _nameplate-RPM__ is 1410, but the VFD may generate up to 80Hz, then _max-rpm_ would read as 2256 (80*1410/50).
The frequency limit is read from the VFD at startup.
To increase the upper frequency limit, the UL and FH parameters must be changed on the panel.
See the VF-S11 manual for instructions how to set the maximum frequency.
-.modbus-ok (bit, out)::
+.modbus-ok (bool, out)::
True when the Modbus session is successfully established and the last 10 transactions returned without error.
-.motor-RPM (float, out)::
+.motor-RPM (real, out)::
Estimated current RPM value, from the VFD.
-.output-current-percentage (float, out)::
+.output-current-percentage (real, out)::
from the VFD
-.output-voltage-percentage (float, out)::
+.output-voltage-percentage (real, out)::
from the VFD
-.output-voltage (float, out)::
+.output-voltage (real, out)::
from the VFD
-.speed-command (float, in)::
+.speed-command (real, in)::
Speed sent to VFD in RPM. It is an error to send a speed faster than the Motor Max RPM as set in the VFD.
-.spindle-fwd (bit, in)::
+.spindle-fwd (bool, in)::
1 for FWD and 0 for REV, sent to VFD.
-.spindle-on (bit, in)::
+.spindle-on (bool, in)::
1 for ON and 0 for OFF sent to VFD, only on when running.
-.spindle-rev (bit, in)::
+.spindle-rev (bool, in)::
1 for ON and 0 for OFF, only on when running.
-.max-speed (bit, in)::
+.max-speed (bool, in)::
Ignore the loop-time parameter and run Modbus at maximum speed, at the expense of higher CPU usage.
Suggested use during spindle positioning.
-.status (s32, out)::
+.status (sint, out)::
Drive Status of the VFD (see the TOSVERT VF-S11 Communications Function Instruction Manual, register FD01). A bitmap.
-.trip-code (s32, out)::
+.trip-code (sint, out)::
Trip code if VF-S11 is in tripped state.
-.error-count (s32, RW)::
+.error-count (sint, RW)::
Total number of transactions returning a Modbus error.
== PARAMETERS
-.frequency-limit (float, RO)::
+.frequency-limit (real, RO)::
Upper limit read from VFD setup.
-.loop-time (float, RW)::
+.loop-time (real, RW)::
How often the Modbus is polled (default interval 0.1 seconds)
-.nameplate-HZ (float, RW)::
+.nameplate-HZ (real, RW)::
Nameplate Hz of motor (default 50).
Used to calculate target frequency (together with __nameplate-RPM__) for a target RPM value as given by speed-command.
-.nameplate-RPM (float, RW)::
+.nameplate-RPM (real, RW)::
Nameplate RPM of motor (default 1410)
-.rpm-limit (float, RW)::
+.rpm-limit (real, RW)::
Do-not-exceed soft limit for motor RPM (defaults to __nameplate-RPM__).
-.tolerance (float, RW)::
+.tolerance (real, RW)::
Speed tolerance (default 0.01) for determining whether spindle is at speed (0.01 meaning: output frequency is within 1% of target frequency).
== USAGE
diff --git a/docs/src/man/man1/xhc-hb04.1.adoc b/docs/src/man/man1/xhc-hb04.1.adoc
index 86cb4815824..99413a82037 100644
--- a/docs/src/man/man1/xhc-hb04.1.adoc
+++ b/docs/src/man/man1/xhc-hb04.1.adoc
@@ -110,130 +110,130 @@ Example: `loadusr -W xhc-hb04-H -I` _path_to_cfg_file_ `-s 2`
== Input Pins (Control)
-xhc-hb04.stepsize-up (bit in)::
+xhc-hb04.stepsize-up (bool in)::
A 1 pulse on this pin changes the stepsize to the next higher stepsize
in the stepsize sequence specified in the xhc-hb04 (loadusr) command.
-xhc-hb04.stepsize-down (bit in)::
+xhc-hb04.stepsize-down (bool in)::
A 1 pulse on this pin changes the stepsize to the next lower stepsize
in the stepsize sequence specified in the xhc-hb04 (loadusr) command.
== Input Pins (to the pendant LCD display)
-xhc-hb04.[xyza].pos-absolute (float in)::
+xhc-hb04.[xyza].pos-absolute (real in)::
Absolute position display. The LCD display for pos-absolute is fixed
format with a sign, 4 number digits and 3 fraction digits (+XXXX.XXX),
require: -9999.999 \<= value \<= 9999.999
(typically connect to: `halui.axis.N.pos-feedback`).
-xhc-hb04.[xyza].pos-relative (float in)::
+xhc-hb04.[xyza].pos-relative (real in)::
Relative position display (typically connect to:
halui.axis.N.pos-relative). The LCD display for pos-relative is fixed
format with a sign, 4 number digits and 3 fraction digits (+XXXX.XXX),
require: -9999.999 \<= value \<= 9999.999.
-xhc-hb04.feed-override (float in)::
- Feed-override value. The float value is converted to a 16 bit integer
+xhc-hb04.feed-override (real in)::
+ Feed-override value. The real value is converted to a 16 bit integer
and multiplied by 100 in order to display as percent, require: 0 \<=
pinvalue \<= 655 (typically connect to: `halui.feed-override.value`).
-xhc-hb04.feed-value (float in)::
- Current Feed-value (units/sec). The float value is converted to a 16
+xhc-hb04.feed-value (real in)::
+ Current Feed-value (units/sec). The real value is converted to a 16
bit integer and multiplied by 60 in order to display as
units-per-minute, require: 0 \<= pinvalue \<= 1092 (65520 units-per-minute)
(typically connect to: `motion.current-vel`).
-xhc-hb04.spindle-override (float in)::
- Spindle-override value. The float value is converted to a 16 bit
+xhc-hb04.spindle-override (real in)::
+ Spindle-override value. The real value is converted to a 16 bit
integer and multiplied by 100 in order to display as percent, require:
0 \<= pinvalue \<= 655) (typically connect to: `halui.spindle-override.value`).
-xhc-hb04.spindle-rps (float in)::
+xhc-hb04.spindle-rps (real in)::
Spindle speed in RPS (revolutions per second).
- The float value is converted to a 16 bit integer and multiplied by 60
+ The real value is converted to a 16 bit integer and multiplied by 60
in order to display as RPMs, require: 0 \<= pinvalue \<= 1092 (65520 RPM)
(typically connect to: `spindle.N.speed-out-rps-abs`).
-xhc-hb04.inch-icon (bit in)::
+xhc-hb04.inch-icon (bool in)::
Use inch icon (default is mm):
== Output Pins (Status)
-xhc-hb04.sleeping (bit out)::
+xhc-hb04.sleeping (bool out)::
True when the driver receives a pendant inactive (sleeping) message.
-xhc-hb04.jog.enable-off (bit out)::
+xhc-hb04.jog.enable-off (bool out)::
True when the pendant rotary selector switch is in the OFF position or
when the pendant is sleeping.
-xhc-hb04.enable-[xyza] (bit out)::
+xhc-hb04.enable-[xyza] (bool out)::
True when the pendant rotary selector switch is in the [xyza] position
and not sleeping.
-xhc-hb04.enable-spindle-override (bit out)::
+xhc-hb04.enable-spindle-override (bool out)::
True when the pendant rotary selector switch is in the Spindle
position and not sleeping (typically connect to:
halui.spindle-override-count-enable).
-xhc-hb04.enable-feed-override (bit out)::
+xhc-hb04.enable-feed-override (bool out)::
True when the pendant rotary selector switch is in the feed position
and not sleeping (typically connect to:
halui.feed-override-count-enable).
-xhc-hb04.connected (bit out)::
+xhc-hb04.connected (bool out)::
True when connection to the pendant is established over the USB
interface.
-xhc-hb04.require_pendant (bit out)::
+xhc-hb04.require_pendant (bool out)::
True if driver started with the -x option.
-xhc-hb04.stepsize (s32 out)::
+xhc-hb04.stepsize (sint out)::
Current stepsize in the stepsize sequence as controlled by the
stepsize-up and/or stepsize-down pins.
== Output Pins (for jogging using axis.N.jog-counts)
-xhc-hb04.jog.counts (s32 out)::
+xhc-hb04.jog.counts (sint out)::
Number of counts of the wheel since start-up (50 counts per wheel revolution)
(typically connect to `axis.N.jog-counts` (lowpass filtering may be helpful)).
-xhc-hb04.jog.counts-neg (s32 out)::
+xhc-hb04.jog.counts-neg (sint out)::
The value of the `xhc-hb04.jog.counts` multiplied by -1.
-xhc-hb04.jog.scale (float out)::
+xhc-hb04.jog.scale (real out)::
Value is the current stepsize multiplied by 0.001 (typically connect to `axis.N.jog-scale`).
== Experimental: Pins for halui plus/minus jogging.
These pins provide some support for non-trivkins, world mode jogging.
-xhc-hb04.jog.max-velocity (float in)::
+xhc-hb04.jog.max-velocity (real in)::
Connect to halui.max-velocity.value.
-xhc-hb04.jog.velocity (float out)::
+xhc-hb04.jog.velocity (real out)::
Connect to halui.jog-speed.
-xhc-hb04.jog.plus-[xyza] (bit out)::
+xhc-hb04.jog.plus-[xyza] (bool out)::
Connect to halui.jog.N.plus.
-xhc-hb04.jog.minus-[xyza] (bit out)::
+xhc-hb04.jog.minus-[xyza] (bool out)::
Connect to halui.jog.N.minus.
-xhc-hb04.jog.increment (float out)::
+xhc-hb04.jog.increment (real out)::
Debug pin -- abs(delta_pos).
== Button output pins (for the 18 button, layout2 pendant)
-The output bit type pins are TRUE when the button is pressed.
+The output bool type pins are TRUE when the button is pressed.
....
ROW 1
- (bit out) xhc-hb04.button-reset
- (bit out) xhc-hb04.button-stop
+ (bool out) xhc-hb04.button-reset
+ (bool out) xhc-hb04.button-stop
ROW 2
- (bit out) xhc-hb04.button-goto-zero
- (bit out) xhc-hb04.button-rewind
- (bit out) xhc-hb04.button-start-pause
- (bit out) xhc-hb04.button-probe-z
+ (bool out) xhc-hb04.button-goto-zero
+ (bool out) xhc-hb04.button-rewind
+ (bool out) xhc-hb04.button-start-pause
+ (bool out) xhc-hb04.button-probe-z
ROW 3
- (bit out) xhc-hb04.button-spindle
- (bit out) xhc-hb04.button-half
- (bit out) xhc-hb04.button-zero
- (bit out) xhc-hb04.button-safe-z
+ (bool out) xhc-hb04.button-spindle
+ (bool out) xhc-hb04.button-half
+ (bool out) xhc-hb04.button-zero
+ (bool out) xhc-hb04.button-safe-z
ROW 4
- (bit out) xhc-hb04.button-home
- (bit out) xhc-hb04.button-macro-1
- (bit out) xhc-hb04.button-macro-2
- (bit out) xhc-hb04.button-macro-3
+ (bool out) xhc-hb04.button-home
+ (bool out) xhc-hb04.button-macro-1
+ (bool out) xhc-hb04.button-macro-2
+ (bool out) xhc-hb04.button-macro-3
ROW 5
- (bit out) xhc-hb04.button-step
- (bit out) xhc-hb04.button-mode
- (bit out) xhc-hb04.button-macro-6
- (bit out) xhc-hb04.button-macro-7
+ (bool out) xhc-hb04.button-step
+ (bool out) xhc-hb04.button-mode
+ (bool out) xhc-hb04.button-macro-6
+ (bool out) xhc-hb04.button-macro-7
....
== Synthesized button pins
@@ -241,9 +241,9 @@ ROW 5
Additional buttons are synthesized for buttons named *zero*, *goto-zero*, and *half*. These synthesized buttons are active when the button is pressed AND the selector-switch is set to the corresponding axis [xyza].
....
- (bit out) xhc-hb04.button-zero-[xyza]
- (bit out) xhc-hb04.button-goto-zero-[xyza]
- (bit out) xhc-hb04.button-half-[xyza]
+ (bool out) xhc-hb04.button-zero-[xyza]
+ (bool out) xhc-hb04.button-goto-zero-[xyza]
+ (bool out) xhc-hb04.button-half-[xyza]
....
== DEBUGGING
diff --git a/docs/src/man/man1/xhc-whb04b-6.1.adoc b/docs/src/man/man1/xhc-whb04b-6.1.adoc
index e2beade376f..6ead157c1ed 100644
--- a/docs/src/man/man1/xhc-whb04b-6.1.adoc
+++ b/docs/src/man/man1/xhc-whb04b-6.1.adoc
@@ -116,34 +116,34 @@ Signals utilized for moving axis.
__ ... denotes the axis number, which is of {x, y, z, a, b, c}.
-`whb.halui.home-all` (bit,out)::
+`whb.halui.home-all` (bool, out)::
connect to `halui.home-all`, driven by M-Home.
Pin for requesting all axis to home. See also `whb.button.m-home`.
-`whb.halui.axis.__.select` (bit,out)::
+`whb.halui.axis.__.select` (bool, out)::
connect to `halui.axis.__.select`. Pin to select axis.
-`whb.axis.__.jog-counts` (s32,out)::
+`whb.axis.__.jog-counts` (sint, out)::
connect to `axis.__.jog-counts`. The count pin of the jogwheel.
-`whb.axis.__.jog-enable` (bit,out)::
+`whb.axis.__.jog-enable` (bool, out)::
connect to `axis.__.jog-enable`.
If true (and in manual mode), any change to "jog-counts" will result in motion.
If false, "jog-counts" is ignored.
-`whb.axis.__.jog-scale` (float,out)::
+`whb.axis.__.jog-scale` (real, out)::
connect to `axis.`____`.jog-scale`.
The distance to move for each count on "jog-counts", in machine units.
-`whb.axis.__.jog-vel-mode` (bit,out)::
+`whb.axis.__.jog-vel-mode` (bool, out)::
connect to `axis.`____`.jog-jog-vel-mode`.
If false the jogwheel operates in position mode.
The axis will move exactly jog-scale units for each count, regardless of how long that might take.
If true, the jogwheel operates in velocity mode - motion stops when the wheel stops, even if that means the commanded motion is not completed.
-`whb.halui.max-velocity.value` (float,in)::
+`whb.halui.max-velocity.value` (real, in)::
connect to `halui.max-velocity.value`.
The maximum allowable velocity, in units per second (__ is two digit '0'-padded).
-`whb.halui.feed-override.scale` (float,in)::
+`whb.halui.feed-override.scale` (real, in)::
connect to `halui.feed-override.scale`. The scaling for feed override value.
-`whb.halui.axis.`____`.pos-feedback` (float,in)::
+`whb.halui.axis.`____`.pos-feedback` (real, in)::
connect to `halui.axis.`____`.pos-feedback`.
Feedback axis position in machine coordinates to be displayed.
-`whb.halui.axis.__.pos-relative` (float,in)::
+`whb.halui.axis.__.pos-relative` (real, in)::
connect to `halui.axis.`____`.pos-relative`.
Commanded axis position in relative coordinates to be displayed.
@@ -151,40 +151,40 @@ __ ... denotes the axis number, which is of {x, y, z, a, b, c}.
Signals utilized for toggling machine status.
-`whb.halui.machine.on` (bit,out)::
+`whb.halui.machine.on` (bool, out)::
Connect to `halui.machine.on`. Pin for requesting machine on.
-`whb.halui.machine.is-on` (bit,in)::
+`whb.halui.machine.is-on` (bool, in)::
Connect to `halui.machine.is-on`. Pin that indicates machine is on.
-`whb.halui.machine.off` (bit,out)::
+`whb.halui.machine.off` (bool, out)::
Connect to `halui.machine.off`. Pin for requesting machine off.
==== Spindle
.Signals utilized for operating a spindle.
-`whb.halui.spindle.start` (bit,out)::
+`whb.halui.spindle.start` (bool, out)::
Connect to `halui.spindle.0.start`. Pin to start the spindle.
-`whb.halui.spindle.is-on` (bit,in)::
+`whb.halui.spindle.is-on` (bool, in)::
Connect to `halui.spindle.0.on`. Pin to indicate spindle is on (either direction).
-`whb.halui.spindle.stop` (bit,out)::
+`whb.halui.spindle.stop` (bool, out)::
Connect to `halui.spindle.0.stop`. Pin to stop the spindle.
-`whb.halui.spindle.forward` (bit,out)::
+`whb.halui.spindle.forward` (bool, out)::
Connect to `halui.spindle.0.forward`. Pin to make the spindle go forward.
-`whb.halui.spindle.reverse` (bit,out)::
+`whb.halui.spindle.reverse` (bool, out)::
Connect to `halui.spindle.0.reverse`. Pin to make the spindle go reverse.
-`whb.halui.spindle.decrease` (bit,out)::
+`whb.halui.spindle.decrease` (bool, out)::
Connect to `halui.spindle.0.decrease`. Pin to decrease the spindle speed.
-`whb.halui.spindle.increase` (bit,out)::
+`whb.halui.spindle.increase` (bool, out)::
Connect to `halui.spindle.0.increase`. Pin to increase the spindle speed.
-`whb.halui.spindle-override.increase` (bit,out)::
+`whb.halui.spindle-override.increase` (bool, out)::
Connect to `halui.spindle.0.override.increase`.
Pin for increasing the spindle override by the amount of scale.
-`whb.halui.spindle-override.decrease` (bit,out)::
+`whb.halui.spindle-override.decrease` (bool, out)::
Connect to `halui.spindle.0.override.decrease`.
Pin for decreasing the spindle override by the amount of scale.
-`whb.halui.spindle-override.value` (float,in)::
+`whb.halui.spindle-override.value` (real, in)::
Connect to `halui.spindle.0.override.value`.
The current spindle override value.
-`whb.halui.spindle-override.scale` (float,in)::
+`whb.halui.spindle-override.scale` (real, in)::
Connect to `halui.spindle.0.override.scale`.
The current spindle scaling override value.
@@ -208,54 +208,54 @@ As a consequence of 3 modes from manufacturer, switching the feed rotary button
Depending on the mode before turning the rotary button, the feed override results in different values.
In MPG/CON the feed rate will change to 100%, 60%, ... and so forth. In Step mode the feed rate is specified in mm.
-`whb.halui.feed-override.value` (float,in)::
+`whb.halui.feed-override.value` (real, in)::
Connect to `halui.feed-override.value`. The current feed override value.
-`whb.halui.feed-override.decrease` (bit,out)::
+`whb.halui.feed-override.decrease` (bool, out)::
Connect to `halui.feed-override.decrease`. Pin for decreasing the feed override by amount of scale.
-`whb.halui.feed-override.increase` (bit,out)::
+`whb.halui.feed-override.increase` (bool, out)::
Connect to `halui.feed-override.increase`. Pin for increasing the feed override by amount of scale.
-`whb.halui.feed-override.scale` (float,out)::
+`whb.halui.feed-override.scale` (real, out)::
Connect to `halui.feed-override.scale`. Pin for setting the scale on changing the feed override.
-`whb.halui.max-velocity.value` (float,out)::
+`whb.halui.max-velocity.value` (real, out)::
Connect to `halui.max-velocity.value`.
==== Program
Signals for operating program and MDI mode.
-`whb.halui.program.run` (bit,out)::
+`whb.halui.program.run` (bool, out)::
Connect to `halui.program.run` in for running a program.
-`whb.halui.program.is-running` (bit,in)::
+`whb.halui.program.is-running` (bool, in)::
Connect to `halui.program.is-running` in indicating a program is running.
-`whb.halui.program.pause` (bit,out)::
+`whb.halui.program.pause` (bool, out)::
Connect to `halui.program.pause`. Pin for pausing a program.
-`whb.halui.program.is-paused` (bit,in)::
+`whb.halui.program.is-paused` (bool, in)::
Connect to `halui.program.is-paused`. Pin indicating a program is pausing.
-`whb.halui.program.resume` (bit,out)::
+`whb.halui.program.resume` (bool, out)::
Connect to `halui.program.resume`. Pin for resuming a program.
-`whb.halui.program.stop` (bit,out)::
+`whb.halui.program.stop` (bool, out)::
Connect to `program.stop`. Pin for stopping a program.
-`whb.halui.program.is-idle` (bit,in)::
+`whb.halui.program.is-idle` (bool, in)::
Connect to `halui.program.is-idle`. Pin indicating no program is running.
-`whb.halui.mode.auto` (bit,out)::
+`whb.halui.mode.auto` (bool, out)::
Connect to `halui.mode.auto`. Pin for requesting auto mode.
-`whb.halui.mode.is-auto` (bit,in)::
+`whb.halui.mode.is-auto` (bool, in)::
Connect to `halui.mode.is-auto`. Pin for indicating auto mode is on.
-`whb.halui.mode.joint` (bit,out)::
+`whb.halui.mode.joint` (bool, out)::
Connect to `halui.mode.joint` Pin for requesting joint by joint mode.
-`whb.halui.mode.is-joint` (bit,in)::
+`whb.halui.mode.is-joint` (bool, in)::
Connect to `halui.mode.is-joint`. Pin indicating joint by joint mode is on.
-`whb.halui.mode.manual` (bit,out)::
+`whb.halui.mode.manual` (bool, out)::
Connect to `halui.mode.manual`. Pin for requesting manual mode.
-`whb.halui.mode.is-manual` (bit,in)::
+`whb.halui.mode.is-manual` (bool, in)::
Connect to `halui.mode.is-manual`. Pin indicating manual mode is on.
-`whb.halui.mode.mdi` (bit,out)::
+`whb.halui.mode.mdi` (bool, out)::
Connect to `halui.mode.mdi`. Pin for requesting MDI mode.
-`whb.halui.mode.is-mdi` (bit,in)::
+`whb.halui.mode.is-mdi` (bool, in)::
Connect to `halui.mode.is-mdi`. Pin indicating MDI mode is on.
-`whb.halui.mode.teleop` (bit,out)::
+`whb.halui.mode.teleop` (bool, out)::
Connect to `halui.mode.teleop`. Pin for requesting axis by axis mode.
-`whb.halui.mode.is-teleop` (bit,in)::
+`whb.halui.mode.is-teleop` (bool, in)::
Connect to `halui.mode.is-teleop`. Pin indicating axis by axis mode is on.
==== Buttons
@@ -290,101 +290,101 @@ MDI_COMMAND=(debug,macro16)
*__* ... denotes an arbitrary macro number which is of {1, 2, ..., 16}
-`whb.button.reset` (bit,out)::
+`whb.button.reset` (bool, out)::
See `whb.halui.estop.`{`activate`, `reset`}
True one Reset button down, false otherwise.
For toggling E-stop use whb.halui.estop .active and .reset.
-`whb.button.stop` (bit,out)::
+`whb.button.stop` (bool, out)::
See `whb.halui.program.stop`. True on Stop button down, false otherwise.
For stopping a program use `whb.halui.program.stop`.
-`whb.button.start-pause` (bit,out)::
+`whb.button.start-pause` (bool, out)::
See `whb.halui.program.`{`run`, `pause`, `resume`}`.
True on Start-Pause button down, false otherwise.
For toggling start-pause use `whb.halui.program.run`, `.pause`, and `.resume`.
-`whb.button.feed-plus` (bit,out)::
+`whb.button.feed-plus` (bool, out)::
True on Feed+ button down, false otherwise.
-`whb.button.feed-minus` (bit,out)::
+`whb.button.feed-minus` (bool, out)::
True on Feed- button down, false otherwise.
-`whb.button.spindle-plus` (bit,out)::
+`whb.button.spindle-plus` (bool, out)::
See `halui.spindle.0.override.increase`.
True on Spindle+ button down, false otherwise.
This button is meant to manipulate the spindle override.
For increasing the spindle override use `halui.spindle.0.override.increase`.
-`whb.button.spindle-minus` (bit,out)::
+`whb.button.spindle-minus` (bool, out)::
See `halui.spindle.0.override.decrease`.
True on Spindle- button down, false otherwise.
This button is meant to manipulate the spindle override.
For decreasing the spindle override use `halui.spindle.0.override.decrease`.
-`whb.button.m-home` (bit,out)::
+`whb.button.m-home` (bool, out)::
Connect to `halui.home-all`. True on M-Home button down, false otherwise.
Requests MDI mode before button pin is set. See also `whb.halui.mode.mdi`.
-`whb.button.safe-z` (bit,out)::
+`whb.button.safe-z` (bool, out)::
Connect to `halui.mdi-command-`____
True on Safe-Z button down, false otherwise.
Requests MDI mode before button pin is set. See also `whb.halui.mode.mdi`.
-`whb.button.w-home` (bit,out)::
+`whb.button.w-home` (bool, out)::
Connect to `halui.mdi-command-`____
True on W-Home button down, false otherwise.
Requests MDI mode before button pin is set. See also `whb.halui.mode.mdi`.
-`whb.button.s-on-off` (bit,out)::
+`whb.button.s-on-off` (bool, out)::
See ``whb.halui.spindle.``{``start``, ``stop``} True on S-ON/OFF button down, false otherwise.
For toggling spindle on-off use `halui.spindle.0.start`.
For toggling spindle on-off use `halui.spindle.0.stop`.
-`whb.button.fn` (bit,out)::
+`whb.button.fn` (bool, out)::
True on Fn button down, false otherwise.
-`whb.button.probe-z` (bit,out)::
+`whb.button.probe-z` (bool, out)::
Connect to `halui.mdi-command-`____ True on Probe-Z button down, false otherwise.
Requests MDI mode before button pin is set. See also `whb.halui.mode.mdi`.
-`whb.button.macro-1` (bit,out)::
+`whb.button.macro-1` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-1 button (Fn + Feed+) down, false otherwise.
-`whb.button.macro-2` (bit,out)::
+`whb.button.macro-2` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-2 button (Fn + Feed-) down, false otherwise.
-`whb.button.macro-3` (bit,out)::
+`whb.button.macro-3` (bool, out)::
See `whb.halui.spindle.increase` True on Macro-3 button (Fn + Spindle+) down, false otherwise.
This button is meant to manipulate the spindle speed.
For decreasing the spindle speed use whb.halui.spindle.increase.
-`whb.button.macro-4` (bit,out)::
+`whb.button.macro-4` (bool, out)::
See `whb.halui.spindle.decrease` True on Macro-4 button down (Fn + Spindle-), false otherwise.
This button is meant to manipulate the spindle speed.
For decreasing the spindle speed use `whb.halui.spindle.decrease`.
-`whb.button.macro-5` (bit,out)::
+`whb.button.macro-5` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-5 button down (Fn + M-HOME), false otherwise.
-`whb.button.macro-6` (bit,out)::
+`whb.button.macro-6` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-6 button down (Fn + Safe-Z), false otherwise.
-`whb.button.macro-7` (bit,out)::
+`whb.button.macro-7` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-7 button down (Fn + W-HOME), false otherwise.
-`whb.button.macro-8` (bit,out)::
+`whb.button.macro-8` (bool, out)::
Reserved for Spindle Direction True on Macro-8 button down (Fn + S-ON/OFF), false otherwise.
-`whb.button.macro-9` (bit,out)::
+`whb.button.macro-9` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-9 button down (Fn + Probe-Z), false otherwise.
-`whb.button.macro-10` (bit,out)::
+`whb.button.macro-10` (bool, out)::
Reserved for toggle DRO Abs/rel.
True on Macro-10 button down, false otherwise.
Switches the display coordinates to relative coordinates.
On display the axis are denoted then as X1, Y1, Z1, A1, B1 and C1.
See also `whb.halui.axis.`____`.pos-relative`.
-`whb.button.macro-11` (bit,out)::
+`whb.button.macro-11` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-11 button down (Fn + RESET), false otherwise.
-`whb.button.macro-12` (bit,out)::
+`whb.button.macro-12` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-12 button (Fn + Stop) down, false otherwise.
-`whb.button.macro-13` (bit,out)::
+`whb.button.macro-13` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-13 button (Fn + Start/Pause) down, false otherwise.
-`whb.button.macro-14` (bit,out)::
+`whb.button.macro-14` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-14 button (Fn + Macro-10) down, false otherwise.
-`whb.button.macro-15` (bit,out)::
+`whb.button.macro-15` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-15 button down (Fn + MPG), false otherwise.
-`whb.button.macro-16` (bit,out)::
+`whb.button.macro-16` (bool, out)::
Connect to `halui.mdi-command-`____ True on Macro-16 button (Fn + Step) down, false otherwise.
-`whb.button.mode-continuous` (bit,out)::
+`whb.button.mode-continuous` (bool, out)::
True on Continuous mode button down, false otherwise.
-`whb.button.mode-step` (bit,out)::
+`whb.button.mode-step` (bool, out)::
True on Step mode button down, false otherwise.
==== Pendant
-`whb.pendant.is-sleeping` (bit,out)::
+`whb.pendant.is-sleeping` (bool, out)::
True as long pendant is in sleep mode (usually a few seconds after turned off), false otherwise.
-`whb.pendant.is-connected` (bit,out)::
+`whb.pendant.is-connected` (bool, out)::
True as long pendant is not in sleep mode (turned on), false otherwise.
== HAL Configuration Example
diff --git a/docs/src/man/man3/hal_create_thread.3.adoc b/docs/src/man/man3/hal_create_thread.3.adoc
index 9289803f210..dbbc8d258ce 100644
--- a/docs/src/man/man3/hal_create_thread.3.adoc
+++ b/docs/src/man/man3/hal_create_thread.3.adoc
@@ -12,7 +12,7 @@ hal_create_thread - Create a HAL thread
----
#include
-int hal_create_thread(const char *name, unsigned long period, int uses_fp);
+int hal_create_thread(const char *name, unsigned long period);
int hal_thread_delete(const char *name);
----
@@ -22,9 +22,6 @@ name::
The name of the thread.
period::
The interval, in nanoseconds, between iterations of the thread.
-uses_fp::
- Deprecated and ignored. All threads now unconditionally save and restore
- floating point state. This parameter will be removed in a future version.
== DESCRIPTION
diff --git a/docs/src/man/man3/hal_export_funct.3.adoc b/docs/src/man/man3/hal_export_funct.3.adoc
index 3ff00485fab..484cefbd145 100644
--- a/docs/src/man/man3/hal_export_funct.3.adoc
+++ b/docs/src/man/man3/hal_export_funct.3.adoc
@@ -14,8 +14,8 @@ hal_export_funct, hal_export_functf - create a realtime function callable from a
typedef void(*hal_funct_t)(void *arg, long period);
-int hal_export_funct(const char *name, hal_funct_t funct, void *arg, int uses_fp, int reentrant, int comp_id);
-int hal_export_functf(hal_funct_t funct, void *arg, int uses_fp, int reentrant, int comp_id, const char *fmt, ...);
+int hal_export_funct(const char *name, hal_funct_t funct, void *arg, int reentrant, int comp_id);
+int hal_export_functf(hal_funct_t funct, void *arg, int reentrant, int comp_id, const char *fmt, ...);
----
== ARGUMENTS
@@ -26,9 +26,6 @@ funct::
The pointer to the function.
arg::
The argument to be passed as the first parameter of _funct_.
-uses_fp::
- Deprecated and ignored. All threads now unconditionally save and restore
- floating point state. This parameter will be removed in a future version.
reentrant::
If reentrant is non-zero, the function may be preempted and called again before the first call completes.
Otherwise, it may only be added to one thread.
diff --git a/docs/src/man/man3/rtapi_task_new.3.adoc b/docs/src/man/man3/rtapi_task_new.3.adoc
index fd437d71172..5f22d802087 100644
--- a/docs/src/man/man3/rtapi_task_new.3.adoc
+++ b/docs/src/man/man3/rtapi_task_new.3.adoc
@@ -10,8 +10,7 @@ rtapi_task_new, rtapi_task_delete - create a realtime task
[source,c]
----
-int rtapi_task_new(void (*_taskcode_)(void*), void *_arg_, int _prio_,
- unsigned long _stacksize_, int _uses_fp_);
+int rtapi_task_new(void (*_taskcode_)(void*), void *_arg_, int _prio_, unsigned long _stacksize_);
int rtapi_task_delete(int _task_id_);
----
@@ -23,9 +22,6 @@ arg::
An argument to be passed to the _taskcode_ function when the task is started
prio::
A task priority value returned by *rtapi_prio_xxxx*
-uses_fp::
- Deprecated and ignored. All tasks now unconditionally save and restore
- floating point state. This parameter will be removed in a future version.
task_id::
A task ID returned by a previous call to *rtapi_task_new*
diff --git a/docs/src/man/man9/classicladder.9.adoc b/docs/src/man/man9/classicladder.9.adoc
index 71b2924f554..520b75cccc8 100644
--- a/docs/src/man/man9/classicladder.9.adoc
+++ b/docs/src/man/man9/classicladder.9.adoc
@@ -27,35 +27,35 @@ the outputs.
== PINS
-**classicladder.0.in-**_NN_ IN bit::
- These bit signal pins map to **%I**_NN_ variables in ClassicLadder.
-**classicladder.0.out-**_NN_ OUT bit::
- These bit signal pins map to **%Q**_NN_ variables in ClassicLadder.
+**classicladder.0.in-**_NN_ IN bool::
+ These bool signal pins map to **%I**_NN_ variables in ClassicLadder.
+**classicladder.0.out-**_NN_ OUT bool::
+ These bool signal pins map to **%Q**_NN_ variables in ClassicLadder.
Output from ClassicLadder.
-**classicladder.0.s32in-**_NN_ IN s32::
+**classicladder.0.s32in-**_NN_ IN sint::
Integer input from ClassicLadder.
- These s32 signal pins map to **%IW**_NN_ variables in ClassicLadder.
-**classicladder.0.s32out-**_NN_ OUT s32::
+ These sint signal pins map to **%IW**_NN_ variables in ClassicLadder.
+**classicladder.0.s32out-**_NN_ OUT sint::
Integer output from ClassicLadder.
- These s32 signal pins map to **%QW**_NN_ variables in ClassicLadder.
-**classicladder.0.floatin-**_NN_ IN float::
+ These sint signal pins map to **%QW**_NN_ variables in ClassicLadder.
+**classicladder.0.floatin-**_NN_ IN real::
Integer input from ClassicLadder.
- These float signal pins map to **%IF**_NN_ variables in ClassicLadder.
+ These real signal pins map to **%IF**_NN_ variables in ClassicLadder.
These are truncated to S32 values internally, e.g. 7.5 will be 7.
-**classicladder.0.floatout-**_NN_ OUT float::
- Float output from ClassicLadder.
- These float signal pins map to **%QF**_NN_ variables in ClassicLadder.
-**classicladder.0.hide_gui** IN bit::
- This bit pin hides the ClassicLadder window, while still having the non-realtime code run.
+**classicladder.0.floatout-**_NN_ OUT real::
+ Real output from ClassicLadder.
+ These real signal pins map to **%QF**_NN_ variables in ClassicLadder.
+**classicladder.0.hide_gui** IN bool::
+ This bool pin hides the ClassicLadder window, while still having the non-realtime code run.
This is usually desirable when modbus is used, as modbus requires the non-realtime code to run.
== PARAMETERS
-*classicladder.0.refresh.time* RO s32::
+*classicladder.0.refresh.time* RO sint::
Tells you how long the last refresh took.
-*classicladder.0.refresh.tmax* RW s32::
+*classicladder.0.refresh.tmax* RW sint::
Tells you how long the longest refresh took.
-*classicladder.0.ladder-state* RO s32::
+*classicladder.0.ladder-state* RO sint::
Tells you if the program is running or not
== FUNCTIONS
diff --git a/docs/src/man/man9/counter.9.adoc b/docs/src/man/man9/counter.9.adoc
index e308dbb16ff..b93aeefe331 100644
--- a/docs/src/man/man9/counter.9.adoc
+++ b/docs/src/man/man9/counter.9.adoc
@@ -36,29 +36,29 @@ HAL manual.
== PINS
-**counter.**_N_**.phase-A** bit in::
+**counter.**_N_**.phase-A** bool in::
The primary input signal. The internal counter is incremented on each rising edge.
-**counter.**_N_**.phase-Z** bit in::
+**counter.**_N_**.phase-Z** bool in::
The index input signal. When the *index-enable* pin is TRUE and a
rising edge on *phase-Z* is seen, *index-enable* is set to FALSE and
the internal counter is reset to zero.
-**counter.**_N_**.index-enable** bit io::
+**counter.**_N_**.index-enable** bool io::
+
-**counter.**_N_**.reset** bit io::
+**counter.**_N_**.reset** bool io::
+
-**counter.**_N_**.counts** signed out::
+**counter.**_N_**.counts** sint out::
+
-**counter.**_N_**.position** float out::
+**counter.**_N_**.position** real out::
+
-**counter.**_N_**.velocity** float out::
+**counter.**_N_**.velocity** real out::
These pins function according to the canonical digital encoder interface.
-**counter.**_N_**.position-scale** float rw::
+**counter.**_N_**.position-scale** real rw::
This parameter functions according to the canonical digital encoder interface.
-**counter.**_N_**.rawcounts** signed ro::
+**counter.**_N_**.rawcounts** sint ro::
The internal counts value, updated from *update-counters* and
reflected in the output pins at the next call to *capture-position*.
diff --git a/docs/src/man/man9/debounce.9.adoc b/docs/src/man/man9/debounce.9.adoc
index 32f98996306..88816d9f956 100644
--- a/docs/src/man/man9/debounce.9.adoc
+++ b/docs/src/man/man9/debounce.9.adoc
@@ -39,10 +39,10 @@ signal to be present for _N_ samples before the output changes state.
== PINS
-**debounce.**_G_**.**_F_**.in** bit in::
+**debounce.**_G_**.**_F_**.in** bool in::
The F'th input pin in group G.
-**debounce.**_G_**.**_F_**.out** bit out::
+**debounce.**_G_**.**_F_**.out** bool out::
The F'th output pin in group _G_.
Reflects the last "stable" input seen on the corresponding input pin.
-**debounce.**_G_**.delay** signed rw::
+**debounce.**_G_**.delay** sint rw::
Sets the amount of filtering for all pins in group _G_.
diff --git a/docs/src/man/man9/demux_generic.9.adoc b/docs/src/man/man9/demux_generic.9.adoc
index 01d75542fe8..9948af5df4d 100644
--- a/docs/src/man/man9/demux_generic.9.adoc
+++ b/docs/src/man/man9/demux_generic.9.adoc
@@ -8,7 +8,7 @@ demux_generic - routes a single input signal to one of multiple outputs
**loadrt demux_generic config="**____[,____],...**"**
-Types: **b** = bit, **f** = float, **s** = signed integer, **u** = unsigned integer
+Types: **b** = bool, **f** = real, **s** = sint, **u** = uint
Example:
**loadrt demux_generic config="**bb8,fu12**"**
@@ -16,7 +16,7 @@ Example:
== FUNCTIONS
-**demux-gen.**_NN_ Depending on the data types can run in either a floating point or non-floating point thread.
+**demux-gen.**_NN_ Demultiplexer function.
== PINS
@@ -25,22 +25,22 @@ Example:
demux-gen.NN.sel-bit-BB ───────────────┐ │ │
demux-gen.NN.sel-int ─────────────┐ │ │ │
┌───────┴─┴─┴─┴───────┐
- │ / o───── ├───── demux-gen.NN.out-[bit/float/s32/u32]-00
-demux-gen.NN.in-[bit/float/s32/u32] ─────┤ ─────o o───── ├───── ...
- │ o───── ├───── demux-gen.NN.out-[bit/float/s32/u32]-MM
+ │ / o───── ├───── demux-gen.NN.out-[bool/real/sint/uint]-00
+demux-gen.NN.in-[bool/real/sint/uint] ───┤ ─────o o───── ├───── ...
+ │ o───── ├───── demux-gen.NN.out-[bool/real/sint/uint]-MM
demux-gen.NN.suppress-no-input ─────┤ │
demux-gen.NN.debounce-us ─────┤ │
└─────────────────────┘
-**demux-gen**.__N__.**suppress-no-input** bit in::
+**demux-gen**.__N__.**suppress-no-input** bool in::
This suppresses changing the output if all select lines are false.
This stops unwanted jumps in output between transitions of input but makes in00 unavailable.
-**demux-gen**.__N__.**debounce-us** unsigned in::
+**demux-gen**.__N__.**debounce-us** uint in::
sets debounce time in microseconds, e.g. 100000 = a tenth of a second.
The selection inputs must be stable this long before the output
changes. This helps to ignore 'noisy' switches.
-**demux-gen**.__N__.**sel-bit-**__BB__ bit in (BB=0..bit width of _size_)::
-**demux-gen**.__N__.**sel-int** unsigned in::
+**demux-gen**.__N__.**sel-bit-**__BB__ bool in (BB=0..bit width of _size_)::
+**demux-gen**.__N__.**sel-int** uint in::
The sel-bit pins are only created when the size of the demux_gen
component is an integer power of two.
Together, these determine to which **out**-__MM__ the **in** value is forwarded.
@@ -48,21 +48,20 @@ demux-gen.NN.in-[bit/float/s32/u32] ─────┤ ─────o o─
added on to the integer pin input. It is expected that either one or
the other would normally be used. However, the possibility exists to
use a higher-order bit to "shift" the values set by the integer pin.
-**demux-gen**.__N__.**in-**[**bit**/**float**/**s32**/**u32**] variable-type in::
+**demux-gen**.__N__.**in-**[**bool**/**real**/**sint**/**uint**] variable-type in::
The input value which is routed to an output depending on the selection pins.
-**demux-gen**.__N__.**out-**[**bit**/**float**/**s32**/**u32**]**-**__MM__ variable-type out (M=0..size-1)::
+**demux-gen**.__N__.**out-**[**bool**/**real**/**sint**/**uint**]**-**__MM__ variable-type out (M=0..size-1)::
According to the selection bits and/or the selection number, the selected output
follows the **in** value. The other outputs retain the values they had before
resp. zero if they have not been selected yet. Values will be
- converted/truncated according to standard C rules. This means, for
- example that a float input greater than 2147483647 will give an S32
- output of -2147483648.
+ converted and clamped. This means, for example that a REAL input greater
+ than (approx.) 2^63^-1 will give a SINT output of 2^63^-1.
== PARAMETERS
-**demux-gen**.__N__.**elapsed** float r::
+**demux-gen**.__N__.**elapsed** real r::
Current value of the internal debounce timer for debugging.
-**demux-gen**.__N__.**selected** s32 r::
+**demux-gen**.__N__.**selected** sint r::
Current value of the internal selection variable after conversion for debugging.
Possibly useful for setting up gray-code switches.
@@ -73,26 +72,22 @@ It allows the creation of arbitrary-size demultiplexers (up to
1024 entries) and also supports differing data types on the input and
output pins. The configuration string is a comma-separated list of
code-letters and numbers, such as "bb4,fu12". This would create a
-4-element bit-to-bit demux and a 12-element float-to-unsigned demux.
+4-element bit-to-bit demux and a 12-element real-to-uint demux.
The code letters are:
-**b** = bit,
-**f** = float,
-**s** = signed integer and
-**u** = unsigned integer.
+**b** = bool (boolean),
+**f** = real (floating point),
+**s** = sint (signed integer) and
+**u** = uint (unsigned integer).
The first letter code is the input type, the second is the
output type. The codes are not case-sensitive. The order of the letters
is significant but the position in the string is not. Do not insert any
-spaces in the config string. Any non-zero float value will be converted
-to a "true" output in bit form. Be wary that float datatypes can be
-very, very, close to zero and not actually be equal to zero.
+spaces in the config string. Any non-zero real value will be converted
+to a "true" output in bool form when it is more than ±2e-7 from zero.
Each demux has its own HAL function and must be added to a thread
-separately. If neither input nor output is of type float then the
-function is base-thread (non floating-point) safe. Any demux_generic with
-a floating point input or output can only be added to a floating-point
-thread.
+separately.
== SEE ALSO
diff --git a/docs/src/man/man9/encoder.9.adoc b/docs/src/man/man9/encoder.9.adoc
index daf0b0ea380..8ac3735bb01 100644
--- a/docs/src/man/man9/encoder.9.adoc
+++ b/docs/src/man/man9/encoder.9.adoc
@@ -60,85 +60,85 @@ The *encoder*.__N__. format is shown in the following descriptions.
== PINS
-**encoder**.__N__.**counter-mode** bit i/o::
+**encoder**.__N__.**counter-mode** bool i/o::
Enables counter mode. When true, the counter counts each rising edge
of the phase-A input, ignoring the value on phase-B. This is useful
for counting the output of a single channel (non-quadrature) sensor.
When false (the default), it counts in quadrature mode.
-**encoder**.__N__.**counts** s32 out::
+**encoder**.__N__.**counts** sint out::
Position in encoder counts.
-**encoder**.__N__.**index-enable** bit i/o::
+**encoder**.__N__.**index-enable** bool i/o::
When true, *counts* and *position* are reset to zero on the next
rising edge of *Phase-Z*. At the same time, *index-enable* is reset to
zero to indicate that the rising edge has occurred.
-**encoder**.__N__.**min-speed-estimate** float in (default: 1.0)::
+**encoder**.__N__.**min-speed-estimate** real in (default: 1.0)::
Determine the minimum speed at which *velocity* will be estimated as
nonzero and *postition-interpolated* will be interpolated. The units
of *min-speed-estimate* are the same as the units of *velocity*.
Setting this parameter too low will cause it to take a long time for
*velocity* to go to 0 after encoder pulses have stopped arriving.
-**encoder**.__N__.**phase-A** bit in::
+**encoder**.__N__.**phase-A** bool in::
Quadrature input for encoder channel _N_.
-**encoder**.__N__.**phase-B** bit in::
+**encoder**.__N__.**phase-B** bool in::
Quadrature input.
-**encoder**.__N__.**phase-Z** bit in::
+**encoder**.__N__.**phase-Z** bool in::
Index pulse input.
-**encoder**.__N__.**position** float out::
+**encoder**.__N__.**position** real out::
Position in scaled units (see *position-scale*)
-**encoder**.__N__.**position-interpolated** float out::
+**encoder**.__N__.**position-interpolated** real out::
Position in scaled units, interpolated between encoder counts. Only
valid when velocity is approximately constant and above
*min-speed-estimate*. Do not use for position control.
-**encoder**.__N__.**position-scale** float i/o::
+**encoder**.__N__.**position-scale** real i/o::
Scale factor, in counts per length unit. For example, if
*position-scale* is 500, then 1000 counts of the encoder will be
reported as a position of 2.0 units.
-**encoder**.__N__.**missing-teeth** s32 in::
+**encoder**.__N__.**missing-teeth** sint in::
The number of teeth missing from the index gap. For example a 60 tooth
gear with two teeth shortened to form an index so that there are 58
pulses per revolution would use a position-scale of 60 and a
missing-teeth of 2.
-**encoder**.__N__.**rawcounts** s32 out::
+**encoder**.__N__.**rawcounts** sint out::
The raw count, as determined by *update-counters*. This value is
updated more frequently than *counts* and *position*. It is also
unaffected by *reset* or the index pulse.
-**encoder**.__N__.**reset** bit in::
+**encoder**.__N__.**reset** bool in::
When true, *counts* and *position* are reset to zero immediately.
-**encoder**.__N__.**velocity** float out::
+**encoder**.__N__.**velocity** real out::
Velocity in scaled units per second. *encoder* uses an algorithm that
greatly reduces quantization noise as compared to simply
differentiating the *position* output. When the magnitude of the true
velocity is below min-speed-estimate, the velocity output is 0.
-**encoder**.__N__.**velocity-rpm** float out::
- Velocity in scaled units per minute. Simply *encoder**.__N__.**velocity*
+**encoder**.__N__.**velocity-rpm** real out::
+ Velocity in scaled units per minute. Simply **encoder**.__N__.**velocity**
scaled by a factor of 60 for convenience.
-**encoder**.__N__.**x4-mode** bit i/o::
+**encoder**.__N__.**x4-mode** bool i/o::
Enables times-4 mode. When true (the default), the counter counts each
edge of the quadrature waveform (four counts per full cycle). When
false, it only counts once per full cycle. In *counter-mode*, this
parameter is ignored.
-**encoder**.__N__.**latch-input** bit in::
+**encoder**.__N__.**latch-input** bool in::
+
-**encoder**.__N__.**latch-falling** bit in (default: *TRUE*)::
+**encoder**.__N__.**latch-falling** bool in (default: *TRUE*)::
+
-**encoder**.__N__.**latch-rising** bit in (default: *TRUE*)::
+**encoder**.__N__.**latch-rising** bool in (default: *TRUE*)::
+
-**encoder**.__N__.**counts-latched** s32 out::
+**encoder**.__N__.**counts-latched** sint out::
+
-**encoder**.__N__.**position-latched** float out::
+**encoder**.__N__.**position-latched** real out::
Update *counts-latched* and *position-latched* on the rising and/or
falling edges of *latch-input* as indicated by *latch-rising* and
*latch-falling*.
-**encoder**.__N__.**counter-mode** bit rw::
+**encoder**.__N__.**counter-mode** bool rw::
Enables counter mode. When true, the counter counts each rising edge
of the phase-A input, ignoring the value on phase-B. This is useful
for counting the output of a single channel (non-quadrature) sensor.
When false (the default), it counts in quadrature mode.
-**encoder**.__N__.**capture-position.tmax** s32 rw::
+**encoder**.__N__.**capture-position.tmax** sint rw::
Maximum time in ns it took to execute this function.
== PARAMETERS
diff --git a/docs/src/man/man9/encoder_ratio.9.adoc b/docs/src/man/man9/encoder_ratio.9.adoc
index a9ba0ce7281..e15820811a1 100644
--- a/docs/src/man/man9/encoder_ratio.9.adoc
+++ b/docs/src/man/man9/encoder_ratio.9.adoc
@@ -39,18 +39,18 @@ The *encoder-ratio.N.* format is shown in the following descriptions.
== PINS
-**encoder-ratio.**_N_**.master-A** bit in::
+**encoder-ratio.**_N_**.master-A** bool in::
+
-**encoder-ratio.**_N_**.master-B** bit in::
+**encoder-ratio.**_N_**.master-B** bool in::
+
-**encoder-ratio.**_N_**.slave-A** bit in::
+**encoder-ratio.**_N_**.slave-A** bool in::
+
-**encoder-ratio.**_N_**.slave-B** bit in::
+**encoder-ratio.**_N_**.slave-B** bool in::
The encoder channels of the master and slave axes.
-**encoder-ratio.**_N_**.enable** bit in::
+**encoder-ratio.**_N_**.enable** bool in::
When the enable pin is FALSE, the error pin simply reports the slave
axis position, in revolutions. As such, it would normally be connected
to the feedback pin of a PID block for closed loop control of the
@@ -60,18 +60,18 @@ The *encoder-ratio.N.* format is shown in the following descriptions.
minus the scaled master position. The scale factor is the ratio of
master teeth to slave teeth. As the master moves, error becomes
non-zero, and the PID loop will drive the slave axis to track the master.
-**encoder-ratio.**_N_**.error** float out::
+**encoder-ratio.**_N_**.error** real out::
The error in the position of the slave (in revolutions).
== PARAMETERS
-**encoder-ratio.**_N_**.master-ppr** unsigned rw::
+**encoder-ratio.**_N_**.master-ppr** uint rw::
-**encoder-ratio.**_N_**.slave-ppr** unsigned rw::
+**encoder-ratio.**_N_**.slave-ppr** uint rw::
The number of pulses per revolution of the master and slave axes.
-**encoder-ratio.**_N_**.master-teeth** unsigned rw::
+**encoder-ratio.**_N_**.master-teeth** uint rw::
-**encoder-ratio.**_N_**.slave-teeth** unsigned rw::
+**encoder-ratio.**_N_**.slave-teeth** uint rw::
The number of "teeth" on the master and slave gears.
== SEE ALSO
diff --git a/docs/src/man/man9/enum.9.adoc b/docs/src/man/man9/enum.9.adoc
index 66c9e7e4fc0..8dc5b320bea 100644
--- a/docs/src/man/man9/enum.9.adoc
+++ b/docs/src/man/man9/enum.9.adoc
@@ -40,7 +40,7 @@ Conversely, if *enum-encode.00.input* is set to 4 then the pin
== OPTIONS
Preceding the list of labels should be the control-codes "D" for decode
-or "E" for encode. A D-type enum will set the value of HAL bit pins in
+or "E" for encode. A D-type enum will set the value of HAL bool pins in
response to changes to the enum-decode.NN.input value, whereas an E-type
enum will set the value of the enum-encode.NN.output integer depending
on which enum-encode.NN.label-bit value is set.
@@ -58,12 +58,12 @@ E and D-type enumerations may be freely mixed in separate instances.
== PINS
-**enum-decode.**_NN_.input:: The integer value to be decoded
+**enum-decode.**_NN_.input:: The uint integer value to be decoded
**enum-decode.**_NN_.label-out:: Output bits of a decode instance
-**enum-decode.**_NN_.label-val:: The enumeration value corresponding to
- each specific bit output. These are
+**enum-decode.**_NN_.label-val:: The uint enumeration value corresponding to
+ each specific bool output. These are
populated in sequence during loading
but may be over-ridden in HAL if
convenient.
@@ -71,12 +71,12 @@ E and D-type enumerations may be freely mixed in separate instances.
**enum-encode.**_NN_**.label-in**:: input bits of a decode instance
**enum-encode.**_NN_**.label-val**:: The enumeration value corresponding to
- each specified bit input. These are
+ each specified bool input. These are
populated in sequence during loading
but may be over-ridden in HAL if
convenient.
-**enum-decode.**_NN_**.output**:: The integer value corresponding to the set bit input.
+**enum-decode.**_NN_**.output**:: The uint integer value corresponding to the set bool input.
== BUGS
diff --git a/docs/src/man/man9/hal_bb_gpio.9.adoc b/docs/src/man/man9/hal_bb_gpio.9.adoc
index 80f12f18c38..ddbc117cd1a 100644
--- a/docs/src/man/man9/hal_bb_gpio.9.adoc
+++ b/docs/src/man/man9/hal_bb_gpio.9.adoc
@@ -17,10 +17,10 @@ Empirically, these seem to be OR'd with whatever function is assigned to the LED
=== PINS
-**bb_gpio.userled**_N_ bit in::
+**bb_gpio.userled**_N_ bool in::
+
-**bb_gpio.userled**_N_**-invert** bit in::
+**bb_gpio.userled**_N_**-invert** bool in::
The associated LED is lit if **userled**_N_ xor **userled**_N_-invert is TRUE.
== INPUT PINS
@@ -37,10 +37,10 @@ system.
=== PINS
-**bb_gpio.p**_N_**.in-**_NN_ bit out::
+**bb_gpio.p**_N_**.in-**_NN_ bool out::
+
-**bb_gpio.p**_N_**.in-**_NN_**-invert** bit in::
+**bb_gpio.p**_N_**.in-**_NN_**-invert** bool in::
**in-**_NN_ is a snapshot of the value of the corresponding physical pin
XOR the value of the corresponding **in-**_NN_**-invert** pin.
@@ -56,10 +56,10 @@ system.
=== PINS
-**bb_gpio.p**_N_**.out-**_NN_ bit out::
+**bb_gpio.p**_N_**.out-**_NN_ bool out::
+
-**bb_gpio.p**_N_**.out-**_NN_**-invert** bit in::
+**bb_gpio.p**_N_**.out-**_NN_**-invert** bool in::
The corresponding physical pin is driven with the result of **in-**_NN_
xor **in-**_NN_**-invert**.
diff --git a/docs/src/man/man9/hal_parport.9.adoc b/docs/src/man/man9/hal_parport.9.adoc
index 7aca5ac2bb2..182ca9455bc 100644
--- a/docs/src/man/man9/hal_parport.9.adoc
+++ b/docs/src/man/man9/hal_parport.9.adoc
@@ -49,11 +49,11 @@ _x_:: The option allows ports with open collectorts on the control group pins to
The pins created by the hal_parport component depends on how it is
configured in the **cfg="" **string passed to it, see OPTIONS.
-**parport**.__p__.**pin-**__n__**-out** (bit):: Drives a physical output pin.
+**parport**.__p__.**pin-**__n__**-out** (bool):: Drives a physical output pin.
-**parport**.__p__.**pin-**__n__**-in** (bit):: Tracks a physical input pin.
+**parport**.__p__.**pin-**__n__**-in** (bool):: Tracks a physical input pin.
-**parport**.__p__.**pin-**__n__**-in-not** (bit):: Tracks a physical input pin, but inverted.
+**parport**.__p__.**pin-**__n__**-in-not** (bool):: Tracks a physical input pin, but inverted.
For each pin created, **_p_** is the port number, and **_n_** is the
physical pin number in the 25 pin D-shell connector.
@@ -82,12 +82,12 @@ in the cfg="" string.
== PARAMETERS
-**parport**.__p__.**pin--out-invert** (bit)::
+**parport**.__p__.**pin--out-invert** (bool)::
Inverts an output pin.
-**parport**.__p__.**pin--out-reset** (bit)::
+**parport**.__p__.**pin--out-reset** (bool)::
(only for out pins) TRUE if this pin should be reset when the .reset
function is executed.
-**parport**.__p__.**reset-time** (u32)::
+**parport**.__p__.**reset-time** (uint)::
The time (in nanoseconds) between a pin is set by write and reset by
the reset function if it is enabled.
diff --git a/docs/src/man/man9/hm2_modbus.9.adoc b/docs/src/man/man9/hm2_modbus.9.adoc
index e8b81e5cb14..2c82facfa00 100644
--- a/docs/src/man/man9/hm2_modbus.9.adoc
+++ b/docs/src/man/man9/hm2_modbus.9.adoc
@@ -107,21 +107,21 @@ the practical limit will be effective communication speed and bus load.
=== PARAMETERS
Exported parameters for driver instance `N`:
-hm2_modbus.N.baudrate (u32, readonly)::
+hm2_modbus.N.baudrate (uint, readonly)::
The communication baudrate.
-hm2_modbus.N.drivedelay (u32, readonly)::
+hm2_modbus.N.drivedelay (uint, readonly)::
The transmitter wait time between enabling the transmitter and start sending
in bit-times.
-hm2_modbus.N.icdelay (u32, readonly)::
+hm2_modbus.N.icdelay (uint, readonly)::
The maximum inter-character delay accepted in received frames in bit-times.
Set to zero (0) when disabled.
-hm2_modbus.N.parity' (u32, readonly)::
+hm2_modbus.N.parity' (uint, readonly)::
The communication parity (0=None, 1=Odd, 2=Even).
-hm2_modbus.N.rxdelay (u32, readonly)::
+hm2_modbus.N.rxdelay (uint, readonly)::
The inter-frame delay required before a packet is accepted in bit-times.
-hm2_modbus.N.stopbits (u32, readonly)::
+hm2_modbus.N.stopbits (uint, readonly)::
The communication number of stopbits (1 or 2).
-hm2_modbus.N.txdelay (u32, readonly)::
+hm2_modbus.N.txdelay (uint, readonly)::
The inter-frame delay inserted after a packet in bit-times.
The parameters are all read/only. There is normally no need to alter any
@@ -132,16 +132,16 @@ parameters. Any tuning of values should be done in the mbccs/mbccb file.
Each driver instance `N` exports the following pins to control the instance's
operation and indicate the instance's status:
-hm2_modbus.N.fault (bit, output)::
+hm2_modbus.N.fault (bool, output)::
Indicates a fault condition.
-hm2_modbus.N.fault-command (u32, output)::
+hm2_modbus.N.fault-command (uint, output)::
The command index that caused the last fault condition.
-hm2_modbus.N.last-error-code (u32, output)::
+hm2_modbus.N.last-error-code (uint, output)::
The errno value of the error that caused the fault condition.
-hm2_modbus.N.reset (bit, input)::
+hm2_modbus.N.reset (bool, input)::
Reset all commands error counters and re-enable disabled commands on the
rising edge of the input pin.
-hm2_modbus.N.suspend (bit, input)::
+hm2_modbus.N.suspend (bool, input)::
Suspend all activity while set. The default can be set in the MBCCB file. +
Suspended start (when set in the MBCCB file) can ensure that all HAL files
and commands are parsed and executed (like setp and sets commands) before
@@ -164,12 +164,12 @@ Each command in the MBCCB file (not init commands) will generate a set of pins
to reflect the current state, where `MM` is the command number counting from zero
(00):
-hm2_modbus.N.command.MM.disable (bit, input)::
+hm2_modbus.N.command.MM.disable (bool, input)::
Disable this command on the rising edge of this pin. You need to use the
command's corresponding reset pin to re-enable it.
-hm2_modbus.N.command.MM.disabled (bit, output)::
+hm2_modbus.N.command.MM.disabled (bool, output)::
Set if the command is no longer sent in the commands loop.
-hm2_modbus.N.command.MM.error-code (u32, output)::
+hm2_modbus.N.command.MM.error-code (uint, output)::
The errno code of the last error. The following error codes can be set:
** 5, 0x05 (EIO): The receiver detected an overrun, a false start-bit or wrong parity.
@@ -186,11 +186,11 @@ hm2_modbus.N.command.MM.error-code (u32, output)::
** 90, 0x5a (EMSGSIZE): The message did not fit into the maximum PDU size of 253.
** 110, 0x6e (ETIMEDOUT): The command received no reply and timed out.
-hm2_modbus.N.command.MM.errors (u32, output)::
+hm2_modbus.N.command.MM.errors (uint, output)::
The number of consecutive errors seen in this command. The command will be
disabled when this count reaches five (5). The value will be reset to zero (0)
when the command succeeds.
-hm2_modbus.N.command.MM.reset (bit, input)::
+hm2_modbus.N.command.MM.reset (bool, input)::
Reset this command's error counter and re-enable the command on the rising
edge of the input pin. +
Note: Re-enabling the command will honor the 'writeflush' setting of the
diff --git a/docs/src/man/man9/lcd.9.adoc b/docs/src/man/man9/lcd.9.adoc
index 33559de4194..b3692643400 100644
--- a/docs/src/man/man9/lcd.9.adoc
+++ b/docs/src/man/man9/lcd.9.adoc
@@ -15,22 +15,22 @@ lcd - Stream HAL data to an LCD screen
== PINS
-**lcd.**_NN_**.out** (u32) out::
+**lcd.**_NN_**.out** (uint) out::
The output byte stream is sent via this pin. One character is sent
every thread invocation. There in no handshaking provided.
-**lcd.**_NN_**.page.**_PP._**arg.**_NN_ (float/s32/u32/bit) in::
+**lcd.**_NN_**.page.**_PP._**arg.**_NN_ (real/sint/uint/bool) in::
The input pins have types matched to the format string specifiers.
-**lcd.**_NN_**.page_num** (u32) in::
+**lcd.**_NN_**.page_num** (uint) in::
Selects the page number. Multiple layouts may be defined, and this pin
switches between them.
-**lcd.**_NN_**.contrast** (float) in::
+**lcd.**_NN_**.contrast** (real) in::
Attempts to set the contrast of the LCD screen using the byte sequence
ESC C and then a value from 0x20 to 0xBF (matching the Mesa 7I73).
The value should be between 0 and 1.
== PARAMETERS
-**lcd.**_NN_**.decimal-separator** (u32) rw::
+**lcd.**_NN_**.decimal-separator** (uint) rw::
Sets the decimal separator used for floating point numbers. The
default value is 46 (0x2E) which corresponds to ".". If a comma is
required then set this parameter to 44 (0x2C).
@@ -121,26 +121,26 @@ The numerical formats supported are:
variable format width, with a sign only shown for negative numbers.
Both %f and %F create exactly the same format.
-* *%i %d* (For example %+ 4d): Creates a signed (s32) HAL pin. The example
+* *%i %d* (For example %+ 4d): Creates a signed (sint) HAL pin. The example
would display the value at a fixed 4 characters, space padded, width
including the "+" giving a range of +999 to -999. %i and %d create
identical output.
-* *%u* (for example %08u): Creates an unsigned (u32) HAL pin.
+* *%u* (for example %08u): Creates an unsigned (uint) HAL pin.
The example would be a fixed 8 characters wide, padded with zeros.
-* *%x, %X*: Creates an unsigned (u32) HAL pin and displays the value in Hexadecimal.
+* *%x, %X*: Creates an unsigned (uint) HAL pin and displays the value in Hexadecimal.
Both %x and %X display capital letters for digits ABCDEF.
- A width may be specified, though the u32 HAL type is only 8 hex digits wide.
+ A width may be specified, though the uint HAL type is only 8 hex digits wide.
-* *%o*: Creates an unsigned (u32) pin and displays the value in octal representation.
+* *%o*: Creates an unsigned (uint) pin and displays the value in octal representation.
-* *%c*: Creates a u32 HAL pin and displays the character corresponding to
+* *%c*: Creates a uint HAL pin and displays the character corresponding to
the value of the pin. Values less than 32 (space) are suppressed.
A width specifier may be used, for example %20c might be used to create a
complete line of one character.
-* *%b*: This specifier has no equivalent in printf. It creates a bit
+* *%b*: This specifier has no equivalent in printf. It creates a bool
(boolean) type HAL pin. The b should be followed by two characters and
the display will show the first of these when the pin is true, and the
second when false. Note that the characters follow, not precede the "b",
diff --git a/docs/src/man/man9/lineardeltakins.9.adoc b/docs/src/man/man9/lineardeltakins.9.adoc
index 9c1a757bfb3..6e110ba2780 100644
--- a/docs/src/man/man9/lineardeltakins.9.adoc
+++ b/docs/src/man/man9/lineardeltakins.9.adoc
@@ -22,7 +22,7 @@ extruder.
== PINS
-*lineardeltakins.R* float in::
+*lineardeltakins.R* real in::
Effective diameter of the platform.
+
The radius R is different than the distance from the center of the table to the
@@ -31,7 +31,7 @@ RepRap delta parlance, R is DELTA_RADIUS which is computed as
+
DELTA_SMOOTH_ROD_OFFSET - DELTA_EFFECTOR_OFFSET - DELTA_CARRIAGE_OFFSET.
-*lineardeltakins.L* float in::
+*lineardeltakins.L* real in::
Length of the rod connecting the carriage to the effector. In RepRap
delta parlance, L is DELTA_DIAGONAL_ROD.
diff --git a/docs/src/man/man9/matrix_kb.9.adoc b/docs/src/man/man9/matrix_kb.9.adoc
index 47596eb8ec9..0093bade3b9 100644
--- a/docs/src/man/man9/matrix_kb.9.adoc
+++ b/docs/src/man/man9/matrix_kb.9.adoc
@@ -55,23 +55,23 @@ node of the matrix.
== PINS
-**matrix_kb.**_N_**.col-**_CC_**-in** bit in::
+**matrix_kb.**_N_**.col-**_CC_**-in** bool in::
The input pin corresponding to column C.
-**matrix_kb.**_N_**.key.r**_R_**c**_C_ bit out::
+**matrix_kb.**_N_**.key.r**_R_**c**_C_ bool out::
The pin corresponding to the key at row R column C of the matrix.
-**matrix_kb.**_N_**.keycode** unsigned in or out, depending on mode::
+**matrix_kb.**_N_**.keycode** uint in or out, depending on mode::
This pin should be connected to the scancode generator if hardware
such as a 7I73 is being used. In this mode it is an input pin. In the
internally-generated scanning mode this pin is an output, but will not
normally be connected.
-**matrix_kb.**_N_**.row-**_RR_**-out** bit out::
+**matrix_kb.**_N_**.row-**_RR_**-out** bool out::
The row scan drive pins. Should be connected to external hardware pins
connected to the keypad. The row scan drive pins.Should be connected
to external hardware pins connected to the keypad.
== PARAMETERS
-**matrix_kb.**_N_**.key_rollover** unsigned r/w (default 2)::
+**matrix_kb.**_N_**.key_rollover** uint r/w (default 2)::
With most matrix keyboards the scancodes are only unambiguous with 1
or 2 keys pressed. With more keys pressed phantom keystrokes can
appear. Some keyboards are optimised to reduce this problem, and some
@@ -79,7 +79,7 @@ node of the matrix.
simultaneously. Increase the value of this parameter if such a
keyboard is connected, or if phantom keystrokes are more acceptable
than only two keys being active at one time.
-**matrix_kb.**_N_**.negative-logic** bit r/w (default 1), only in scan mode::
+**matrix_kb.**_N_**.negative-logic** bool r/w (default 1), only in scan mode::
When no keys are pressed a typical digital input will float high.
The input will then be pulled low by the keypad when the corresponding poll line is low.
Set this parameter to 0 if the I/O in use requires one row at a time to be high,
diff --git a/docs/src/man/man9/motion.9.adoc b/docs/src/man/man9/motion.9.adoc
index 4d2c1840cb9..176e32450f2 100644
--- a/docs/src/man/man9/motion.9.adoc
+++ b/docs/src/man/man9/motion.9.adoc
@@ -105,47 +105,47 @@ digital pins and two analog pins.
== MOTION PINS
-*motion-command-handler.time* OUT S32::
+*motion-command-handler.time* OUT SINT::
Time (in ns) for the motion module motion-command-handler
-*motion-controller.time* OUT S32::
+*motion-controller.time* OUT SINT::
Time (in ns) for the motion module motion-controller
-*motion.adaptive-feed* IN FLOAT::
+*motion.adaptive-feed* IN REAL::
When adaptive feed is enabled with M52 P1, the commanded velocity is
multiplied by this value. This effect is multiplicative with the
NML-level feed override value and motion.feed-hold. Negative values
are valid and will run the G-code path in reverse.
-**motion.analog-in-**_NN_ IN FLOAT::
+**motion.analog-in-**_NN_ IN REAL::
These pins are used by M66 Enn wait-for-input mode.
-**motion.analog-out-**_NN_ OUT FLOAT::
+**motion.analog-out-**_NN_ OUT REAL::
These pins are used by M67-68.
-*motion.coord-error* OUT BIT::
+*motion.coord-error* OUT BOOL::
TRUE when motion has encountered an error, such as exceeding a soft limit
-*motion.coord-mode* OUT BIT::
+*motion.coord-mode* OUT BOOL::
TRUE when motion is in "coordinated mode", as opposed to "teleop mode"
-*motion.current-vel* OUT FLOAT::
+*motion.current-vel* OUT REAL::
Current cartesian velocity
-**motion.digital-in-**_NN_ IN BIT::
+**motion.digital-in-**_NN_ IN BOOL::
These pins are used by M66 Pnn wait-for-input mode.
-**motion.digital-out-**_NN_ OUT BIT::
+**motion.digital-out-**_NN_ OUT BOOL::
These pins are controlled by the M62 through M65 words.
-*motion.distance-to-go* OUT FLOAT::
+*motion.distance-to-go* OUT REAL::
Distance remaining in the current move
-*motion.enable* IN BIT::
- If this bit is driven FALSE, motion stops, the machine is placed in
+*motion.enable* IN BOOL::
+ If this bool is driven FALSE, motion stops, the machine is placed in
the "machine off" state, and a message is displayed for the operator.
- For normal motion, drive this bit TRUE.
-*motion.eoffset-active* OUT BIT::
+ For normal motion, drive this bool TRUE.
+*motion.eoffset-active* OUT BOOL::
Indicates external offsets are active (non-zero)
-*motion.eoffset-limited* OUT BIT::
+*motion.eoffset-limited* OUT BOOL::
Indicates motion with external offsets was limited by a soft limit
constraint ([AXIS_L]MIN_LIMIT,MAX_LIMIT).
-*motion.feed-hold* IN BIT::
- When Feed Stop Control is enabled with M53 P1, and this bit is TRUE,
+*motion.feed-hold* IN BOOL::
+ When Feed Stop Control is enabled with M53 P1, and this bool is TRUE,
the feed rate is set to 0.
Note: feed-hold applies to G-code commands -- not jogs.
-*motion.feed-inhibit* IN BIT::
+*motion.feed-inhibit* IN BOOL::
When this pin is TRUE, machine motion is inhibited for G-code commands.
If the machine is performing a spindle synchronized move when this pin
@@ -161,7 +161,7 @@ Motion resumes when this pin goes FALSE.
Note: feed-inhibit applies to G-code commands -- not jogs.
-*motion.feed-upm* OUT FLOAT::
+*motion.feed-upm* OUT REAL::
Current feed rate in G-code program units per minute for
motion.motion-type feed(2) and arc(3). Value is the G-code program F
value multiplied by the current feed override value and the
@@ -169,53 +169,53 @@ Note: feed-inhibit applies to G-code commands -- not jogs.
motion.feed-hold or motion.feed-inhibit are asserted. If units (G20 or
G21) are not specified in the G-code file then units will be the last
units used.
-*motion.feed-inches-per-minute* OUT FLOAT::
+*motion.feed-inches-per-minute* OUT REAL::
Current feed rate in inches per minute for motion.motion-type feed(2)
and arc(3). Value is the inch equivalent of the G-code program F value
multiplied by the current feed override value and the
motion.adaptive-feed setting (if M52 active). Value is zero if
motion.feed-hold or motion.feed-inhibit are asserted.
-*motion.feed-inches-per-second* OUT FLOAT::
+*motion.feed-inches-per-second* OUT REAL::
Current feed rate in inches per second for motion.motion-type feed(2)
and arc(3). Value is the inch equivalent of the G-code program F value
multiplied by the current feed override value and the
motion.adaptive-feed setting (if M52 active). Value is zero if
motion.feed-hold or motion.feed-inhibit are asserted.
-*motion.feed-mm-per-minute* OUT FLOAT::
+*motion.feed-mm-per-minute* OUT REAL::
Current feed rate in mm per minute for motion.motion-type feed(2) and arc(3).
Value is the mm equivalent of the G-code program F value multiplied by the
current feed override value and the motion.adaptive-feed setting (if M52 active).
Value is zero if motion.feed-hold or motion.feed-inhibit are asserted.
-*motion.feed-mm-per-second* OUT FLOAT::
+*motion.feed-mm-per-second* OUT REAL::
Current feed rate in mm per second for motion.motion-type feed(2) and arc(3).
Value is the mm equivalent of the G-code program F value multiplied by the current feed override value
and the motion.adaptive-feed setting (if M52 active).
Value is zero if motion.feed-hold or motion.feed-inhibit are asserted.
-*motion.homing-inhibit* IN BIT::
- If this bit is TRUE, initiation of any joint homing move (including "Home All")
+*motion.homing-inhibit* IN BOOL::
+ If this bool is TRUE, initiation of any joint homing move (including "Home All")
is disallowed and an error is reported.
By default, homing is allowed in joint mode whenever motion is enabled.
-*motion.is-all-homed* OUT BIT::
+*motion.is-all-homed* OUT BOOL::
TRUE if all active joints is homed.
-*motion.jog-inhibit* IN BIT::
- If this bit is TRUE, jogging of any joint or axis is disallowed and an error is reported.
-*motion.jog-stop* IN BIT::
+*motion.jog-inhibit* IN BOOL::
+ If this bool is TRUE, jogging of any joint or axis is disallowed and an error is reported.
+*motion.jog-stop* IN BOOL::
If any jog is active when the pin state changes to TRUE then that jog
will be stopped following the associated acceleration values.
-*motion.jog-stop-immediate* IN BIT::
+*motion.jog-stop-immediate* IN BOOL::
If any jog is active when the pin state changes to TRUE then that jog
will be stopped immediately.
-*motion.jog-is-active* OUT BIT::
+*motion.jog-is-active* OUT BOOL::
TRUE if any joint or axis is jogging.
-*motion.in-position* OUT BIT::
+*motion.in-position* OUT BOOL::
TRUE if the machine is in position (i.e., not currently moving towards the commanded position).
-**motion.misc-error-**_NN_ IN BIT::
+**motion.misc-error-**_NN_ IN BOOL::
Extra error inputs for faults such as over-temperature sensors,
low coolant warnings, custom HAL component errors.
If driven TRUE this will disable a machine. Similar to spindle.amp-fault-in.
-*motion.motion-enabled* OUT BIT::
+*motion.motion-enabled* OUT BOOL::
+
-*motion.motion-type* OUT S32::
+*motion.motion-type* OUT SINT::
These values are from src/emc/nml_intf/motion_types.h:
0: Idle (no motion)
@@ -233,24 +233,24 @@ Note: feed-inhibit applies to G-code commands -- not jogs.
6: Rotary unlock for traverse
-*motion.on-soft-limit* OUT BIT::
-*motion.probe-input* IN BIT::
+*motion.on-soft-limit* OUT BOOL::
+*motion.probe-input* IN BOOL::
G38.n uses the value on this pin to determine when the probe has made contact.
TRUE for probe contact closed (touching), FALSE for probe contact open.
-*motion.program-line* OUT S32::
+*motion.program-line* OUT SINT::
The current program line while executing.
Zero if not running or between lines while single stepping.
-*motion.requested-vel* OUT FLOAT::
+*motion.requested-vel* OUT REAL::
The current requested velocity in user units per second.
This value is the F-word setting from the G-code file,
possibly reduced to accommodate machine velocity and acceleration limits.
The value on this pin does not reflect the feed override or any other adjustments.
-*motion.servo.last-period* OUT U32::
+*motion.servo.last-period* OUT UINT::
Time (in ns) between invocations of the servo thread.
Typically, this number divided by the CPU speed gives the time in seconds,
and can be used to determine whether the realtime motion
controller is meeting its timing constraints
-*motion.switchkins-type* IN float::
+*motion.switchkins-type* IN REAL::
Kinematics modules that define the functions kinematicsSwitchable()
and kinematicsSwitch() receive the *integer* value of this pin to
select the machine kinematics functions. Extra G-code commands are
@@ -263,15 +263,15 @@ Note: feed-inhibit applies to G-code commands -- not jogs.
deprecation once, the first time the pin is used to change the
kinematics. The pin is in a grace period: it keeps working for now,
but is meant to be removed in the future.
-*motion.kins-type* OUT float::
+*motion.kins-type* OUT REAL::
The kinematics currently in force, whether it was selected by
*G12.1*, by *G13.1* or from *motion.switchkins-type*. A kinematics
type the module refuses is not reported here.
-*motion.teleop-mode* OUT BIT::
+*motion.teleop-mode* OUT BOOL::
Motion mode is teleop (axis coordinate jogging available).
-*motion.tooloffset.L* OUT FLOAT::
+*motion.tooloffset.L* OUT REAL::
Current tool offset for each axis where (*L* is the axis letter, one of: *x y z a b c u v w*)
-*motion.tp-reverse* OUT BIT::
+*motion.tp-reverse* OUT BOOL::
Trajectory planning is reversed (reverse run)
=== Interpreter Metadata Pins
@@ -280,10 +280,10 @@ These pins provide geometric intent and interpreter state for the segment of mot
==== Interpreter Status Pins
-* `motion.interp.line-number` (s32, out) +
+* `motion.interp.line-number` (sint, out) +
The current G-code line number being executed.
-* `motion.interp.motion-type` (s32, out) +
+* `motion.interp.motion-type` (sint, out) +
The type of motion currently in progress:
** 0: None
** 1: Rapid (G0)
@@ -291,30 +291,30 @@ These pins provide geometric intent and interpreter state for the segment of mot
** 3: Arc (G2, G3)
** 4: Tool Change/Other
-* `motion.interp.feedrate` (float, out) +
+* `motion.interp.feedrate` (real, out) +
The interpreted feedrate for the current segment in units per minute.
==== Interpreter Geometric Pins
-* `motion.interp.heading` (float, out) +
+* `motion.interp.heading` (real, out) +
The XY plane heading of the current linear move in degrees. Measured counter-clockwise from the +X axis (0 to 360). This could be used to control a tangential knife.
-* `motion.interp.arc-radius` (float, out) +
+* `motion.interp.arc-radius` (real, out) +
The radius of the current circular move. This value is 0.0 during linear moves. This could be used to modify plasma cutting parameters based on the arc radius and when hole cutting.
-* `motion.interp.arc-center-x` (float, out) +
+* `motion.interp.arc-center-x` (real, out) +
The absolute X-coordinate of the center point for the current arc. 0 if in YZ plane
-* `motion.interp.arc-center-y` (float, out) +
+* `motion.interp.arc-center-y` (real, out) +
The absolute Y-coordinate of the center point for the current arc. 0 if in XZ plane
-* `motion.interp.arc-center-z` (float, out) +
+* `motion.interp.arc-center-z` (real, out) +
The absolute Y-coordinate of the center point for the current arc if in XZ or YZ plane.
-* `motion.interp.normal-heading` (float, out) +
+* `motion.interp.normal-heading` (real, out) +
the heading from the current point back to the arc centre for the current arc.
- * `motion.interp.iscircle` (bit, out) +
+ * `motion.interp.iscircle` (bool, out) +
True if the current arc is a full circle and not a helix.
[NOTE]
@@ -324,52 +324,52 @@ These pins represent the *commanded geometric intent* from the interpreter and a
(*L* is the axis letter, one of: *x y z a b c u v w*)
-**axis.**_L_**.eoffset** OUT FLOAT::
+**axis.**_L_**.eoffset** OUT REAL::
Current external offset.
-**axis.**_L_**.eoffset-clear** IN BIT::
+**axis.**_L_**.eoffset-clear** IN BOOL::
Clear external offset request
-**axis.**_L_**.eoffset-counts** IN S32::
+**axis.**_L_**.eoffset-counts** IN SINT::
Counts input for external offset. The eoffset-counts are transferred
to an internal register. The applied external offset is the product of
the register counts and the eoffset-scale value. The register is
*reset to zero at each machine startup*. If the machine is turned off
with an external offset active, the eoffset-counts pin should be set
to zero before restarting.
-**axis.**_L_**.eoffset-enable** IN BIT::
+**axis.**_L_**.eoffset-enable** IN BOOL::
Enable for external offset (also requires INI file setting for [AXIS_L]OFFSET_AV_RATIO)
-**axis.**_L_**.eoffset-request** OUT FLOAT::
+**axis.**_L_**.eoffset-request** OUT REAL::
Debug pin for requested external offset.
-**axis.**_L_**.eoffset-scale** IN FLOAT::
+**axis.**_L_**.eoffset-scale** IN REAL::
Scale for external offset.
-**axis.**_L_**.jog-accel-fraction** IN FLOAT::
+**axis.**_L_**.jog-accel-fraction** IN REAL::
Sets acceleration for wheel jogging to a fraction of the INI max_acceleration for the axis.
Values greater than 1 or less than zero are ignored.
-**axis.**_L_**.jog-counts** IN S32::
+**axis.**_L_**.jog-counts** IN SINT::
Connect to the "counts" pin of an external encoder to use a physical jog wheel.
-**axis.**_L_**.jog-enable** IN BIT::
+**axis.**_L_**.jog-enable** IN BOOL::
When TRUE (and in manual mode), any change to "jog-counts" will result in motion.
When false, "jog-counts" is ignored.
-**axis.**_L_**.jog-scale** IN FLOAT::
+**axis.**_L_**.jog-scale** IN REAL::
Sets the distance moved for each count on "jog-counts", in machine units.
-**axis.**_L_**.jog-vel-mode** IN BIT::
+**axis.**_L_**.jog-vel-mode** IN BOOL::
When FALSE (the default), the jogwheel operates in position mode.
The axis will move exactly jog-scale units for each count, regardless of how long that might take.
When TRUE, the wheel operates in velocity mode - motion stops when the wheel stops, even if that means the commanded motion is not completed.
-**axis.**_L_**.kb-jog-active** OUT BIT::
+**axis.**_L_**.kb-jog-active** OUT BOOL::
(free planner axis jogging active (keyboard or halui))
-**axis.**_L_**.pos-cmd** OUT FLOAT::
+**axis.**_L_**.pos-cmd** OUT REAL::
The axis commanded position.
There may be several offsets between the axis and motor coordinates:
Backlash compensation, screw error compensation, and home offsets.
External offsets are reported separately (axis._L_.eoffset).
-**axis.**_L_**.teleop-pos-cmd** OUT FLOAT::
-**axis.**_L_**.teleop-tp-enable** OUT BIT::
+**axis.**_L_**.teleop-pos-cmd** OUT REAL::
+**axis.**_L_**.teleop-tp-enable** OUT BOOL::
TRUE when the "teleop planner" is enabled for this axis.
-**axis.**_L_**.teleop-vel-cmd** OUT FLOAT::
+**axis.**_L_**.teleop-vel-cmd** OUT REAL::
The axis's commanded velocity.
-**axis.**_L_**.teleop-vel-lim** OUT FLOAT::
+**axis.**_L_**.teleop-vel-lim** OUT REAL::
The velocity limit for the teleop planner.
-**axis.**_L_**.wheel-jog-active** OUT BIT::
+**axis.**_L_**.wheel-jog-active** OUT BOOL::
+
== JOINT PINS
@@ -378,97 +378,97 @@ _N_ is the joint number (0 ... _num_joints_-1))
Note: Pins marked *(DEBUG)* serve as debugging aids and are subject to change or removal at any time.
-**joint.**_N_**.acc-cmd** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.acc-cmd** OUT REAL *(DEBUG)*::
The joint's commanded acceleration.
-**joint.**_N_**.active** OUT BIT *(DEBUG)*::
+**joint.**_N_**.active** OUT BOOL *(DEBUG)*::
TRUE when this joint is active.
-**joint.**_N_**.amp-enable-out** OUT BIT::
+**joint.**_N_**.amp-enable-out** OUT BOOL::
TRUE if the amplifier for this joint should be enabled.
-**joint.**_N_**.amp-fault-in** IN BIT::
+**joint.**_N_**.amp-fault-in** IN BOOL::
Should be driven TRUE if an external fault is detected with the amplifier for this joint.
-**joint.**_N_**.backlash-corr** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.backlash-corr** OUT REAL *(DEBUG)*::
Backlash or screw compensation raw value.
-**joint.**_N_**.backlash-filt** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.backlash-filt** OUT REAL *(DEBUG)*::
Backlash or screw compensation filtered value (respecting motion limits).
-**joint.**_N_**.backlash-vel** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.backlash-vel** OUT REAL *(DEBUG)*::
Backlash or screw compensation velocity.
-**joint.**_N_**.coarse-pos-cmd** OUT FLOAT *(DEBUG)*::
-**joint.**_N_**.error** OUT BIT *(DEBUG)*::
+**joint.**_N_**.coarse-pos-cmd** OUT REAL *(DEBUG)*::
+**joint.**_N_**.error** OUT BOOL *(DEBUG)*::
TRUE when t*his joint has encountered an error, such as a limit switch closing.
-**joint.**_N_**.f-error** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.f-error** OUT REAL *(DEBUG)*::
The actual following error.
-**joint.**_N_**.f-error-lim** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.f-error-lim** OUT REAL *(DEBUG)*::
The following error limit.
-**joint.**_N_**.f-errored** OUT BIT *(DEBUG)*::
+**joint.**_N_**.f-errored** OUT BOOL *(DEBUG)*::
TRUE when this joint has exceeded the following error limit.
-**joint.**_N_**.faulted** OUT BIT *(DEBUG)*::
-**joint.**_N_**.free-pos-cmd** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.faulted** OUT BOOL *(DEBUG)*::
+**joint.**_N_**.free-pos-cmd** OUT REAL *(DEBUG)*::
The "free planner" commanded position for this joint.
-**joint.**_N_**.free-tp-enable** OUT BIT *(DEBUG)*::
+**joint.**_N_**.free-tp-enable** OUT BOOL *(DEBUG)*::
TRUE when the "free planner" is enabled for this joint.
-**joint.**_N_**.free-vel-lim** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.free-vel-lim** OUT REAL *(DEBUG)*::
The velocity limit for the free planner.
-**joint.**_N_**.home-state** OUT S32 *(DEBUG)*::
+**joint.**_N_**.home-state** OUT SINT *(DEBUG)*::
homing state machine state
-**joint.**_N_**.home-sw-in** IN BIT::
+**joint.**_N_**.home-sw-in** IN BOOL::
Should be driven TRUE if the home switch for this joint is closed.
-**joint.**_N_**.homed** OUT BIT *(DEBUG)*::
+**joint.**_N_**.homed** OUT BOOL *(DEBUG)*::
TRUE if the joint has been homed.
-**joint.**_N_**.homing** OUT BIT::
+**joint.**_N_**.homing** OUT BOOL::
TRUE if the joint is currently homing.
-**joint.**_N_**.in-position** OUT BIT *(DEBUG)*::
+**joint.**_N_**.in-position** OUT BOOL *(DEBUG)*::
TRUE if the joint is using the "free planner" and has come to a stop.
-**joint.**_N_**.index-enable** IO BIT::
+**joint.**_N_**.index-enable** IO BOOL::
Should be attached to the index-enable pin of the joint's encoder to enable homing to index pulse.
-**joint.**_N_**.is-unlocked** IN BIT::
+**joint.**_N_**.is-unlocked** IN BOOL::
Indicates joint is unlocked (see JOINT UNLOCK PINS).
-**joint.**_N_**.jog-accel-fraction** IN FLOAT::
+**joint.**_N_**.jog-accel-fraction** IN REAL::
Sets acceleration for wheel jogging to a fraction of the INI max_acceleration for the joint.
Values greater than 1 or less than zero are ignored.
-**joint.**_N_**.jog-counts** IN S32::
+**joint.**_N_**.jog-counts** IN SINT::
Connect to the "counts" pin of an external encoder to use a physical jog wheel.
-**joint.**_N_**.jog-enable** IN BIT::
+**joint.**_N_**.jog-enable** IN BOOL::
When TRUE (and in manual mode), any change to "jog-counts" will result in motion.
When false, "jog-counts" is ignored.
-**joint.**_N_**.jog-scale** IN FLOAT::
+**joint.**_N_**.jog-scale** IN REAL::
Sets the distance moved for each count on "jog-counts", in machine units.
-**joint.**_N_**.jog-vel-mode** IN BIT::
+**joint.**_N_**.jog-vel-mode** IN BOOL::
When FALSE (the default), the jogwheel operates in position mode.
The joint will move exactly jog-scale units for each count, regardless of how long that might take.
When TRUE, the wheel operates in velocity mode - motion stops when the wheel stops, even if that means the commanded motion is not completed.
-**joint.**_N_**.kb-jog-active** OUT BIT *(DEBUG)*::
+**joint.**_N_**.kb-jog-active** OUT BOOL *(DEBUG)*::
(free planner joint jogging active (keyboard or halui))
-**joint.**_N_**.motor-offset** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.motor-offset** OUT REAL *(DEBUG)*::
joint motor offset established when joint is homed.
-**joint.**_N_**.motor-pos-cmd** OUT FLOAT::
+**joint.**_N_**.motor-pos-cmd** OUT REAL::
The commanded position for this joint.
-**joint.**_N_**.motor-pos-fb** IN FLOAT::
+**joint.**_N_**.motor-pos-fb** IN REAL::
The actual position for this joint.
-**joint.**_N_**.neg-hard-limit** OUT BIT *(DEBUG)*::
+**joint.**_N_**.neg-hard-limit** OUT BOOL *(DEBUG)*::
The negative hard limit for the joint
-**joint.**_N_**.neg-lim-sw-in** IN BIT::
+**joint.**_N_**.neg-lim-sw-in** IN BOOL::
Should be driven TRUE if the negative limit switch for this joint is tripped.
-**joint.**_N_**.pos-cmd** OUT FLOAT::
+**joint.**_N_**.pos-cmd** OUT REAL::
The joint (as opposed to motor) commanded position. There may be
several offsets between the joint and motor coordinates: backlash
compensation, screw error compensation, and home offsets.
-**joint.**_N_**.pos-fb** OUT FLOAT::
+**joint.**_N_**.pos-fb** OUT REAL::
The joint feedback position. This value is computed from the actual
motor position minus joint offsets. Useful for machine visualization.
-**joint.**_N_**.pos-hard-limit** OUT BIT *(DEBUG)*::
+**joint.**_N_**.pos-hard-limit** OUT BOOL *(DEBUG)*::
The positive hard limit for the joint.
-**joint.**_N_**.pos-lim-sw-in** IN BIT::
+**joint.**_N_**.pos-lim-sw-in** IN BOOL::
Should be driven TRUE if the positive limit switch for this joint is tripped.
-**joint.**_N_**.unlock** OUT BIT::
+**joint.**_N_**.unlock** OUT BOOL::
TRUE if the axis is a locked joint (typically a rotary) and a move is
commanded (see JOINT UNLOCK PINS).
-**joint.**_N_**.vel-cmd** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.vel-cmd** OUT REAL *(DEBUG)*::
The joint's commanded velocity.
-**joint.**_N_**.jerk-cmd** OUT FLOAT *(DEBUG)*::
+**joint.**_N_**.jerk-cmd** OUT REAL *(DEBUG)*::
The joint's commanded jerk (rate of change of acceleration).
Only active when S-curve trajectory planning is enabled (INI file [TRAJ]PLANNER_TYPE=1 and [TRAJ]MAX_LINEAR_JERK>0).
Jerk limits are set via INI file [JOINT_N]MAX_JERK or via the ini.N.max_jerk HAL pin.
-**joint.**_N_**.wheel-jog-active** OUT BIT *(DEBUG)*::
+**joint.**_N_**.wheel-jog-active** OUT BOOL *(DEBUG)*::
+
== JOINT posthome pins
@@ -491,78 +491,78 @@ Example: loadrt motmod ... **unlock_joints_mask=**0x38 creates unlock pins for j
(_M_ is the spindle number (*0* ... *num_spindles-1*))
-**spindle.**_M_**.amp-fault-in** IN BIT::
+**spindle.**_M_**.amp-fault-in** IN BOOL::
Should be driven TRUE if an external fault is detected with the amplifier for this spindle.
-**spindle.**_M_**.at-speed** IN BIT::
+**spindle.**_M_**.at-speed** IN BOOL::
Motion will pause until this pin is TRUE, under the following conditions:
Before the first feed move after each spindle start or speed change;
before the start of every chain of spindle-synchronized moves;
and if in CSS mode, at every rapid->feed transition.
-**spindle.**_M_**.brake** OUT BIT::
+**spindle.**_M_**.brake** OUT BOOL::
TRUE when the spindle brake should be applied.
-**spindle.**_M_**.forward** OUT BIT::
+**spindle.**_M_**.forward** OUT BOOL::
TRUE when the spindle should rotate forward.
-**spindle.**_M_**.index-enable** I/O BIT::
+**spindle.**_M_**.index-enable** IO BOOL::
For correct operation of spindle synchronized moves, this signal must
be hooked to the index-enable pin of the spindle encoder.
-**spindle.**_M_**.inhibit** IN BIT::
+**spindle.**_M_**.inhibit** IN BOOL::
When TRUE, the spindle speed is set and held to 0.
-**spindle.**_M_**.is-oriented** IN BIT::
+**spindle.**_M_**.is-oriented** IN BOOL::
Acknowledge pin for spindle-orient. Completes orient cycle.
If spindle-orient was true when spindle-is-oriented was asserted,
the spindle-orient pin is cleared and the spindle-locked pin is asserted.
Also, the spindle-brake pin is asserted.
-**spindle.**_M_**.locked** OUT BIT::
+**spindle.**_M_**.locked** OUT BOOL::
Spindle orient complete pin. Cleared by any of M3, M4 or M5.
-**spindle.**_M_**.on** OUT BIT::
+**spindle.**_M_**.on** OUT BOOL::
TRUE when spindle should rotate.
-**spindle.**_M_**.orient** OUT BIT::
+**spindle.**_M_**.orient** OUT BOOL::
Indicates start of spindle orient cycle.
Set by M19. Cleared by any of M3, M4 or M5.
If spindle-orient-fault is not zero during spindle-orient true,
the M19 command fails with an error message.
-**spindle.**_M_**.orient-angle** OUT FLOAT::
+**spindle.**_M_**.orient-angle** OUT REAL::
Desired spindle orientation for M19. Value of the M19 R word parameter
plus the value of the [RS274NGC]ORIENT_OFFSET INI parameter.
-**spindle.**_M_**.orient-fault** IN S32::
+**spindle.**_M_**.orient-fault** IN SINT::
Fault code input for orient cycle.
Any value other than zero will cause the orient cycle to abort.
-**spindle.**_M_**.orient-mode** OUT BIT::
+**spindle.**_M_**.orient-mode** OUT BOOL::
Desired spindle rotation mode. Reflects M19 P parameter word.
-**spindle.**_M_**.reverse** OUT BIT::
+**spindle.**_M_**.reverse** OUT BOOL::
TRUE when the spindle should rotate backward.
-**spindle.**_M_**.revs** IN FLOAT::
+**spindle.**_M_**.revs** IN REAL::
For correct operation of spindle synchronized moves, this signal must
be hooked to the position pin of the spindle encoder.
-**spindle.**_M_**.speed-cmd-rps** FLOAT OUT::
+**spindle.**_M_**.speed-cmd-rps** OUT REAL::
Commanded spindle speed in units of revolutions per second.
-**spindle.**_M_**.speed-in** IN FLOAT::
+**spindle.**_M_**.speed-in** IN REAL::
Actual spindle speed feedback in revolutions per second; used for G96
(constant surface speed) and G95 (feed per revolution) modes.
-**spindle.**_M_**.speed-out** OUT FLOAT::
+**spindle.**_M_**.speed-out** OUT REAL::
Desired spindle speed in rotations per minute.
-**spindle.**_M_**.speed-out-abs** OUT FLOAT::
+**spindle.**_M_**.speed-out-abs** OUT REAL::
Desired spindle speed in rotations per minute, always positive regardless of spindle direction.
-**spindle.**_M_**.speed-out-rps** OUT FLOAT::
+**spindle.**_M_**.speed-out-rps** OUT REAL::
Desired spindle speed in rotations per second.
-**spindle.**_M_**.speed-out-rps-abs** OUT FLOAT::
+**spindle.**_M_**.speed-out-rps-abs** OUT REAL::
Desired spindle speed in rotations per second, always positive regardless of spindle direction.
== MOTION PARAMETERS
Many of the parameters serve as debugging aids, and are subject to change or removal at any time.
-*motion-command-handler.tmax* RW S32::
+*motion-command-handler.tmax* RW SINT::
Show information about the execution time of these HAL functions in ns.
-*motion-command-handler.tmax-increased* RO BIT::
+*motion-command-handler.tmax-increased* RO BOOL::
-*motion-controller.tmax* RW S32::
+*motion-controller.tmax* RW SINT::
Show information about the execution time of these HAL functions in ns.
-*motion-controller.tmax-increased* RO BIT::
+*motion-controller.tmax-increased* RO BOOL::
+
**motion.debug-**_*_::
diff --git a/docs/src/man/man9/mux_generic.9.adoc b/docs/src/man/man9/mux_generic.9.adoc
index 16f28d729c9..e02b068aa7f 100644
--- a/docs/src/man/man9/mux_generic.9.adoc
+++ b/docs/src/man/man9/mux_generic.9.adoc
@@ -8,13 +8,13 @@ mux_generic - select one from several inputs and forwards it to a single output
**loadrt mux_generic config="**____[,____],...**"**
-Types: **b** = bit, **f** = float, **s** = signed integer, **u** = unsigned integer
+Types: **b** = bool, **f** = real, **s** = sint, **u** = uint
Example: **loadrt mux_generic config="**bb8,fu12**"**
== FUNCTIONS
-**mux-gen.**_NN_ Depending on the data types can run in either a floating point or non-floating point thread.
+**mux-gen.**_NN_ Multiplexer function.
== PINS
@@ -23,23 +23,23 @@ Example: **loadrt mux_generic config="**bb8,fu12**"**
mux-gen.NN.sel-bit-BB ───────────────┐ │ │
mux-gen.NN.sel-int ─────────────┐ │ │ │
┌───────┴─┴─┴─┴───────┐
-mux-gen.NN.in-[bit/float/s32/u32]-00 ─────┤ ─────o \ │
- ... ─────┤ ─────o o───── ├───── mux-gen.NN.out-[bit/float/s32/u32]
-mux-gen.NN.in-[bit/float/s32/u32]-MM ─────┤ ─────o │
+mux-gen.NN.in-[bool/real/sint/uint]-00 ───┤ ─────o \ │
+ ... ─────┤ ─────o o───── ├───── mux-gen.NN.out-[bool/real/sint/uint]
+mux-gen.NN.in-[bool/real/sint/uint]-MM ───┤ ─────o │
│ │
mux-gen.NN.suppress-no-input ─────┤ │
mux-gen.NN.debounce-us ─────┤ │
└─────────────────────┘
-**mux-gen**.__N__.**suppress-no-input** bit in::
+**mux-gen**.__N__.**suppress-no-input** bool in::
This suppresses changing the output if all select lines are false.
This stops unwanted jumps in output between transitions of input but makes in00 unavailable.
-**mux-gen**.__N__.**debounce-us** unsigned in::
+**mux-gen**.__N__.**debounce-us** uint in::
sets debounce time in microseconds, e.g. 100000 = a tenth of a second.
The selection inputs must be stable this long before the output
changes. This helps to ignore 'noisy' switches.
**mux-gen**.__N__.**sel-bit-**__BB__ bit in (BB=0..bit width of _size_)::
-**mux-gen**.__N__.**sel-int** unsigned in::
+**mux-gen**.__N__.**sel-int** uint in::
Together, these determine which **in**__M__ value is copied to *output*.
The bit pins are interpreted as binary bits, and the result is simply
added on to the integer pin input. It is expected that either one or
@@ -49,20 +49,19 @@ mux-gen.NN.in-[bit/float/s32/u32]-MM ─────┤ ─────o
component is an integer power of two. This component (unlike mux16)
does not offer the option of decoding Gray-code, however the same
effect can be achieved by arranging the order of the input values to suit.
-**mux-gen**.__N__.**in-**[**bit**/**float**/**s32**/**u32**]**-**__MM__ variable-type in::
+**mux-gen**.__N__.**in-**[**bool**/**real**/**sint**/**uint**]**-**__MM__ variable-type in::
The possible output values that are selected by the selection pins.
-**mux-gen**.__N__.**out-**[**bit**/**float**/**s32**/**u32**] variable-type out::
+**mux-gen**.__N__.**out-**[**real**/**real**/**sint**/**uint**] variable-type out::
Follows the value of one of the **in**__N__ values according to the
selection bits and/or the selection number. Values will be
- converted/truncated according to standard C rules. This means, for
- example that a float input greater than 2147483647 will give an S32
- output of -2147483648.
+ converted and clamped. This means, for example that a REAL input greater
+ than (approx.) 2^63^-1 will give a SINT output of 2^63^-1.
== PARAMETERS
-**mux-gen**.__N__.**elapsed** float r::
+**mux-gen**.__N__.**elapsed** real r::
Current value of the internal debounce timer for debugging.
-**mux-gen**.__N__.**selected** s32 r::
+**mux-gen**.__N__.**selected** sint r::
Current value of the internal selection variable after conversion for debugging.
Possibly useful for setting up gray-code switches.
@@ -73,20 +72,16 @@ components. It allows the creation of arbitrary-size multiplexers (up to
1024 entries) and also supports differing data types on the input and
output pins. The configuration string is a comma-separated list of
code-letters and numbers, such as "bb4,fu12". This would create a
-4-element bit-to-bit mux and a 12-element float-to-unsigned mux. The
-code letters are **b** = bit, **f** = float, **s** = signed integer, **u** = unsigned
+4-element bit-to-bit mux and a 12-element real-to-uint mux. The
+code letters are **b** = bool, **f** = real, **s** = sint, **u** = uint
integer. The first letter code is the input type, the second is the
output type. The codes are not case-sensitive. The order of the letters
is significant but the position in the string is not. Do not insert any
-spaces in the config string. Any non-zero float value will be converted
-to a "true" output in bit form. Be wary that float datatypes can be
-very, very, close to zero and not actually be equal to zero.
+spaces in the config string. Any non-zero real value will be converted
+to a "true" output in bool form when it is more than ±2e-7 from zero.
Each mux has its own HAL function and must be added to a thread
-separately. If neither input nor output is of type float then the
-function is base-thread (non floating-point) safe. Any mux_generic with
-a floating point input or output can only be added to a floating-point
-thread.
+separately.
== SEE ALSO
diff --git a/docs/src/man/man9/pid.9.adoc b/docs/src/man/man9/pid.9.adoc
index 7a148cd8923..5ae8a02315b 100644
--- a/docs/src/man/man9/pid.9.adoc
+++ b/docs/src/man/man9/pid.9.adoc
@@ -42,7 +42,7 @@ the feedback match the command. As such, for a position loop 'output' is
a velocity, in inches/sec, mm/sec, degrees/sec, etc.
Each loop has several other pins as well. 'error' is equal to 'command'
-minus 'feedback'. 'enable' is a bit that enables the loop. If 'enable'
+minus 'feedback'. 'enable' is a bool that enables the loop. If 'enable'
is false, all integrators are reset, and the output is forced to zero.
If 'enable' is true, the loop operates normally.
@@ -167,50 +167,50 @@ The *pid.N.* format is shown in the following descriptions.
== PINS
-**pid.**_N_**.command** float in::
+**pid.**_N_**.command** real in::
The desired (commanded) value for the control loop.
-**pid.**_N_**.Pgain** float in::
+**pid.**_N_**.Pgain** real in::
Proportional gain. Results in a contribution to the output that is the
error multiplied by *Pgain*.
-**pid.**_N_**.Igain** float in::
+**pid.**_N_**.Igain** real in::
Integral gain. Results in a contribution to the output that is the
integral of the error multiplied by *Igain*. For example an error of
0.02 that lasted 10 seconds would result in an integrated error
(*errorI*) of 0.2, and if *Igain* is 20, the integral term would add
4.0 to the output.
-**pid.**_N_**.Dgain** float in::
+**pid.**_N_**.Dgain** real in::
Derivative gain. Results in a contribution to the output that is the
rate of change (derivative) of the error multiplied by *Dgain*. For
example an error that changed from 0.02 to 0.03 over 0.2 seconds would
result in an error derivative (*errorD*) of of 0.05, and if *Dgain* is
5, the derivative term would add 0.25 to the output.
-**pid.**_N_**.feedback** float in::
+**pid.**_N_**.feedback** real in::
The actual (feedback) value, from some sensor such as an encoder.
-**pid.**_N_**.output** float out::
+**pid.**_N_**.output** real out::
The output of the PID loop, which goes to some actuator such as a
motor.
-**pid.**_N_**.command-deriv** float in::
+**pid.**_N_**.command-deriv** real in::
The derivative of the desired (commanded) value for the control loop.
If no signal is connected then the derivative will be estimated
numerically.
-**pid.**_N_**.feedback-deriv** float in::
+**pid.**_N_**.feedback-deriv** real in::
The derivative of the actual (feedback) value for the control loop. If
no signal is connected then the derivative will be estimated
numerically. When the feedback is from a quantized position source
(e.g., encoder feedback position), behavior of the D term can be
improved by using a better velocity estimate here, such as the
velocity output of encoder(9) or hostmot2(9).
-**pid.**_N_**.error-previous-target** bit in::
+**pid.**_N_**.error-previous-target** bool in::
Use previous invocation's target vs. current position for error
calculation, like the motion controller expects. This may make
torque-mode position loops and loops requiring a large I gain easier
to tune, by eliminating velocity-dependent following error.
-**pid.**_N_**.error** float out::
+**pid.**_N_**.error** real out::
The difference between command and feedback.
-**pid.**_N_**.enable** bit in::
+**pid.**_N_**.enable** bool in::
When true, enables the PID calculations. When false, *output* is zero,
and all internal integrators, etc, are reset.
-**pid.**_N_**.index-enable** bit in::
+**pid.**_N_**.index-enable** bool in::
On the falling edge of *index-enable*, pid does not update the
internal command derivative estimate. On systems which use the encoder
index pulse, this pin should be connected to the index-enable signal.
@@ -218,7 +218,7 @@ The *pid.N.* format is shown in the following descriptions.
command causes a single-cycle spike in the PID output. On systems
which use exactly one of the *-deriv* inputs, this affects the D term
as well.
-**pid.**_N_**.bias** float in::
+**pid.**_N_**.bias** real in::
*bias* is a constant amount that is added to the output. In most cases
it should be left at zero. However, it can sometimes be useful to
compensate for offsets in servo amplifiers, or to balance the weight
@@ -226,34 +226,34 @@ The *pid.N.* format is shown in the following descriptions.
loop is disabled, just like all other components of the output. If a
non-zero output is needed even when the PID loop is disabled, it
should be added with an external HAL sum2 block.
-**pid.**_N_**.FF0** float in::
+**pid.**_N_**.FF0** real in::
Zero order feed-forward term. Produces a contribution to the output
that is *FF0* multiplied by the commanded value. For position loops,
it should usually be left at zero. For velocity loops, *FF0* can
compensate for friction or motor counter-EMF and may permit better
tuning if used properly.
-**pid.**_N_**.FF1** float in::
+**pid.**_N_**.FF1** real in::
First order feed-forward term. Produces a contribution to the output
that is *FF1* multiplied by the derivative of the commanded value. For
position loops, the contribution is proportional to speed, and can be
used to compensate for friction or motor CEMF. For velocity loops, it
is proportional to acceleration and can compensate for inertia. In
both cases, it can result in better tuning if used properly.
-**pid.**_N_**.FF2** float in::
+**pid.**_N_**.FF2** real in::
Second order feed-forward term. Produces a contribution to the output
that is *FF2* multiplied by the second derivative of the commanded
value. For position loops, the contribution is proportional to
acceleration, and can be used to compensate for inertia. For velocity
loops, the contribution is proportional to jerk, and should usually be
left at zero.
-**pid.**_N_**.FF3** float in::
+**pid.**_N_**.FF3** real in::
Third order feed-forward term. Produces a contribution to the output
that is *FF3* multiplied by the third derivative of the commanded
value. For position loops, the contribution is proportional to jerk,
and can be used to compensate for residual errors during acceleration.
For velocity loops, the contribution is proportional to snap(jounce),
and should usually be left at zero.
-**pid.**_N_**.deadband** float in::
+**pid.**_N_**.deadband** real in::
Defines a range of "acceptable" error. If the absolute value of
*error* is less than *deadband*, it will be treated as if the error is
zero. When using feedback devices such as encoders that are inherently
@@ -264,95 +264,95 @@ The *pid.N.* format is shown in the following descriptions.
subtracted from the error before performing the loop calculations, to
prevent a step in the transfer function at the edge of the deadband
(see *BUGS*).
-**pid.**_N_**.maxoutput** float in::
+**pid.**_N_**.maxoutput** real in::
Output limit. The absolute value of the output will not be permitted
to exceed *maxoutput*, unless *maxoutput* is zero. When the output is
limited, the error integrator will hold instead of integrating, to
prevent windup and overshoot.
-**pid.**_N_**.maxerror** float in::
+**pid.**_N_**.maxerror** real in::
Limit on the internal error variable used for P, I, and D. Can be used
to prevent high *Pgain* values from generating large outputs under
conditions when the error is large (for example, when the command
makes a step change). Not normally needed, but can be useful when
tuning non-linear systems.
-**pid.**_N_**.maxerrorD** float in::
+**pid.**_N_**.maxerrorD** real in::
Limit on the error derivative. The rate of change of error used by the
*Dgain* term will be limited to this value, unless the value is zero.
Can be used to limit the effect of *Dgain* and prevent large output
spikes due to steps on the command and/or feedback. Not normally needed.
-**pid.**_N_**.maxerrorI** float in::
+**pid.**_N_**.maxerrorI** real in::
Limit on error integrator. The error integrator used by the *Igain*
term will be limited to this value, unless it is zero. Can be used to
prevent integrator windup and the resulting overshoot during/after
sustained errors. Not normally needed.
-**pid.**_N_**.maxcmdD** float in::
+**pid.**_N_**.maxcmdD** real in::
Limit on command derivative. The command derivative used by *FF1* will
be limited to this value, unless the value is zero. Can be used to
prevent *FF1* from producing large output spikes if there is a step
change on the command. Not normally needed.
-**pid.**_N_**.maxcmdDD** float in::
+**pid.**_N_**.maxcmdDD** real in::
Limit on command second derivative. The command second derivative used
by *FF2* will be limited to this value, unless the value is zero. Can
be used to prevent *FF2* from producing large output spikes if there
is a step change on the command. Not normally needed.
-**pid.**_N_**.maxcmdDDD** float in::
+**pid.**_N_**.maxcmdDDD** real in::
Limit on command third derivative. The command third derivative used
by *FF3* will be limited to this value, unless the value is zero. Can
be used to prevent *FF3* from producing large output spikes if there
is a step change on the command. Not normally needed.
-**pid.**_N_**.saturated** bit out::
+**pid.**_N_**.saturated** bool out::
When true, the current PID output is saturated. That is,
+
*output* = ± *maxoutput*.
-**pid.**_N_**.saturated-s** float out::
+**pid.**_N_**.saturated-s** real out::
-**pid.**_N_**.saturated-count** s32 out::
+**pid.**_N_**.saturated-count** sint out::
When true, the output of PID was continually saturated for this many
seconds (*saturated-s*) or periods (*saturated-count*).
=== Additional auto tuning pins
-**pid.**_N_**.tune-mode** bit in::
+**pid.**_N_**.tune-mode** bool in::
When true, enables auto tune mode. When false, normal PID calculations are performed.
-**pid.**_N_**.tune-start** bit io::
+**pid.**_N_**.tune-start** bool io::
When set to true, starts auto tuning. Cleared when the auto tuning completes.
-**pid.**_N_**.tune-type* u32 rw::
+**pid.**_N_**.tune-type** uint rw::
When set to 0, *Pgain/Igain/Dgain* are calculated. When set to 1, *Pgain/Igain/FF1* are calculated.
-**pid.**_N_**.tune-cycles** u32 rw::
+**pid.**_N_**.tune-cycles** uint rw::
Determines the number of cycles to run to characterize the process.
*tune-cycles* actually sets the number of half cycles. More cycles
results in a more accurate characterization as the average of all
cycles is used.
-**pid.**_N_**.tune-effort** float rw::
+**pid.**_N_**.tune-effort** real rw::
The maximum output value used during automatic tuning. Determines the
effort used in setting up the limit cycle in the process.
*tune-effort* should be set to a positive value less than *maxoutput*.
Start with something small and work up to a value that results in a
good portion of the maximum motor current being used. The smaller the
value, the smaller the amplitude of the limit cycle.
-**pid.**_N_**.ultimate-gain** float ro (only if debug=1)::
+**pid.**_N_**.ultimate-gain** real ro (only if debug=1)::
Determined from process characterization. *ultimate-gain* is the ratio
of *tune-effort* to the limit cycle amplitude multiplied by 4.0
divided by Pi.
-**pid.**_N_**.ultimate-period** float ro (only if debug=1)::
+**pid.**_N_**.ultimate-period** real ro (only if debug=1)::
Determined from process characterization. *ultimate-period* is the
period of the limit cycle.
== PARAMETERS
-**pid.**_N_**.errorI** float ro (only if debug=1)::
+**pid.**_N_**.errorI** real ro (only if debug=1)::
Integral of error. This is the value that is multiplied by *Igain* to
produce the Integral term of the output.
-**pid.**_N_**.errorD** float ro (only if debug=1)::
+**pid.**_N_**.errorD** real ro (only if debug=1)::
Derivative of error. This is the value that is multiplied by *Dgain*
to produce the Derivative term of the output.
-**pid.**_N_**.commandD** float ro (only if debug=1)::
+**pid.**_N_**.commandD** real ro (only if debug=1)::
Derivative of command. This is the value that is multiplied by *FF1*
to produce the first order feed-forward term of the output.
-**pid.**_N_**.commandDD** float ro (only if debug=1)::
+**pid.**_N_**.commandDD** real ro (only if debug=1)::
Second derivative of command. This is the value that is multiplied by
*FF2* to produce the second order feed-forward term of the output.
-**pid.**_N_**.commandDDD** float ro (only if debug=1)::
+**pid.**_N_**.commandDDD** real ro (only if debug=1)::
Third derivative of command. This is the value that is multiplied by
*FF3* to produce the third order feed-forward term of the output.
diff --git a/docs/src/man/man9/pwmgen.9.adoc b/docs/src/man/man9/pwmgen.9.adoc
index 7eead2af2a4..981d7bb3b5a 100644
--- a/docs/src/man/man9/pwmgen.9.adoc
+++ b/docs/src/man/man9/pwmgen.9.adoc
@@ -49,43 +49,43 @@ type 2: up/down::
== PINS
-**pwmgen.**_N_**.enable** bit in::
+**pwmgen.**_N_**.enable** bool in::
Enables PWM generator _N_ - when false, all **pwmgen.**_N_ output pins are low.
-**pwmgen.**_N_**.value** float in::
+**pwmgen.**_N_**.value** real in::
Commanded value. When *value* = 0.0, duty cycle is 0%, and when
*value* = ±**scale**, duty cycle is ± 100% (subject to *min-dc* and
*max-dc* limitations).
-**pwmgen.**_N_**.pwm* bit out (output types 0 and 1 only)::
+**pwmgen.**_N_**.pwm** bool out (output types 0 and 1 only)::
PWM/PDM waveform.
-**pwmgen.**_N_**.dir** bit out (output type 1 only)::
+**pwmgen.**_N_**.dir** bool out (output type 1 only)::
Direction output: low for forward, high for reverse.
-**pwmgen.**_N_**.up** bit out (output type 2 only)::
+**pwmgen.**_N_**.up** bool out (output type 2 only)::
PWM/PDM waveform for positive input values, low for negative inputs.
-**pwmgen.**_N_**.down** bit out (output type 2 only)::
+**pwmgen.**_N_**.down** bool out (output type 2 only)::
PWM/PDM waveform for negative input values, low for positive inputs.
-**pwmgen.**_N_**.curr-dc** float out::
+**pwmgen.**_N_**.curr-dc** real out::
The current duty cycle, after all scaling and limits have been applied.
Range is from -1.0 to +1.0.
-**pwmgen.**_N_**.max-dc** float in/out::
+**pwmgen.**_N_**.max-dc** real in/out::
The maximum duty cycle. A value of 1.0 corresponds to 100%.
This can be useful when using transistor drivers with bootstrapped power supplies,
since the supply requires some low time to recharge.
-**pwmgen.**_N_**.min-dc** float in/out::
+**pwmgen.**_N_**.min-dc** real in/out::
The minimum duty cycle. A value of 1.0 corresponds to 100%.
Note that when the pwm generator is disabled, the outputs are constantly low,
regardless of the setting of *min-dc*.
-**pwmgen.**_N_**.scale** float in/out::
+**pwmgen.**_N_**.scale** real in/out::
-**pwmgen.**_N_**.offset** float in/out::
+**pwmgen.**_N_**.offset** real in/out::
These parameters provide a scale and offset from the *value* pin to the actual duty cycle.
The duty cycle is calculated according to _dc = (value/scale) + offset_, with 1.0 meaning 100%.
-**pwmgen.**_N_**.pwm-freq** float in/out::
+**pwmgen.**_N_**.pwm-freq** real in/out::
PWM frequency in Hz. The upper limit is half of the frequency at which
*make-pulses* is invoked, and values above that limit will be changed to the limit.
If *dither-pwm* is false, the value will be changed to
the nearest integer submultiple of the *make-pulses* frequency.
A value of zero produces Pulse Density Modulation instead of Pulse Width Modulation.
-**pwmgen.**_N_**.dither-pwm** bit in/out::
+**pwmgen.**_N_**.dither-pwm** bool in/out::
Because software-generated PWM uses a fairly slow timebase (several to
many microseconds), it has limited resolution. For example, if
*make-pulses* is called at a 20 kHz rate, and *pwm-freq* is 2 kHz,
@@ -95,4 +95,4 @@ type 2: up/down::
PWM cycle. If *dither-pwm* is true, the output duty cycle will be
dithered between the two closest values, so that the long-term average
is closer to the desired level. *dither-pwm* has no effect if
- *pwm-freq* is zero (PDM mode), since PDM is an inherently dithered process.
\ No newline at end of file
+ *pwm-freq* is zero (PDM mode), since PDM is an inherently dithered process.
diff --git a/docs/src/man/man9/rosekins.9.adoc b/docs/src/man/man9/rosekins.9.adoc
index f9c38fcd225..d60a029b6f5 100644
--- a/docs/src/man/man9/rosekins.9.adoc
+++ b/docs/src/man/man9/rosekins.9.adoc
@@ -17,12 +17,12 @@ spindle (workholding, not tool holding, e.g. not a highspeed spindle)
== PINS
-*rosekins.revolutions* float out::
+*rosekins.revolutions* real out::
Count of crossings of the negative X axis.
Clockwise crossings increment revolutions by 1, counterclockwise crossings decrement by 1.
-*rosekins.theta_degrees* float out::
+*rosekins.theta_degrees* real out::
Principal value for arctan(Y/X)
-*rosekins.bigtheta_degrees* float out::
+*rosekins.bigtheta_degrees* real out::
Accumulated angle (theta + revolutions * 360)
== NOTES
diff --git a/docs/src/man/man9/sampler.9.adoc b/docs/src/man/man9/sampler.9.adoc
index ba6a5f41dcc..04b8000b6c3 100644
--- a/docs/src/man/man9/sampler.9.adoc
+++ b/docs/src/man/man9/sampler.9.adoc
@@ -31,10 +31,10 @@ where it can be redirected to a file or piped to some other program.
commas. *sampler* exports one pin for each character in _string._
Legal characters are:
-- *F, f* (float pin)
-- *B, b* (bit pin)
-- *S, s* (s32 pin)
-- *U, u* (u32 pin)
+- *F*, *f*, *R*, *r* (real pin)
+- *B*, *b* (bool pin)
+- *S*, *s*, *L*, *l* (sint pin)
+- *U*, *u*, *K*, *k* (uint pin)
== FUNCTIONS
@@ -47,23 +47,23 @@ where it can be redirected to a file or piped to some other program.
Pin for the data that will wind up in column _M_ of FIFO _N_ (and in
column _M_ of the output file). The pin type depends on the config
string.
-**sampler.**_N_**.curr-depth** s32 output::
+**sampler.**_N_**.curr-depth** sint output::
Current number of samples in the FIFO. When this reaches _depth_ new
data will begin overwriting old data, and some samples will be lost.
-**sampler.**_N_**.full** bit output::
+**sampler.**_N_**.full** bool output::
TRUE when the FIFO _N_ is full, FALSE when there is room for another
sample.
-**sampler.**_N_**.enable** bit input::
+**sampler.**_N_**.enable** bool input::
When TRUE, samples are captured and placed in FIFO _N_, when FALSE, no
samples are acquired. Defaults to TRUE.
== PARAMETERS
-**sampler.**_N_**.overruns** s32 read/write::
+**sampler.**_N_**.overruns** sint read/write::
The number of times that *sampler* has tried to write data to the HAL
pins but found no room in the FIFO. It increments whenever *full* is
true, and can be reset by the *setp* command.
-**sampler.**_N_**.sample-num** s32 read/write::
+**sampler.**_N_**.sample-num** sint read/write::
A number that identifies the sample. It is automatically incremented
for each sample, and can be reset using the *setp* command. The sample
number can optionally be printed in the first column of the output
diff --git a/docs/src/man/man9/siggen.9.adoc b/docs/src/man/man9/siggen.9.adoc
index ee39b4ea260..6768c753069 100644
--- a/docs/src/man/man9/siggen.9.adoc
+++ b/docs/src/man/man9/siggen.9.adoc
@@ -43,37 +43,37 @@ The **siggen.**_N_**.** format is shown in the following descriptions.
== PINS
-**siggen.**_N_**.frequency** float in::
+**siggen.**_N_**.frequency** real in::
The output frequency for signal generator _N_, in Hertz.
The default value is 1.0 Hertz.
-**siggen.**_N_**.amplitude** float in::
+**siggen.**_N_**.amplitude** real in::
The output amplitude for signal generator _N_.
If *offset* is zero, the outputs will swing from -*amplitude* to +**amplitude**.
The default value is 1.00.
-**siggen.**_N_**.offset** float in::
+**siggen.**_N_**.offset** real in::
The output offset for signal generator _N_.
This value is added directly to the output signal. The default value is zero.
-**siggen.**_N_**.reset** bit in::
+**siggen.**_N_**.reset** bool in::
Resets output pins to predetermined states: +
*sine*: 0 +
*sawtooth*: 0 +
*square*: -1 * amplitude +
*cosine*: -1 * amplitude +
*triangle*: -1 * amplitude
-**siggen.**_N_**.clock** bit out::
- The clock output. Bit type clock signal output at the commanded frequency.
-**siggen.**_N_**.square** float out::
+**siggen.**_N_**.clock** bool out::
+ The clock output. Boolean type clock signal output at the commanded frequency.
+**siggen.**_N_**.square** real out::
The square wave output. Positive while *triangle* and *cosine* are
ramping upwards, and while *sine* is negative.
-**siggen.**_N_**.sine** float out::
+**siggen.**_N_**.sine** real out::
The sine output. Lags *cosine* by 90 degrees.
-**siggen.**_N_**.cosine** float out::
+**siggen.**_N_**.cosine** real out::
The cosine output. Leads *sine* by 90 degrees.
-**siggen.**_N_**.triangle** float out::
+**siggen.**_N_**.triangle** real out::
The triangle wave output.
Ramps up while *square* is positive, and down while *square* is negative.
Reaches its positive and negative peaks at the same time as *cosine*.
-**siggen.**_N_**.sawtooth** float out::
+**siggen.**_N_**.sawtooth** real out::
The sawtooth output. Ramps upwards to its positive peak, then
instantly drops to its negative peak and starts ramping again.
The drop occurs when *triangle* and *cosine* are at their positive peaks,
diff --git a/docs/src/man/man9/sim_encoder.9.adoc b/docs/src/man/man9/sim_encoder.9.adoc
index 22666604009..8a4ce856813 100644
--- a/docs/src/man/man9/sim_encoder.9.adoc
+++ b/docs/src/man/man9/sim_encoder.9.adoc
@@ -47,25 +47,25 @@ The *sim-encoder.N.* format is shown in the following descriptions.
== PINS
-**sim-encoder.**_N_**.phase-A** bit out::
+**sim-encoder.**_N_**.phase-A** bool out::
One of the quadrature outputs.
-**sim-encoder.**_N_**.phase-B** bit out::
+**sim-encoder.**_N_**.phase-B** bool out::
The other quadrature output.
-**sim-encoder.**_N_**.phase-Z** bit out::
+**sim-encoder.**_N_**.phase-Z** bool out::
The index pulse.
-**sim-encoder.**_N_**.speed** float in::
+**sim-encoder.**_N_**.speed** real in::
The desired speed of the encoder, in user units per per second. This
is divided by *scale*, and the result is used as the encoder speed in
revolutions per second.
== PARAMETERS
-**sim-encoder.**_N_**.ppr** u32 rw::
+**sim-encoder.**_N_**.ppr** uint rw::
The pulses per revolution of the simulated encoder. Note that this is
pulses, not counts, per revolution (ppr). Each pulse or cycle from the
encoder results in four counts, because every edge is counted. Default
value is 100 ppr, or 400 counts per revolution.
-**sim-encoder.**_N_**.scale** float rw::
+**sim-encoder.**_N_**.scale** real rw::
Scale factor for the *speed* input. The *speed* value is divided by
*scale* to get the actual encoder speed in revolutions per second. For
example, if *scale* is set to 60, then *speed* is in revolutions per
diff --git a/docs/src/man/man9/stepgen.9.adoc b/docs/src/man/man9/stepgen.9.adoc
index 16e5b6d3cb4..5e118a14254 100644
--- a/docs/src/man/man9/stepgen.9.adoc
+++ b/docs/src/man/man9/stepgen.9.adoc
@@ -96,66 +96,66 @@ type 15: user-specified::
== PINS
-**stepgen.**__N__**.counts** s32 out::
+**stepgen.**__N__**.counts** sint out::
The current position, in counts, for channel _N_. Updated by *capture-position*.
-**stepgen.**__N__**.position-fb** float out::
+**stepgen.**__N__**.position-fb** real out::
The current position, in length units (see parameter *position-scale*).
Updated by *capture-position*. The resolution of *position-fb* is much finer than a single step.
If you need to see individual steps, use *counts*.
-**stepgen.**__N__**.enable** bit in::
+**stepgen.**__N__**.enable** bool in::
Enables output steps - when false, no steps are generated.
-**stepgen.**__N__**.velocity-cmd** float in (velocity mode only)::
+**stepgen.**__N__**.velocity-cmd** real in (velocity mode only)::
Commanded velocity, in length units per second (see parameter
*position-scale*).
-**stepgen.**__N__**.position-cmd** float in (position mode only)::
+**stepgen.**__N__**.position-cmd** real in (position mode only)::
Commanded position, in length units (see parameter *position-scale)*.
-**stepgen.**__N__**.step** bit out (step type 0 only)::
+**stepgen.**__N__**.step** bool out (step type 0 only)::
Step pulse output.
-**stepgen.**__N__**.dir** bit out (step type 0 only)::
+**stepgen.**__N__**.dir** bool out (step type 0 only)::
Direction output: low for forward, high for reverse.
-**stepgen.**__N__**.up** bit out (step type 1 only)::
+**stepgen.**__N__**.up** bool out (step type 1 only)::
Count up output, pulses for forward steps.
-**stepgen.**__N__**.down** bit out (step type 1 only)::
+**stepgen.**__N__**.down** bool out (step type 1 only)::
Count down output, pulses for reverse steps.
-**stepgen.**__N__**.phase-A** thru *phase-E* bit out (step types 2-14 only)::
+**stepgen.**__N__**.phase-A** thru *phase-E* bool out (step types 2-14 only)::
Output bits. `phase-A` and `phase-B` are present for step types 2-14,
`phase-C` for types 3-14, `phase-D` for types 5-14, and `phase-E` for types 11-14.
Behavior depends on selected stepping type.
== PARAMETERS
-**stepgen.**_N_**.frequency** float ro::
+**stepgen.**_N_**.frequency** real ro::
The current step rate, in steps per second, for channel _N_.
-**stepgen.**_N_**.maxaccel** float rw::
+**stepgen.**_N_**.maxaccel** real rw::
The acceleration/deceleration limit, in length units per second squared.
-**stepgen.**_N_**.maxvel** float rw::
+**stepgen.**_N_**.maxvel** real rw::
The maximum allowable velocity, in length units per second.
If the requested maximum velocity cannot be reached with the current
combination of scaling and *make-pulses* thread period, it will be
reset to the highest attainable value.
-**stepgen.**_N_**.position-scale** float rw::
+**stepgen.**_N_**.position-scale** real rw::
The scaling for position feedback, position command, and velocity
command, in steps per length unit.
-**stepgen.**_N_**.rawcounts** s32 ro::
+**stepgen.**_N_**.rawcounts** sint ro::
The position in counts, as updated by *make-pulses*.
(Note: this is updated more frequently than the *counts* pin.)
-**stepgen.**_N_**.steplen** u32 rw::
+**stepgen.**_N_**.steplen** uint rw::
The length of the step pulses, in nanoseconds.
Measured from rising edge to falling edge.
-**stepgen.**_N_**.stepspace** u32 rw (step types 0 and 1 only)::
+**stepgen.**_N_**.stepspace** uint rw (step types 0 and 1 only)::
The minimum space between step pulses, in nanoseconds. Measured from
falling edge to rising edge. The actual time depends on the step rate
and can be much longer. If *stepspace* is 0, then *step* can be
asserted every period. This can be used in conjunction with
*hal_parport*'s auto-resetting pins to output one step pulse per
period. In this mode, *steplen* must be set for one period or less.
-**stepgen.**_N_**.dirsetup** u32 rw (step type 0 only)::
+**stepgen.**_N_**.dirsetup** uint rw (step type 0 only)::
The minimum setup time from direction to step, in nanoseconds periods.
Measured from change of direction to rising edge of step.
-**stepgen.**_N_**.dirhold** u32 rw (step type 0 only)::
+**stepgen.**_N_**.dirhold** uint rw (step type 0 only)::
The minimum hold time of direction after step, in nanoseconds.
Measured from falling edge of step to change of direction.
-**stepgen.**_N_**.dirdelay** u32 rw (step types 1 and higher only)::
+**stepgen.**_N_**.dirdelay** uint rw (step types 1 and higher only)::
The minimum time between a forward step and a reverse step, in nanoseconds.
== TIMING
diff --git a/docs/src/man/man9/streamer.9.adoc b/docs/src/man/man9/streamer.9.adoc
index a05257da4f1..cb784361940 100644
--- a/docs/src/man/man9/streamer.9.adoc
+++ b/docs/src/man/man9/streamer.9.adoc
@@ -26,10 +26,10 @@ streamer - stream file data into HAL in real time
*streamer* exports one pin for each character in _string_.
Legal characters are:
- * *F*, *f* (float pin)
- * *B*, *b* (bit pin)
- * *S*, *s* (s32 pin)
- * *U*, *u* (u32 pin)
+ * *F*, *f*, *R*, *r* (real pin)
+ * *B*, *b* (bool pin)
+ * *S*, *s*, *L*, *l* (sint pin)
+ * *U*, *u*, *K*, *k* (uint pin)
== FUNCTIONS
*streamer*._N_::
@@ -41,25 +41,25 @@ One function is created per FIFO, numbered from zero.
Data from column _M_ of the data in FIFO _N_ appears on this pin.
The pin type depends on the config string.
-*streamer*._N_.*curr-depth* s32 output::
+*streamer*._N_.*curr-depth* sint output::
Current number of samples in the FIFO.
When this reaches zero, new data will no longer be written to the pins.
-*streamer*._N_.*empty* bit output::
+*streamer*._N_.*empty* bool output::
TRUE when the FIFO _N_ is empty, FALSE when valid data is available.
-*streamer*._N_.*enable* bit input::
+*streamer*._N_.*enable* bool input::
When TRUE, data from FIFO _N_ is written to the HAL pins.
When false, no data is transferred. Defaults to TRUE.
-*streamer*._N_.*underruns* s32 read/write::
+*streamer*._N_.*underruns* sint read/write::
The number of times that *sampler* has tried to write data to the HAL pins but found no fresh data in the FIFO.
It increments whenever *empty* is true, and can be reset by the *setp* command.
-*streamer*._N_.*clock bit input::
+*streamer*._N_.*clock bool input::
Clock for data as specified by the clock-mode pin.
-*streamer*._N_.*clock-mode s32 input::
+*streamer*._N_.*clock-mode sint input::
Defines behavior of clock pin:
* 0 (*default*) free run at every iteration
diff --git a/docs/src/man/man9/supply.9.adoc b/docs/src/man/man9/supply.9.adoc
index d2693c26e04..d65fc010e43 100644
--- a/docs/src/man/man9/supply.9.adoc
+++ b/docs/src/man/man9/supply.9.adoc
@@ -34,15 +34,15 @@ loaded. If *numchan* is not specified, the default value is one.
== PINS
-**supply.**_N_**.q** bit out::
- Output bit, copied from parameter **supply.**_N_**.d**.
-**supply.**_N_**._q** bit out::
- Output bit, inverted copy of parameter **supply.**_N_**.d**.
-**supply.**_N_**.variable** float out::
+**supply.**_N_**.q** bool out::
+ Output value, copied from parameter **supply.**_N_**.d**.
+**supply.**_N_**._q** bool out::
+ Output value, inverted copy of parameter **supply.**_N_**.d**.
+**supply.**_N_**.variable** real out::
Analog output, copied from parameter **supply.**_N_**.value**.
-**supply.**_N_**._variable** float out::
+**supply.**_N_**._variable** real out::
Analog output, equal to -1.0 times parameter **supply.**_N_**.value**.
-**supply.**_N_**.d** bit rw::
+**supply.**_N_**.d** bool rw::
Data source for *q* and *_q* output pins.
-**supply.**_N_**.value** bit rw::
+**supply.**_N_**.value** bool rw::
Data source for *variable* and *_variable* output pins.
diff --git a/docs/src/man/man9/watchdog.9.adoc b/docs/src/man/man9/watchdog.9.adoc
index c2ad6d09c40..d6a9a4f44ce 100644
--- a/docs/src/man/man9/watchdog.9.adoc
+++ b/docs/src/man/man9/watchdog.9.adoc
@@ -18,20 +18,20 @@ Each input has a separate timeout value.
input has no transition within its timeout period. This function does
not use floating point, and should be added to a fast thread.
*set-timeouts*::
- Check for timeout changes, and convert the float timeout inputs to int values
+ Check for timeout changes, and convert the real timeout inputs to integer values
that can be used in *process*. This function also monitors `enable-in`
for false to true transitions, and re-enables monitoring when such a transition is detected.
This function does use floating point, and it is appropriate to add it to the servo thread.
== PINS
-**watchdog.input-**__N__ bit in::
- Input number _N_. The inputs are numbered from 0 to *num_inputs*-1.
-**watchdog.enable-in** bit in (default: FALSE)::
+**watchdog.input-**__N__ bool in::
+ Input number _N_. The inputs are numbered from 0 to **num_inputs**-1.
+**watchdog.enable-in** bool in (default: FALSE)::
If TRUE, forces out-ok to be false. Additionally, if a timeout occurs
on any input, this pin must be set FALSE and TRUE again to re-start
the monitoring of input pins.
-*watchdog.ok-out* bit out (default: FALSE)::
+*watchdog.ok-out* bool out (default: FALSE)::
OK output. This pin is true only if enable-in is TRUE and no timeout
has been detected. This output can be connected to the enable input of
a *charge_pump* or *stepgen* (in v mode), to provide a heartbeat
@@ -39,7 +39,7 @@ Each input has a separate timeout value.
== PARAMETERS
-**watchdog.timeout-**_N_ float in::
+**watchdog.timeout-**_N_ real in::
Timeout value for input number _N_.
The inputs are numbered from 0 to **num_inputs**-1.
The timeout is in seconds, and may not be below zero.
diff --git a/docs/src/man/man9/weighted_sum.9.adoc b/docs/src/man/man9/weighted_sum.9.adoc
index dfd1593cad8..ff4ada4e70e 100644
--- a/docs/src/man/man9/weighted_sum.9.adoc
+++ b/docs/src/man/man9/weighted_sum.9.adoc
@@ -14,11 +14,11 @@ Creates weighted sum groups each with the given number of input bits (_size_).
The weighted_sum converts a group of bits to an integer. The conversion
is the sum of the weights of the bits that are on plus any offset. The
-weight of the m-th bit is 2^m. This is similar to a binary coded decimal
+weight of the m-th bit is 2\^m. This is similar to a binary coded decimal
but with more options. The hold bit stops processing the input changes
so the sum will not change.
-The default value for each weight is 2^m where m is the bit number.
+The default value for each weight is 2\^m where m is the bit number.
This results in a binary to unsigned conversion.
There is a limit of 8 weighted summers and each may have up to 16 input bits.
@@ -30,19 +30,19 @@ There is a limit of 8 weighted summers and each may have up to 16 input bits.
== PINS
-**wsum.**_N_**.bit.**_M_**.in** bit in::
+**wsum.**_N_**.bit.**_M_**.in** bool in::
The __m__^th^ input of weighted summer _n_.
-**wsum.**_N_**.hold** bit in::
+**wsum.**_N_**.hold** bool in::
When TRUE, the _sum_ output does not change.
When FALSE, the _sum_ output tracks the _bit_ inputs according to the weights and offset.
-**wsum.**_N_**.sum** signed out::
+**wsum.**_N_**.sum** sint out::
The output of the weighted summer.
-**wsum.**_N_**.bit.**_M_**.weight** signed rw::
+**wsum.**_N_**.bit.**_M_**.weight** sint rw::
The weight of the __m__^th^ input of weighted summer _n_.
The default value is 2^__m__^.
-**wsum.**_N_**.offset** signed rw::
+**wsum.**_N_**.offset** sint rw::
The offset is added to the weights corresponding to all TRUE inputs to give the final sum.
== SEE ALSO
-scaled_s32_sums(9), sum2(9)
+scaled_sint_sums(9), sum2(9)
diff --git a/docs/src/motion/external-offsets.adoc b/docs/src/motion/external-offsets.adoc
index 9548d705a4a..f81b24f6796 100644
--- a/docs/src/motion/external-offsets.adoc
+++ b/docs/src/motion/external-offsets.adoc
@@ -46,17 +46,17 @@ external offset acceleration = ( r) * MAX_ACCELERATION
For each axis letter (*_L_* in xyzabcuvw)
-. *axis._L_.eoffset-enable* Input(bit): enable
-. *axis._L_.eoffset-scale* Input(float): scale factor
-. *axis._L_.eoffset-counts* Input(s32): input to counts register
-. *axis._L_.eoffset-clear* Input(bit): clear requested offset
-. *axis._L_.eoffset* Output(float): current external offset
-. *axis._L_.eoffset-request* Output(float): requested external offset
+. *axis._L_.eoffset-enable* Input(bool): enable
+. *axis._L_.eoffset-scale* Input(real): scale factor
+. *axis._L_.eoffset-counts* Input(sint): input to counts register
+. *axis._L_.eoffset-clear* Input(bool): clear requested offset
+. *axis._L_.eoffset* Output(real): current external offset
+. *axis._L_.eoffset-request* Output(real): requested external offset
=== Other Motion HAL Pins
-. *motion.eoffset-active* Output(bit): non-zero external offsets applied
-. *motion.eoffset-limited* Output(bit): motion inhibited due to soft limit
+. *motion.eoffset-active* Output(bool): non-zero external offsets applied
+. *motion.eoffset-limited* Output(bool): motion inhibited due to soft limit
== Usage
diff --git a/docs/src/motion/switchkins.adoc b/docs/src/motion/switchkins.adoc
index 8c1fea13e24..7b0041a2395 100644
--- a/docs/src/motion/switchkins.adoc
+++ b/docs/src/motion/switchkins.adoc
@@ -139,11 +139,11 @@ program behavior in accordance with the active kinematics type.
=== HAL Pin Summary
-. *motion.switchkins-type* Input (float)
-. *motion.kins-type* Output (float)
-. *kinstype.is-0* Output (bit)
-. *kinstype.is-1* Output (bit)
-. *kinstype.is-2* Output (bit)
+. *motion.switchkins-type* Input (real)
+. *motion.kins-type* Output (real)
+. *kinstype.is-0* Output (bool)
+. *kinstype.is-1* Output (bool)
+. *kinstype.is-2* Output (bool)
A module providing more than three kinematics types has one
'kinstype.is-N' pin per type.
diff --git a/lib/hallib/hal_procs_lib.tcl b/lib/hallib/hal_procs_lib.tcl
index 6347d5dc34e..202c59d927a 100644
--- a/lib/hallib/hal_procs_lib.tcl
+++ b/lib/hallib/hal_procs_lib.tcl
@@ -144,6 +144,10 @@ proc get_netlist {inpins_name outpin_name iopins_name signame} {
set v1 [lindex $l($ct) 1]
set v2 [lindex $l($ct) 2]
switch $v0 {
+ bool -
+ real -
+ sint -
+ uint -
float -
bit -
u32 -
diff --git a/lib/python/gladevcp/hal_widgets.py b/lib/python/gladevcp/hal_widgets.py
index d7d993f4779..ddb18f0a9e9 100644
--- a/lib/python/gladevcp/hal_widgets.py
+++ b/lib/python/gladevcp/hal_widgets.py
@@ -53,7 +53,7 @@ def hal_update(self, *a):
class _HalScaleBase(_HalWidgetBase):
def _hal_init(self):
self.hal_pin = self.hal.newpin(self.hal_name, hal.Type.REAL, hal.Dir.OUT)
- self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.Type.SINT, hal.Dir.OUT)
self.connect("value-changed", self.hal_update)
def hal_update(self, *a):
@@ -86,7 +86,7 @@ def _hal_init(self):
class _HalJogWheelBase(_HalWidgetBase):
def _hal_init(self):
- self.hal_pin = self.hal.newpin(self.hal_name, hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin = self.hal.newpin(self.hal_name, hal.Type.SINT, hal.Dir.OUT)
try:
self.get_scaled_value()
self.hal_pin_scaled = self.hal.newpin(self.hal_name+'-scaled', hal.Type.REAL, hal.Dir.OUT)
@@ -167,7 +167,7 @@ def do_set_property(self, property, value):
def _hal_init(self):
self.hal_pin_f = self.hal.newpin(self.hal_name+"-f", hal.Type.REAL, hal.Dir.OUT)
- self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.Type.SINT, hal.Dir.OUT)
self.connect("changed", self.hal_update)
def hal_update(self, *a):
@@ -220,7 +220,7 @@ def hal_update(self, *a):
def _hal_init(self):
self.hal_pin_f = self.hal.newpin(self.hal_name+"-f", hal.Type.REAL, hal.Dir.OUT)
- self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.hal.newpin(self.hal_name+"-s", hal.Type.SINT, hal.Dir.OUT)
self.connect("value-changed", self.hal_update)
self.emit("value-changed")
@@ -349,9 +349,9 @@ def do_set_property(self, property, value):
def _hal_init(self):
- types = {0:hal.HAL_S32
+ types = {0:hal.Type.SINT
,1:hal.Type.REAL
- ,2:hal.HAL_U32
+ ,2:hal.Type.UINT
}
pin_type = types.get(self.label_pin_type, None)
if pin_type is None:
diff --git a/lib/python/hal.py b/lib/python/hal.py
index 34f90289cb6..0fa81b63991 100644
--- a/lib/python/hal.py
+++ b/lib/python/hal.py
@@ -48,6 +48,22 @@ def __getattr__(name):
warnings.warn(f"{name} is deprecated, use lcnc_realtime.verify() instead", FutureWarning, stacklevel=2)
return not lcnc_realtime.verify()
+ oldnames = {
+ 'HAL_BIT' : (_hal.Type.BOOL, 'BOOL'),
+ 'HAL_FLOAT': (_hal.Type.REAL, 'REAL'),
+ 'HAL_S32' : (_hal.Type.SINT, 'SINT'),
+ 'HAL_U32' : (_hal.Type.UINT, 'UINT'),
+ 'HAL_S64' : (_hal.Type.SINT, 'SINT'),
+ 'HAL_U64' : (_hal.Type.UINT, 'UINT')
+ }
+ if name in oldnames:
+ nt, nn = oldnames[name]
+ if name in ('HAL_S32', 'HAL_U32'):
+ warnings.warn(f"{name} is no longer supported and replaced by hal.Type.{nn}", FutureWarning, stacklevel=2)
+ else:
+ warnings.warn(f"{name} has been deprecated. Please use the IntEnum type hal.Type.{nn}", FutureWarning, stacklevel=2)
+ return nt
+
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
class _ItemWrap(object):
diff --git a/lib/python/pyvcp_widgets.py b/lib/python/pyvcp_widgets.py
index 7e831fbcae8..e3c3398911a 100644
--- a/lib/python/pyvcp_widgets.py
+++ b/lib/python/pyvcp_widgets.py
@@ -1074,8 +1074,8 @@ def update(self,pycomp):
self.v.set( str( dummy % {'b':newvalue} ) )
-class pyvcp_u32(Label):
- """ (indicator) shows a u32 as text """
+class pyvcp_uint(Label):
+ """ (indicator) shows a uint as text """
n=0
def __init__(self,master,pycomp,halpin=None,format="d",**kw):
self.v = StringVar()
@@ -1088,7 +1088,7 @@ def __init__(self,master,pycomp,halpin=None,format="d",**kw):
self.value=int(0.0)
dummy = "%(b)"+self.format
self.v.set( str( dummy % {'b':self.value} ) )
- pycomp.newpin(halpin, HAL_U32, Dir.IN)
+ pycomp.newpin(halpin, Type.UINT, Dir.IN)
def update(self,pycomp):
newvalue = pycomp[self.halpin]
@@ -1097,9 +1097,13 @@ def update(self,pycomp):
dummy = "%(b)"+self.format
self.v.set( str( dummy % {'b':newvalue} ) )
-
-class pyvcp_s32(Label):
- """ (indicator) shows a s32 as text """
+class pyvcp_u32(pyvcp_uint):
+ """ (indicator) shows a uint as text """
+ # This is just a proxy so that tags still work.
+ # We changed the actual pin type to UINT.
+
+class pyvcp_sint(Label):
+ """ (indicator) shows a sint as text """
n=0
def __init__(self,master,pycomp,halpin=None,format="d",**kw):
self.v = StringVar()
@@ -1112,7 +1116,7 @@ def __init__(self,master,pycomp,halpin=None,format="d",**kw):
self.value=int(0.0)
dummy = "%(b)"+self.format
self.v.set( str( dummy % {'b':self.value} ) )
- pycomp.newpin(halpin, HAL_S32, Dir.IN)
+ pycomp.newpin(halpin, Type.SINT, Dir.IN)
def update(self,pycomp):
newvalue = pycomp[self.halpin]
@@ -1121,6 +1125,11 @@ def update(self,pycomp):
dummy = "%(b)"+self.format
self.v.set( str( dummy % {'b':newvalue} ) )
+class pyvcp_s32(pyvcp_sint):
+ """ (indicator) shows a sint as text """
+ # This is just a proxy so that tags still work.
+ # We changed the actual pin type to SINT.
+
class pyvcp_timer(Label):
""" (indicator) shows elapsed time as HH:MM:SS
two pins - run and reset
@@ -1568,7 +1577,7 @@ def __init__(self,master,pycomp,
pyvcp_scale.n += 1
- pycomp.newpin(halpin+"-i", HAL_S32, Dir.OUT)
+ pycomp.newpin(halpin+"-i", Type.SINT, Dir.OUT)
pycomp.newpin(halpin+"-f", Type.REAL, Dir.OUT)
self.bind('',self.wheel_up)
@@ -1775,10 +1784,15 @@ def update(self, pycomp):
print("Unknown image #%d on %s" % (l, self.halpin), file=sys.stderr)
self.last = l
+class pyvcp_image_bool(_pyvcp_image):
+ pintype = Type.BOOL
+class pyvcp_image_uint(_pyvcp_image):
+ pintype = Type.UINT
+# Keep the old names for compatibility
class pyvcp_image_bit(_pyvcp_image):
pintype = Type.BOOL
class pyvcp_image_u32(_pyvcp_image):
- pintype = HAL_U32
+ pintype = Type.UINT
# This must come after all the pyvcp_xxx classes
elements = []
diff --git a/lib/python/qtvcp/lib/message.py b/lib/python/qtvcp/lib/message.py
index e74e111baf7..825552a3153 100644
--- a/lib/python/qtvcp/lib/message.py
+++ b/lib/python/qtvcp/lib/message.py
@@ -76,7 +76,7 @@ def message_setup(self, hal_comp, window=None, notify=None):
self.HAL_GCOMP_.newpin(name + "-waiting", hal.Type.BOOL, hal.Dir.OUT)
if not ("ok" in details):
self.HAL_GCOMP_.newpin(name + "-response", hal.Type.BOOL, hal.Dir.OUT)
- self.HAL_GCOMP_.newpin(name + "-response-s32", hal.HAL_S32, hal.Dir.OUT)
+ self.HAL_GCOMP_.newpin(name + "-response-s32", hal.Type.SINT, hal.Dir.OUT)
self.HAL_GCOMP_[name + "-response-s32"] = -1 # undetermined
if not INFO.USRMULTIMESS_ID is None:
@@ -88,7 +88,7 @@ def message_setup(self, hal_comp, window=None, notify=None):
D.hal_init(HAL_NAME=name)
D.pinname = name
- D._halpin = self.HAL_GCOMP_.newpin(name, hal.HAL_S32, hal.Dir.IN)
+ D._halpin = self.HAL_GCOMP_.newpin(name, hal.Type.SINT, hal.Dir.IN)
D._halpin.value_changed.connect(self.multiMessageCallback(D,
D._halpin, name, mess, ))
diff --git a/lib/python/qtvcp/qt_halobjects.py b/lib/python/qtvcp/qt_halobjects.py
index 97db41a57ac..38846757bc9 100644
--- a/lib/python/qtvcp/qt_halobjects.py
+++ b/lib/python/qtvcp/qt_halobjects.py
@@ -121,8 +121,8 @@ class _QHal(object):
HAL_BIT = hal.Type.BOOL # Deprecated
HAL_FLOAT = hal.Type.REAL # Deprecated
- HAL_S32 = hal.HAL_S32
- HAL_U32 = hal.HAL_U32
+ HAL_S32 = hal.Type.SINT # Replaced by hal.Type.SINT
+ HAL_U32 = hal.Type.UINT # Replaced by hal.Type.UINT
HAL_IN = hal.Dir.IN
HAL_OUT = hal.Dir.OUT
diff --git a/lib/python/qtvcp/widgets/bar.py b/lib/python/qtvcp/widgets/bar.py
index b53fe23b336..1d59c283c2b 100644
--- a/lib/python/qtvcp/widgets/bar.py
+++ b/lib/python/qtvcp/widgets/bar.py
@@ -408,7 +408,7 @@ def resetVert(self):
class HALPinType(enum.IntEnum):
NONE = 0
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
SINT = hal.Type.SINT
REAL = hal.Type.REAL
@@ -420,14 +420,14 @@ class HalBar(Bar, _HalWidgetBase):
# older version of pyqt5 need this as well as QEnum
NONE = 0
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
SINT = hal.Type.SINT
REAL = hal.Type.REAL
def __init__(self, *args, **kwargs):
super(). __init__( *args, **kwargs)
- self._pin_type = HALPinType.S32
+ self._pin_type = HALPinType.SINT
self._pin_name = ''
self._invert_negative = False
self._superOpposite = self._opposite
@@ -443,8 +443,8 @@ def _hal_init(self):
if self._pin_type == HALPinType.REAL:
self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.REAL, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.updateDisplay(data))
- elif self._pin_type == HALPinType.S32:
- self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.HAL_S32, hal.Dir.IN)
+ elif self._pin_type == HALPinType.SINT:
+ self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.SINT, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.updateDisplay(data))
def updateDisplay(self, data):
@@ -460,7 +460,7 @@ def set_pin_type(self, value):
def get_pin_type(self):
return self._pin_type
def reset_pin_type(self):
- self._pin_type = HALPinType.S32
+ self._pin_type = HALPinType.SINT
def set_pin_name(self, value):
self._pin_name = value
diff --git a/lib/python/qtvcp/widgets/dialog_widget.py b/lib/python/qtvcp/widgets/dialog_widget.py
index b3164a8b4d4..bbe9a05e167 100644
--- a/lib/python/qtvcp/widgets/dialog_widget.py
+++ b/lib/python/qtvcp/widgets/dialog_widget.py
@@ -443,7 +443,7 @@ def _hal_init(self):
self.HAL_GCOMP_.comp.setprefix('hal_manualtoolchange')
self.hal_pin = self.HAL_GCOMP_.newpin('change', hal.Type.BOOL, hal.Dir.IN)
self.hal_pin.value_changed.connect(self.tool_change)
- self.tool_number = self.HAL_GCOMP_.newpin('number', hal.HAL_S32, hal.Dir.IN)
+ self.tool_number = self.HAL_GCOMP_.newpin('number', hal.Type.SINT, hal.Dir.IN)
self.changed = self.HAL_GCOMP_.newpin('changed', hal.Type.BOOL, hal.Dir.OUT)
self.ext_ack = self.HAL_GCOMP_.newpin(self.HAL_NAME_ + 'change_button', hal.Type.BOOL, hal.Dir.IN)
self.ext_ack.value_changed.connect(self.external_acknowledge)
diff --git a/lib/python/qtvcp/widgets/general_hal_input.py b/lib/python/qtvcp/widgets/general_hal_input.py
index 942fe4cae22..3f8cd3be73e 100644
--- a/lib/python/qtvcp/widgets/general_hal_input.py
+++ b/lib/python/qtvcp/widgets/general_hal_input.py
@@ -55,7 +55,7 @@ def _hal_init(self):
self.hal_pin = self.HAL_GCOMP_.newpin(self.HAL_NAME_, hal.Type.REAL, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.pin_update(data))
else:
- self.hal_pin = self.HAL_GCOMP_.newpin(self.HAL_NAME_, hal.HAL_S32, hal.Dir.IN)
+ self.hal_pin = self.HAL_GCOMP_.newpin(self.HAL_NAME_, hal.Type.SINT, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.pin_update(data))
def pin_update(self, *a):
diff --git a/lib/python/qtvcp/widgets/general_hal_output.py b/lib/python/qtvcp/widgets/general_hal_output.py
index f04439ab3b7..bf555cf3d6d 100644
--- a/lib/python/qtvcp/widgets/general_hal_output.py
+++ b/lib/python/qtvcp/widgets/general_hal_output.py
@@ -53,7 +53,7 @@ def _hal_init(self):
if self.istate:
self._pin_bit_update(self._initial_float)
else:
- ptype = hal.HAL_S32
+ ptype = hal.Type.SINT
ptype2 = hal.Type.REAL
self.hal_pin = self.HAL_GCOMP_.newpin(pname + '-s32', ptype, hal.Dir.OUT)
self.hal_pin_2 = self.HAL_GCOMP_.newpin(pname + "-float", ptype2, hal.Dir.OUT)
diff --git a/lib/python/qtvcp/widgets/hal_label.py b/lib/python/qtvcp/widgets/hal_label.py
index 81b06784867..add3f4fc664 100644
--- a/lib/python/qtvcp/widgets/hal_label.py
+++ b/lib/python/qtvcp/widgets/hal_label.py
@@ -55,7 +55,7 @@ def _hal_init(self):
self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.REAL, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self._setText(data))
elif self._s32_pin_type or self._use_multi_label:
- self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.HAL_S32, hal.Dir.IN)
+ self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.SINT, hal.Dir.IN)
if self._s32_pin_type:
self.hal_pin.value_changed.connect(lambda data: self._setText(data))
else:
diff --git a/lib/python/qtvcp/widgets/hal_selectionbox.py b/lib/python/qtvcp/widgets/hal_selectionbox.py
index 8e3d08e6c74..260f46bff26 100644
--- a/lib/python/qtvcp/widgets/hal_selectionbox.py
+++ b/lib/python/qtvcp/widgets/hal_selectionbox.py
@@ -113,8 +113,8 @@ class HALSelectionBox(TreeComboBox, _HalWidgetBase):
HAL_BIT = hal.Type.BOOL # Deprecated
HAL_FLOAT = hal.Type.REAL # Deprecated
- HAL_S32 = hal.HAL_S32
- HAL_U32 = hal.HAL_U32
+ HAL_S32 = hal.Type.SINT # Replaced by hal.Type.SINT
+ HAL_U32 = hal.Type.UINT # Replaced by hal.Type.SINT
HAL_IN = hal.Dir.IN
HAL_OUT = hal.Dir.OUT
@@ -128,9 +128,9 @@ class HALSelectionBox(TreeComboBox, _HalWidgetBase):
def __init__(self, parent=None):
super(HALSelectionBox, self).__init__(parent)
- self.PINTYPE = [self.HAL_BOOL,self.HAL_REAL,self.HAL_S32,self.HAL_U32]
+ self.PINTYPE = [self.HAL_BOOL,self.HAL_REAL,self.HAL_SINT,self.HAL_UINT]
self.PINDIRECTION = [self.HAL_IN, self.HAL_OUT]
- self.SIGTYPE = [self.HAL_BOOL,self.HAL_REAL,self.HAL_S32,self.HAL_U32]
+ self.SIGTYPE = [self.HAL_BOOL,self.HAL_REAL,self.HAL_SINT,self.HAL_UINT]
self.SIGDRIVEN = [True, False]
self.PARAMTYPE = [self.HAL_RO, self.HAL_RW]
self.SHOWTYPES = [self.PINS]
@@ -192,16 +192,16 @@ def _hal_init(self):
self.view().adjustSize()
def setShowTypes(self, types):
- ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_S32,HAL_U32
+ ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_SINT,HAL_UINT
that will be shown in the combbox.
widget defaults to all pin types shown
ie. combobox.setShowTypes([combobox.HAL_BOOL])'''
self.SHOWTYPES = types
def setPinTypes(self, \
- types = [HAL_BOOL,HAL_REAL,HAL_S32,HAL_U32], \
+ types = [HAL_BOOL,HAL_REAL,HAL_SINT,HAL_UINT], \
direction = [HAL_IN, HAL_OUT]):
- ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_S32,HAL_U32
+ ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_SINT,HAL_UINT
and direction: HAL_IN, HAL_OUT
that will be shown in combobox.
widget defaults to all pins, all directions.
@@ -210,9 +210,9 @@ def setPinTypes(self, \
self.PINDIRECTION = direction
def setSignalTypes(self, \
- types = [HAL_BOOL,HAL_REAL,HAL_S32,HAL_U32], \
+ types = [HAL_BOOL,HAL_REAL,HAL_SINT,HAL_UINT], \
driven = [True, False]):
- ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_S32,HAL_U32
+ ''' Sets the pin type: HAL_BOOL,HAL_REAL,HAL_SINT,HAL_UINT
and what type of signals (driven by a pin, not or both).
True being driven and False being un-driven signals
combobox.setSignalTypes([combobox.HAL_BOOL], direction = [True,False])'''
diff --git a/lib/python/qtvcp/widgets/joypad.py b/lib/python/qtvcp/widgets/joypad.py
index 223f459c34d..85620e61b8e 100644
--- a/lib/python/qtvcp/widgets/joypad.py
+++ b/lib/python/qtvcp/widgets/joypad.py
@@ -540,7 +540,7 @@ def __setitem__(self, item, value):
class HALPinType(enum.IntEnum):
NONE = 0
BIT = hal.Type.BOOL # Deprecated
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
BOOL = hal.Type.BOOL
SINT = hal.Type.SINT
@@ -553,7 +553,7 @@ class HALPad(JoyPad, _HalWidgetBase):
# older version of pyqt5 need this as well as QEnum
NONE = 0
BIT = hal.Type.BOOL # Deprecated
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
BOOL = hal.Type.BOOL
SINT = hal.Type.SINT
@@ -602,7 +602,7 @@ def _pressedOutput(self, btncode):
data = True
elif self._pin_type == HALPinType.REAL:
data = float(self['_trueOutput{}'.format(btncode)])
- elif self._pin_type == HALPinType.S32:
+ elif self._pin_type == HALPinType.SINT:
data = int(self['_trueOutput{}'.format(btncode)])
else:
return
@@ -619,7 +619,7 @@ def _releasedOutput(self, btncode):
data = False
elif self._pin_type == HALPinType.REAL:
data = float(self._falseOutput)
- elif self._pin_type == HALPinType.S32:
+ elif self._pin_type == HALPinType.SINT:
data = int(self._falseOutput)
else:
return
diff --git a/lib/python/qtvcp/widgets/simple_widgets.py b/lib/python/qtvcp/widgets/simple_widgets.py
index 2697fa53b1a..3e814efee42 100644
--- a/lib/python/qtvcp/widgets/simple_widgets.py
+++ b/lib/python/qtvcp/widgets/simple_widgets.py
@@ -46,7 +46,7 @@
class HALPinType(enum.IntEnum):
NONE = 0
BIT = hal.Type.BOOL # Deprecated
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
BOOL = hal.Type.BOOL
SINT = hal.Type.SINT
@@ -73,7 +73,7 @@ def _hal_init(self):
self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.REAL, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.updateFloatDisplay(data))
elif self._s32_pin_type:
- self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.HAL_S32, hal.Dir.IN)
+ self.hal_pin = self.HAL_GCOMP_.newpin(pname, hal.Type.SINT, hal.Dir.IN)
self.hal_pin.value_changed.connect(lambda data: self.updateDisplay(data))
def updateDisplay(self, data):
@@ -180,7 +180,7 @@ def _hal_init(self):
pname = self.HAL_NAME_
else:
pname = self._pin_name_
- self.hal_pin_s = self.HAL_GCOMP_.newpin(str(pname +'-s'), hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.HAL_GCOMP_.newpin(str(pname +'-s'), hal.Type.SINT, hal.Dir.OUT)
self.hal_pin_f = self.HAL_GCOMP_.newpin(pname +'-f', hal.Type.REAL, hal.Dir.OUT)
self.hal_pin_scale = self.HAL_GCOMP_.newpin(pname +'-scale', hal.Type.REAL, hal.Dir.IN)
self.hal_pin_scale.set(1)
@@ -215,7 +215,7 @@ def _hal_init(self):
pname = self.HAL_NAME_
else:
pname = self._pin_name_
- self.hal_pin_s = self.HAL_GCOMP_.newpin(str(pname +'-s'), hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.HAL_GCOMP_.newpin(str(pname +'-s'), hal.Type.SINT, hal.Dir.OUT)
self.hal_pin_f = self.HAL_GCOMP_.newpin(pname +'-f', hal.Type.REAL, hal.Dir.OUT)
self.hal_pin_d = self.HAL_GCOMP_.newpin(pname +'-d', hal.Type.REAL, hal.Dir.OUT)
self.hal_pin_scale = self.HAL_GCOMP_.newpin(pname +'-scale', hal.Type.REAL, hal.Dir.IN)
@@ -363,7 +363,7 @@ class PushButton(QtWidgets.QPushButton, IndicatedMixIn):
# older version of pyqt5 need this as well as QEnum
NONE = 0
BIT = hal.Type.BOOL # Deprecated
- S32 = hal.HAL_S32
+ S32 = hal.Type.SINT # Removed
FLOAT= hal.Type.REAL # Deprecated
BOOL = hal.Type.BOOL
SINT = hal.Type.SINT
@@ -372,7 +372,7 @@ class PushButton(QtWidgets.QPushButton, IndicatedMixIn):
def __init__(self, parent=None):
super(PushButton, self).__init__(parent)
- self._pin_type = HALPinType.S32
+ self._pin_type = HALPinType.SINT
self._groupPinName = ''
self._exclusiveValue = 0.0
self.halPinGroup = None
@@ -462,7 +462,7 @@ def updateGroup(self):
data = bool(value)
elif self._pin_type == HALPinType.REAL:
data = float(value)
- elif self._pin_type == HALPinType.S32:
+ elif self._pin_type == HALPinType.SINT:
data = int(value)
else:
return
@@ -485,7 +485,7 @@ def set_pin_type(self, value):
def get_pin_type(self):
return self._pin_type
def reset_pin_type(self):
- self._pin_type = HALPinType.S32
+ self._pin_type = HALPinType.SINT
# designer will show these properties in this order:
pin_type = QtCore.Property(HALPinType, get_pin_type, set_pin_type, reset_pin_type)
diff --git a/lib/python/qtvcp/widgets/widget_baseclass.py b/lib/python/qtvcp/widgets/widget_baseclass.py
index 49ce0e8a1e1..67f048285bd 100644
--- a/lib/python/qtvcp/widgets/widget_baseclass.py
+++ b/lib/python/qtvcp/widgets/widget_baseclass.py
@@ -143,7 +143,7 @@ def _hal_init(self):
else:
pname = self._pin_name_
self.hal_pin_f = self.HAL_GCOMP_.newpin(pname + "-f", hal.Type.REAL, hal.Dir.OUT)
- self.hal_pin_s = self.HAL_GCOMP_.newpin(pname + "-s", hal.HAL_S32, hal.Dir.OUT)
+ self.hal_pin_s = self.HAL_GCOMP_.newpin(pname + "-s", hal.Type.SINT, hal.Dir.OUT)
self.valueChanged.connect(lambda data: self._pin_update(data))
# default scale
self.input = 1
diff --git a/lib/python/raster.py b/lib/python/raster.py
index 574fdc06c8b..37676dd5756 100644
--- a/lib/python/raster.py
+++ b/lib/python/raster.py
@@ -55,7 +55,7 @@ def __init__(self, name):
self.__timeout = 5.0
self.component = hal.component(name)
self.port = self.component.newpin("program", hal.Type.PORT, hal.Dir.OUT)
- self.faultCode = self.component.newpin("fault-code", hal.HAL_S32, hal.Dir.IN)
+ self.faultCode = self.component.newpin("fault-code", hal.Type.SINT, hal.Dir.IN)
self.enabled = self.component.newpin("enabled", hal.Type.BOOL, hal.Dir.IN)
self.run = self.component.newpin("run", hal.Type.BOOL, hal.Dir.OUT)
self.component.ready()
diff --git a/lib/python/vcpparse.py b/lib/python/vcpparse.py
index bda750bbecc..24c4a360fda 100644
--- a/lib/python/vcpparse.py
+++ b/lib/python/vcpparse.py
@@ -65,16 +65,22 @@ def read_file():
num=0
+_old_types = {'s32':'sint', 'u32':'uint', 'image_bit':'image_bool', 'image_u32':'image_uint'}
+_old_types_warned = []
def nodeiterator(node,widgetparent):
"""
A recursive function that traverses the dom tree
and calls widget_creator() when it finds a valid element
"""
+ global _old_types, _old_types_warned
global num
num+=1
params=[]
for e in node.childNodes:
if e.nodeType == e.ELEMENT_NODE and (e.nodeName in pyvcp_widgets.elements):
+ if e.nodeName in _old_types and e.nodeName not in _old_types_warned:
+ print(f"Deprecation notice: Old tag name '<{e.nodeName}>' has been replaced with '<{_old_types[e.nodeName]}>'. Please update your configuration.")
+ _old_types_warned += [e.nodeName]
params = paramiterator(e) # find all the parameters for this node
newwidget = widget_creator(widgetparent,e.nodeName,params)
nodeiterator(e,newwidget)
diff --git a/nc_files/remap_lib/python-stdglue/stdglue.py b/nc_files/remap_lib/python-stdglue/stdglue.py
index 19d29d93520..8457e400f38 100644
--- a/nc_files/remap_lib/python-stdglue/stdglue.py
+++ b/nc_files/remap_lib/python-stdglue/stdglue.py
@@ -33,8 +33,8 @@ def build_hal(self):
import hal
try:
h=hal.component('remapStat')
- h.newpin("tool", hal.HAL_S32, hal.Dir.OUT)
- h.newpin("wear", hal.HAL_S32, hal.Dir.OUT)
+ h.newpin("tool", hal.Type.SINT, hal.Dir.OUT)
+ h.newpin("wear", hal.Type.SINT, hal.Dir.OUT)
h.ready()
self.hal_tool_comp = h
except Exception as e:
diff --git a/scripts/hal-histogram b/scripts/hal-histogram
index e4c210cef7d..a6fa342f668 100755
--- a/scripts/hal-histogram
+++ b/scripts/hal-histogram
@@ -106,10 +106,10 @@ proc set_defaults {} {
# defaults for items with no cmdline opts:
set ::HH(color) seagreen
- set ::HH(signame,prefix,float) hhf
- set ::HH(signame,prefix,s32) hhs
- set ::HH(signame,prefix,u32) hhu
- set ::HH(signame,prefix,bit) hhb
+ set ::HH(signame,prefix,real) hhf
+ set ::HH(signame,prefix,sint) hhs
+ set ::HH(signame,prefix,uint) hhu
+ set ::HH(signame,prefix,bool) hhb
set ::HH(max_histos) 5
set ::HH(guess,ct) 100
set ::HH(guess,factor) 10
@@ -212,10 +212,10 @@ proc config {} {
set ::HH(pintype) [hal ptype $::HH(pinname)]
switch -exact "$::HH(pintype)" {
- float {}
- s32 {}
- u32 {}
- bit {
+ real {}
+ sint {}
+ uint {}
+ bool {
# ignore input args on startup:
set ::HH(minvalue) 0
set ::HH(binsize) 1
@@ -498,10 +498,10 @@ proc check_inputs {minvalue binsize nbins} {
if { ![is_int $nbins] } {return "nbins must be integer"}
switch -exact "$::HH(pintype)" {
- float {}
- s32 -
- u32 -
- bit {
+ real {}
+ sint -
+ uint -
+ bool {
if { ![is_int $minvalue]} {
return "minvalue must be integer <$minvalue> for type $::HH(pintype)"
}
@@ -597,16 +597,16 @@ proc setup_hal {} {
if [catch {
switch -exact "$::HH(pintype)" {
- float { set ::HH(inputpinname) $::HH(instance).input
+ real { set ::HH(inputpinname) $::HH(instance).input
hal setp $::HH(instance).pintype 0
}
- s32 { set ::HH(inputpinname) $::HH(instance).input-s32
+ sint { set ::HH(inputpinname) $::HH(instance).input-sint
hal setp $::HH(instance).pintype 1
}
- u32 { set ::HH(inputpinname) $::HH(instance).input-u32
+ uint { set ::HH(inputpinname) $::HH(instance).input-uint
hal setp $::HH(instance).pintype 2
}
- bit { set ::HH(inputpinname) $::HH(instance).input-bit
+ bool { set ::HH(inputpinname) $::HH(instance).input-bool
hal setp $::HH(instance).pintype 3
}
default { puts notdoneyet; exit 77 }
@@ -968,7 +968,7 @@ proc usage { {errtxt ""} } {
puts " 1) LinuxCNC (or another Hal application) must be running"
puts " 2) If no pinname is specified, default is: $::HH(pinname)"
puts " 3) This app may be opened for $::HH(max_histos) pins"
- puts " 4) pintypes float, s32, u32, bit are supported"
+ puts " 4) pintypes real, sint, uint, bool are supported"
if {"$errtxt" != ""} {
puts ""
diff --git a/share/qtvcp/panels/qtplasmac_sim/qtplasmac_sim_handler.py b/share/qtvcp/panels/qtplasmac_sim/qtplasmac_sim_handler.py
index 86ce65d815d..9214601d5ed 100644
--- a/share/qtvcp/panels/qtplasmac_sim/qtplasmac_sim_handler.py
+++ b/share/qtvcp/panels/qtplasmac_sim/qtplasmac_sim_handler.py
@@ -59,7 +59,7 @@ def initialized__(self):
self.materialPin = self.hal.newpin('material_height', hal.Type.REAL, hal.Dir.IN)
self.ohmicPin = self.hal.newpin('sensor_ohmic', hal.Type.BOOL, hal.Dir.OUT)
self.torchPin = self.hal.newpin('torch_on', hal.Type.BOOL, hal.Dir.IN)
- self.statePin = self.hal.newpin('state', hal.HAL_S32, hal.Dir.IN)
+ self.statePin = self.hal.newpin('state', hal.Type.SINT, hal.Dir.IN)
self.stylePin = self.hal.newpin('style_update', hal.Type.BOOL, hal.Dir.IN)
self.zPosPin = self.hal.newpin('z_position', hal.Type.REAL, hal.Dir.IN)
simStepconf = False
diff --git a/share/qtvcp/panels/sim_panel/sim_panel.ui b/share/qtvcp/panels/sim_panel/sim_panel.ui
index 92d76cc0100..8428bc2a63b 100644
--- a/share/qtvcp/panels/sim_panel/sim_panel.ui
+++ b/share/qtvcp/panels/sim_panel/sim_panel.ui
@@ -96,7 +96,7 @@
true
- PushButton::FLOAT
+ PushButton::REAL
increments
@@ -130,7 +130,7 @@
false
- PushButton::FLOAT
+ PushButton::REAL
10.000000000000000
@@ -161,7 +161,7 @@
false
- PushButton::FLOAT
+ PushButton::REAL
30.000000000000000
diff --git a/share/qtvcp/screens/qtaxis/qtaxis_handler.py b/share/qtvcp/screens/qtaxis/qtaxis_handler.py
index d5827821182..9fbea092ec9 100644
--- a/share/qtvcp/screens/qtaxis/qtaxis_handler.py
+++ b/share/qtvcp/screens/qtaxis/qtaxis_handler.py
@@ -404,7 +404,7 @@ def init_pins(self):
self['jog_axis_{}_pin'.format(i)] = \
QHAL.newpin("axis-{}-selected".format(i.lower()), QHAL.HAL_BOOL, QHAL.HAL_OUT)
# screen MPG controls
- self.pin_mpg_in = QHAL.newpin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newpin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.value_changed.connect(lambda s: self.external_mpg(s))
self.pin_mpg_enabled = QHAL.newpin('mpg-enable',QHAL.HAL_BOOL, QHAL.HAL_IN)
diff --git a/share/qtvcp/screens/qtdragon/qtdragon_handler.py b/share/qtvcp/screens/qtdragon/qtdragon_handler.py
index 41b842de940..d69b9a00515 100644
--- a/share/qtvcp/screens/qtdragon/qtdragon_handler.py
+++ b/share/qtvcp/screens/qtdragon/qtdragon_handler.py
@@ -337,14 +337,14 @@ def init_pins(self):
pin = QHAL.newPin("spindle-volts", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_pwr_changed(v))
- pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-fault", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
pin = QHAL.newPin("spindle-modbus-connection", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -359,7 +359,7 @@ def init_pins(self):
QHAL.newPin("eoffset-enable", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("eoffset-clear", QHAL.HAL_BOOL, QHAL.HAL_OUT)
self.h['eoffset-clear'] = True
- QHAL.newPin("eoffset-spindle-count", QHAL.HAL_S32, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-spindle-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
pin = QHAL.newPin("eoffset-is-active", QHAL.HAL_BOOL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.external_offset_state_changed(v))
@@ -367,7 +367,7 @@ def init_pins(self):
pin = QHAL.newPin("eoffset-value", QHAL.HAL_REAL, QHAL.HAL_IN)
# MPG scrolling pin
- self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.pinValueChanged.connect(lambda p,v: self.external_mpg(v))
# dialog answer pins
diff --git a/share/qtvcp/screens/qtdragon_hd/qtdragon_hd_handler.py b/share/qtvcp/screens/qtdragon_hd/qtdragon_hd_handler.py
index 7c6055aca71..a8c4d45c378 100644
--- a/share/qtvcp/screens/qtdragon_hd/qtdragon_hd_handler.py
+++ b/share/qtvcp/screens/qtdragon_hd/qtdragon_hd_handler.py
@@ -266,14 +266,14 @@ def init_pins(self):
pin = QHAL.newPin("spindle-volts", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_pwr_changed(v))
- pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-fault", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
pin = QHAL.newPin("spindle-modbus-connection", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -288,8 +288,8 @@ def init_pins(self):
QHAL.newPin("eoffset-enable", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("eoffset-clear", QHAL.HAL_BOOL, QHAL.HAL_OUT)
self.h['eoffset-clear'] = False
- QHAL.newPin("eoffset-spindle-count", QHAL.HAL_S32, QHAL.HAL_OUT)
- QHAL.newPin("eoffset-count", QHAL.HAL_S32, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-spindle-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
pin = QHAL.newPin("eoffset-is-active", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -297,13 +297,13 @@ def init_pins(self):
pin = QHAL.newPin("eoffset-value", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.external_offset_state_changed(v))
- pin = QHAL.newPin("eoffset-zlevel-count", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("eoffset-zlevel-count", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.comp_count_changed(v))
QHAL.newPin("comp-on", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("spindle-lift-on", QHAL.HAL_BOOL, QHAL.HAL_OUT)
# MPG scrolling pin
- self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.pinValueChanged.connect(lambda p,v: self.external_mpg(v))
# dialog answer pins
diff --git a/share/qtvcp/screens/qtdragon_hd_vert/qtdragon_hd_vert_handler.py b/share/qtvcp/screens/qtdragon_hd_vert/qtdragon_hd_vert_handler.py
index dd6829fe5c7..2a3a072639b 100644
--- a/share/qtvcp/screens/qtdragon_hd_vert/qtdragon_hd_vert_handler.py
+++ b/share/qtvcp/screens/qtdragon_hd_vert/qtdragon_hd_vert_handler.py
@@ -266,14 +266,14 @@ def init_pins(self):
pin = QHAL.newPin("spindle-volts", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_pwr_changed(v))
- pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-fault", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
pin = QHAL.newPin("spindle-modbus-connection", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -288,8 +288,8 @@ def init_pins(self):
QHAL.newPin("eoffset-enable", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("eoffset-clear", QHAL.HAL_BOOL, QHAL.HAL_OUT)
self.h['eoffset-clear'] = False
- QHAL.newPin("eoffset-spindle-count", QHAL.HAL_S32, QHAL.HAL_OUT)
- QHAL.newPin("eoffset-count", QHAL.HAL_S32, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-spindle-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
pin = QHAL.newPin("eoffset-is-active", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -297,13 +297,13 @@ def init_pins(self):
pin = QHAL.newPin("eoffset-value", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.external_offset_state_changed(v))
- pin = QHAL.newPin("eoffset-zlevel-count", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("eoffset-zlevel-count", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.comp_count_changed(v))
QHAL.newPin("comp-on", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("spindle-lift-on", QHAL.HAL_BOOL, QHAL.HAL_OUT)
# MPG scrolling pin
- self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.pinValueChanged.connect(lambda p,v: self.external_mpg(v))
# dialog answer pins
diff --git a/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe.ui b/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe.ui
index 15d2c406682..ab2f0dbd144 100644
--- a/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe.ui
+++ b/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe.ui
@@ -14942,7 +14942,7 @@ SCROLL
1
- HalBar::FLOAT
+ HalBar::REAL
axis-x-load
@@ -14971,7 +14971,7 @@ SCROLL
1
- HalBar::FLOAT
+ HalBar::REAL
axis-z-load
@@ -17008,7 +17008,7 @@ SCROLL
0
- HalBar::FLOAT
+ HalBar::REAL
spindle-rpm
diff --git a/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe_handler.py b/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe_handler.py
index 698eb9de9b1..e9069833b7e 100644
--- a/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe_handler.py
+++ b/share/qtvcp/screens/qtdragon_lathe/qtdragon_lathe_handler.py
@@ -327,14 +327,14 @@ def init_pins(self):
pin = QHAL.newPin("spindle-volts", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_pwr_changed(v))
- pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-fault", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-fault", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.spindle_fault_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors-u32", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
- pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_S32, QHAL.HAL_IN)
+ pin = QHAL.newPin("spindle-modbus-errors", QHAL.HAL_SINT, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.mb_errors_changed(v))
pin = QHAL.newPin("spindle-modbus-connection", QHAL.HAL_BOOL, QHAL.HAL_IN)
@@ -349,14 +349,14 @@ def init_pins(self):
QHAL.newPin("eoffset-enable", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newPin("eoffset-clear", QHAL.HAL_BOOL, QHAL.HAL_OUT)
self.h['eoffset-clear'] = True
- QHAL.newPin("eoffset-spindle-count", QHAL.HAL_S32, QHAL.HAL_OUT)
+ QHAL.newPin("eoffset-spindle-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
pin = QHAL.newPin("eoffset-is-active", QHAL.HAL_BOOL, QHAL.HAL_IN)
pin.pinValueChanged.connect(lambda p,v: self.external_offset_state_changed(v))
# total external offset
pin = QHAL.newPin("eoffset-value", QHAL.HAL_REAL, QHAL.HAL_IN)
- self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newPin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.pinValueChanged.connect(lambda p,v: self.external_mpg(v))
# dialog answer pins
diff --git a/share/qtvcp/screens/qtplasmac/qtplasmac_handler.py b/share/qtvcp/screens/qtplasmac/qtplasmac_handler.py
index 23e54a2518f..fe3ebfd54a3 100644
--- a/share/qtvcp/screens/qtplasmac/qtplasmac_handler.py
+++ b/share/qtvcp/screens/qtplasmac/qtplasmac_handler.py
@@ -844,7 +844,7 @@ def new_process_error(self, w, kind, text):
def make_hal_pins(self):
self.consChangePin = self.h.newpin('consumable_changing', hal.Type.BOOL, hal.Dir.IN)
self.convTabDisable = self.h.newpin('conv_disable', hal.Type.BOOL, hal.Dir.IN)
- self.cutTypePin = self.h.newpin('cut_type', hal.HAL_S32, hal.Dir.IN)
+ self.cutTypePin = self.h.newpin('cut_type', hal.Type.SINT, hal.Dir.IN)
self.developmentPin = self.h.newpin('development', hal.Type.BOOL, hal.Dir.IN)
self.extAbortPin = self.h.newpin('ext_abort', hal.Type.BOOL, hal.Dir.IN)
self.extAutoVoltsEnablePin = self.h.newpin('ext_auto_volts_enable', hal.Type.BOOL, hal.Dir.IN)
@@ -862,7 +862,7 @@ def make_hal_pins(self):
self.extCutRecWPin = self.h.newpin('ext_cutrec_w', hal.Type.BOOL, hal.Dir.IN)
self.extCutRecNWPin = self.h.newpin('ext_cutrec_nw', hal.Type.BOOL, hal.Dir.IN)
self.extFramingPin = self.h.newpin('ext_frame_job', hal.Type.BOOL, hal.Dir.IN)
- self.extHeightOvrCountsPin = self.h.newpin('ext_height_ovr_counts', hal.HAL_S32, hal.Dir.IN)
+ self.extHeightOvrCountsPin = self.h.newpin('ext_height_ovr_counts', hal.Type.SINT, hal.Dir.IN)
self.extHeightOvrCountEnablePin = self.h.newpin('ext_height_ovr_count_enable', hal.Type.BOOL, hal.Dir.IN)
self.extHeightOvrMinusPin = self.h.newpin('ext_height_ovr_minus', hal.Type.BOOL, hal.Dir.IN)
self.extHeightOvrPlusPin = self.h.newpin('ext_height_ovr_plus', hal.Type.BOOL, hal.Dir.IN)
@@ -894,19 +894,19 @@ def make_hal_pins(self):
self.laserOnPin = self.h.newpin('laser_on', hal.Type.BOOL, hal.Dir.OUT)
self.offsetSetProbePin = self.h.newpin('offset_set_probe', hal.Type.BOOL, hal.Dir.OUT)
self.offsetSetScribePin = self.h.newpin('offset_set_scribe', hal.Type.BOOL, hal.Dir.OUT)
- self.laserRecStatePin = self.h.newpin('laser_recovery_state', hal.HAL_S32, hal.Dir.IN)
- self.materialChangePin = self.h.newpin('material_change', hal.HAL_S32, hal.Dir.IN)
- self.materialChangeNumberPin = self.h.newpin('material_change_number', hal.HAL_S32, hal.Dir.IN)
+ self.laserRecStatePin = self.h.newpin('laser_recovery_state', hal.Type.SINT, hal.Dir.IN)
+ self.materialChangePin = self.h.newpin('material_change', hal.Type.SINT, hal.Dir.IN)
+ self.materialChangeNumberPin = self.h.newpin('material_change_number', hal.Type.SINT, hal.Dir.IN)
self.materialChangeTimeoutPin = self.h.newpin('material_change_timeout', hal.Type.BOOL, hal.Dir.IN)
self.materialReloadPin = self.h.newpin('material_reload', hal.Type.BOOL, hal.Dir.IN)
- self.materialTempPin = self.h.newpin('material_temp', hal.HAL_S32, hal.Dir.IN)
+ self.materialTempPin = self.h.newpin('material_temp', hal.Type.SINT, hal.Dir.IN)
self.offsetsActivePin = self.h.newpin('offsets_active', hal.Type.BOOL, hal.Dir.IN)
self.ohmicLedInPin = self.h.newpin('ohmic_led_in', hal.Type.BOOL, hal.Dir.IN)
self.paramTabDisable = self.h.newpin('param_disable', hal.Type.BOOL, hal.Dir.IN)
self.settingsTabDisable = self.h.newpin('settings_disable', hal.Type.BOOL, hal.Dir.IN)
self.simStyleUpdate = self.h.newpin('sim_style_update', hal.Type.BOOL, hal.Dir.OUT)
- self.plasmacStatePin = self.h.newpin('plasmac_state', hal.HAL_S32, hal.Dir.IN)
- self.plasmacStopPin = self.h.newpin('plasmac_stop', hal.HAL_S32, hal.Dir.IN)
+ self.plasmacStatePin = self.h.newpin('plasmac_state', hal.Type.SINT, hal.Dir.IN)
+ self.plasmacStopPin = self.h.newpin('plasmac_stop', hal.Type.SINT, hal.Dir.IN)
self.pmx485CurrentPin = self.h.newpin('pmx485_current', hal.Type.REAL, hal.Dir.IN)
self.pmx485CurrentMaxPin = self.h.newpin('pmx485_current_max', hal.Type.REAL, hal.Dir.IN)
self.pmx485CurrentMinPin = self.h.newpin('pmx485_current_min', hal.Type.REAL, hal.Dir.IN)
@@ -928,7 +928,7 @@ def make_hal_pins(self):
self.xOffsetPin = self.h.newpin('x_offset', hal.Type.REAL, hal.Dir.IN)
self.yOffsetPin = self.h.newpin('y_offset', hal.Type.REAL, hal.Dir.IN)
self.zHeightPin = self.h.newpin('z_height', hal.Type.REAL, hal.Dir.IN)
- self.zOffsetPin = self.h.newpin('z_offset_counts', hal.HAL_S32, hal.Dir.IN)
+ self.zOffsetPin = self.h.newpin('z_offset_counts', hal.Type.SINT, hal.Dir.IN)
self.xMinPierceExtentPin = self.h.newpin('x_min_pierce_extent', hal.Type.REAL, hal.Dir.IN)
self.xMaxPierceExtentPin = self.h.newpin('x_max_pierce_extent', hal.Type.REAL, hal.Dir.IN)
self.yMinPierceExtentPin = self.h.newpin('y_min_pierce_extent', hal.Type.REAL, hal.Dir.IN)
diff --git a/share/qtvcp/screens/qttouchy/qttouchy_handler.py b/share/qtvcp/screens/qttouchy/qttouchy_handler.py
index 0da4e405dd4..69a66c97f37 100644
--- a/share/qtvcp/screens/qttouchy/qttouchy_handler.py
+++ b/share/qtvcp/screens/qttouchy/qttouchy_handler.py
@@ -57,7 +57,7 @@ def __init__(self, halcomp,widgets,paths):
def initialized__(self):
KEYBIND.add_call('Key_F12','on_keycall_F12')
- self.pin_mpg_in = QHAL.newpin('mpg-in',QHAL.HAL_S32, QHAL.HAL_IN)
+ self.pin_mpg_in = QHAL.newpin('mpg-in',QHAL.HAL_SINT, QHAL.HAL_IN)
self.pin_mpg_in.value_changed.connect(lambda s: self.external_mpg(s))
self.pin_cycle_start_in = QHAL.newpin('cycle-start-in',QHAL.HAL_BOOL, QHAL.HAL_IN)
diff --git a/share/qtvcp/screens/woodpecker/woodpecker_handler.py b/share/qtvcp/screens/woodpecker/woodpecker_handler.py
index 622642c1c7c..7b254d3727c 100644
--- a/share/qtvcp/screens/woodpecker/woodpecker_handler.py
+++ b/share/qtvcp/screens/woodpecker/woodpecker_handler.py
@@ -250,18 +250,18 @@ def init_pins(self):
pin.value_changed.connect(self.spindle_pwr_changed)
pin = QHAL.newpin("spindle-volts", QHAL.HAL_REAL, QHAL.HAL_IN)
pin.value_changed.connect(self.spindle_pwr_changed)
- pin = QHAL.newpin("spindle-fault", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newpin("spindle-fault", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.value_changed.connect(self.spindle_fault_changed)
- pin = QHAL.newpin("spindle-modbus-errors", QHAL.HAL_U32, QHAL.HAL_IN)
+ pin = QHAL.newpin("spindle-modbus-errors", QHAL.HAL_UINT, QHAL.HAL_IN)
pin.value_changed.connect(self.mb_errors_changed)
QHAL.newpin("spindle-inhibit", QHAL.HAL_BOOL, QHAL.HAL_OUT)
# external offset control pins
QHAL.newpin("eoffset-enable", QHAL.HAL_BOOL, QHAL.HAL_OUT)
QHAL.newpin("eoffset-clear", QHAL.HAL_BOOL, QHAL.HAL_OUT)
- QHAL.newpin("eoffset-count", QHAL.HAL_S32, QHAL.HAL_OUT)
+ QHAL.newpin("eoffset-count", QHAL.HAL_SINT, QHAL.HAL_OUT)
pin = QHAL.newpin("eoffset-value", QHAL.HAL_REAL, QHAL.HAL_IN)
- self.pin_mpg_in = self.h.newpin('mpg-in',hal.HAL_S32, hal.Dir.IN)
+ self.pin_mpg_in = self.h.newpin('mpg-in',hal.Type.SINT, hal.Dir.IN)
self.pin_mpg_in.value_changed.connect(lambda s: self.external_mpg(s))
self.wheel_x = self.h.newpin('jog.wheel.x',hal.Type.BOOL, hal.Dir.OUT)
self.wheel_y = self.h.newpin('jog.wheel.y',hal.Type.BOOL, hal.Dir.OUT)
diff --git a/src/Makefile b/src/Makefile
index c05d9071f95..29e33f377f8 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -564,7 +564,7 @@ genclean:
-rm -f ../lib/*.so.[0-9]*
-rm -rf ../docs/build/man
-rm -f ../rtlib/*.$(MODULE_EXT)
- -rm -f hal/components/conv_*.comp
+ -rm -f $(patsubst %,hal/components/%,$(notdir $(CONVERTERS)))
pycheck-python-files:
@echo 'Checking *.py files for python3 compatibility...'
diff --git a/src/emc/ini/inihal.cc b/src/emc/ini/inihal.cc
index ba987919670..69c5fa938fd 100644
--- a/src/emc/ini/inihal.cc
+++ b/src/emc/ini/inihal.cc
@@ -50,12 +50,12 @@ static ptr_inihal_data *the_inihal_data;
fprintf(stderr,"Changed: "#NAME" %g-->%g\n",old_inihal_data.NAME, \
new_inihal_data.NAME);
#define SHOW_CHANGE_INT(NAME) \
- fprintf(stderr,"Changed: "#NAME" %d-->%d\n",old_inihal_data.NAME, \
+ fprintf(stderr,"Changed: "#NAME" %ld-->%ld\n",old_inihal_data.NAME, \
new_inihal_data.NAME);
#define SHOW_CHANGE_ARC_BLEND() \
fprintf(stderr,"Changed: blend_enable: %d-->%d\n"\
" blend_fallback_enable: %d-->%d\n"\
- " optimization_depth: %d-->%d\n"\
+ " optimization_depth: %ld-->%ld\n"\
" gap_cycles: %f-->%f\n"\
" ramp_freq: %f-->%f\n"\
,old_inihal_data.traj_arc_blend_enable \
@@ -74,7 +74,7 @@ static ptr_inihal_data *the_inihal_data;
fprintf(stderr,"Changed: "#NAME"[%d] %g-->%g\n",IDX,old_inihal_data.NAME[IDX], \
new_inihal_data.NAME[IDX]);
#define SHOW_CHANGE_IDX_INT(NAME,IDX) \
- fprintf(stderr,"Changed: "#NAME"[%d] %d-->%d\n",IDX,old_inihal_data.NAME[IDX], \
+ fprintf(stderr,"Changed: "#NAME"[%d] %ld-->%ld\n",IDX,old_inihal_data.NAME[IDX], \
new_inihal_data.NAME[IDX]);
#define MAKE_BIT_PIN(NAME,DIR) \
do { \
@@ -82,15 +82,15 @@ do { \
if (retval < 0) return retval; \
} while (0)
-#define MAKE_S32_PIN(NAME,DIR) \
+#define MAKE_SINT_PIN(NAME,DIR) \
do { \
- int retval = hal_pin_new_si32(comp_id, DIR, &(the_inihal_data->NAME), 0, PREFIX#NAME); \
+ int retval = hal_pin_new_sint(comp_id, DIR, &(the_inihal_data->NAME), 0, PREFIX#NAME); \
if (retval < 0) return retval; \
} while (0)
-#define MAKE_S32_PIN_IDX(NAME,HALPIN_NAME,DIR,IDX) \
+#define MAKE_SINT_PIN_IDX(NAME,HALPIN_NAME,DIR,IDX) \
do { \
- int retval = hal_pin_new_si32(comp_id, DIR, &(the_inihal_data->NAME[IDX]),\
+ int retval = hal_pin_new_sint(comp_id, DIR, &(the_inihal_data->NAME[IDX]),\
0, PREFIX"%d."#HALPIN_NAME, IDX); \
if (retval < 0) return retval; \
} while (0)
@@ -116,7 +116,7 @@ do { \
} while (0)
#define INIT_PIN_R(NAME) hal_set_real(the_inihal_data->NAME, old_inihal_data.NAME);
-#define INIT_PIN_S(NAME) hal_set_si32(the_inihal_data->NAME, old_inihal_data.NAME);
+#define INIT_PIN_S(NAME) hal_set_sint(the_inihal_data->NAME, old_inihal_data.NAME);
#define INIT_PIN_B(NAME) hal_set_bool(the_inihal_data->NAME, old_inihal_data.NAME);
int ini_hal_exit(void)
@@ -154,7 +154,7 @@ int ini_hal_init(int numjoints)
MAKE_FLOAT_PIN_IDX(joint_jerk,max_jerk,HAL_IN,idx);
MAKE_FLOAT_PIN_IDX(joint_home,home,HAL_IN,idx);
MAKE_FLOAT_PIN_IDX(joint_home_offset,home_offset,HAL_IN,idx);
- MAKE_S32_PIN_IDX( joint_home_sequence,home_sequence,HAL_IN,idx);
+ MAKE_SINT_PIN_IDX( joint_home_sequence,home_sequence,HAL_IN,idx);
}
for (int idx = 0; idx < EMCMOT_MAX_AXIS; idx++) {
char letter = "xyzabcuvw"[idx];
@@ -170,12 +170,12 @@ int ini_hal_init(int numjoints)
MAKE_FLOAT_PIN(traj_default_acceleration,HAL_IN);
MAKE_FLOAT_PIN(traj_max_acceleration,HAL_IN);
MAKE_FLOAT_PIN(traj_max_jerk,HAL_IN);
- MAKE_S32_PIN(traj_planner_type,HAL_IN);
+ MAKE_SINT_PIN(traj_planner_type,HAL_IN);
MAKE_FLOAT_PIN(traj_scurve_peak_scale,HAL_IN);
MAKE_BIT_PIN(traj_arc_blend_enable,HAL_IN);
MAKE_BIT_PIN(traj_arc_blend_fallback_enable,HAL_IN);
- MAKE_S32_PIN(traj_arc_blend_optimization_depth,HAL_IN);
+ MAKE_SINT_PIN(traj_arc_blend_optimization_depth,HAL_IN);
MAKE_FLOAT_PIN(traj_arc_blend_gap_cycles,HAL_IN);
MAKE_FLOAT_PIN(traj_arc_blend_ramp_freq,HAL_IN);
MAKE_FLOAT_PIN(traj_arc_blend_tangent_kink_ratio,HAL_IN);
diff --git a/src/emc/ini/inihal.hh b/src/emc/ini/inihal.hh
index 1cef6da97d1..6d75a936707 100644
--- a/src/emc/ini/inihal.hh
+++ b/src/emc/ini/inihal.hh
@@ -47,13 +47,6 @@ int ini_hal_init_pins(int numjoints);
[JOINT_n]COMP_FILE_TYPE
[JOINT_n]COMP
*/
-// FIXME: This will have to go again when we do proper 64-bit
-// The typedefs are necessary to map to hal_[gs]et_[su]i32() in the expansion
-// of below macros because they are selected based on text-concatenation in the
-// preprocessor. Even the 32-bit version use sint/uint, but the expansion would
-// then select the 64-bit versions.
-typedef hal_sint_t hal_si32_t;
-typedef hal_uint_t hal_ui32_t;
#define HAL_FIELDS \
FIELD(real,traj_default_velocity) \
@@ -61,12 +54,12 @@ typedef hal_uint_t hal_ui32_t;
FIELD(real,traj_default_acceleration) \
FIELD(real,traj_max_acceleration) \
FIELD(real,traj_max_jerk) \
- FIELD(si32,traj_planner_type) \
+ FIELD(sint,traj_planner_type) \
FIELD(real,traj_scurve_peak_scale) \
\
FIELD(bool,traj_arc_blend_enable) \
FIELD(bool,traj_arc_blend_fallback_enable) \
- FIELD(si32,traj_arc_blend_optimization_depth) \
+ FIELD(sint,traj_arc_blend_optimization_depth) \
FIELD(real,traj_arc_blend_gap_cycles) \
FIELD(real,traj_arc_blend_ramp_freq) \
FIELD(real,traj_arc_blend_tangent_kink_ratio) \
@@ -81,7 +74,7 @@ typedef hal_uint_t hal_ui32_t;
ARRAY(real,joint_jerk,EMCMOT_MAX_JOINTS) \
ARRAY(real,joint_home,EMCMOT_MAX_JOINTS) \
ARRAY(real,joint_home_offset,EMCMOT_MAX_JOINTS) \
- ARRAY(si32,joint_home_sequence,EMCMOT_MAX_JOINTS) \
+ ARRAY(sint,joint_home_sequence,EMCMOT_MAX_JOINTS) \
\
ARRAY(real,axis_min_limit,EMCMOT_MAX_AXIS) \
ARRAY(real,axis_max_limit,EMCMOT_MAX_AXIS) \
@@ -100,12 +93,8 @@ struct PTR {
#endif
template struct NATIVE {};
template<> struct NATIVE { typedef rtapi_bool type; };
-template<> struct NATIVE { typedef rtapi_s32 type; };
-template<> struct NATIVE { typedef rtapi_u32 type; };
-// FIXME: These need to be 64-bit. Can't set them now because the compiler sees
-// the typedef mapped overlap.
-//template<> struct NATIVE { typedef rtapi_sint type; };
-//template<> struct NATIVE { typedef rtapi_uint type; };
+template<> struct NATIVE { typedef rtapi_sint type; };
+template<> struct NATIVE { typedef rtapi_uint type; };
template<> struct NATIVE { typedef rtapi_real type; };
struct VALUE {
template struct field { typedef typename NATIVE::type type; };
diff --git a/src/emc/motion/axis.c b/src/emc/motion/axis.c
index 9e1908a6aa4..4cc55035c0e 100644
--- a/src/emc/motion/axis.c
+++ b/src/emc/motion/axis.c
@@ -16,14 +16,14 @@ typedef struct {
double jerk_limit; /* upper limit of axis jerk */
simple_tp_t teleop_tp; /* planner for teleop mode motion */
- int old_ajog_counts; /* prior value, used for deltas */
+ rtapi_sint old_ajog_counts; /* prior value, used for deltas */
int kb_ajog_active; /* non-zero during a keyboard jog */
int wheel_ajog_active; /* non-zero during a wheel jog */
int locking_joint; /* locking_joint number, -1 ==> notused */
double ext_offset_vel_limit; /* upper limit of axis speed for ext offset */
double ext_offset_acc_limit; /* upper limit of axis accel for ext offset */
- int old_eoffset_counts;
+ rtapi_sint old_eoffset_counts;
simple_tp_t ext_offset_tp; /* planner for external coordinate offsets*/
} emcmot_axis_t;
@@ -102,7 +102,7 @@ static int export_axis(int mot_comp_id, char c, axis_hal_t * addr)
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->ajog_enable), 0, "axis.%c.jog-enable", c));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_IN, &(addr->ajog_scale), 0.0, "axis.%c.jog-scale", c));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_IN, &(addr->ajog_counts), 0, "axis.%c.jog-counts", c));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_IN, &(addr->ajog_counts), 0, "axis.%c.jog-counts", c));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->ajog_vel_mode), 0, "axis.%c.jog-vel-mode", c));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(addr->kb_ajog_active), 0, "axis.%c.kb-jog-active", c));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(addr->wheel_ajog_active), 0, "axis.%c.wheel-jog-active", c));
@@ -135,7 +135,7 @@ int axis_init_hal_io(int mot_comp_id)
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &axis_data->teleop_tp_enable, 0, "axis.%c.teleop-tp-enable",c));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &axis_data->eoffset_enable, 0, "axis.%c.eoffset-enable", c));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &axis_data->eoffset_clear, 0, "axis.%c.eoffset-clear", c));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_IN, &axis_data->eoffset_counts, 0, "axis.%c.eoffset-counts", c));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_IN, &axis_data->eoffset_counts, 0, "axis.%c.eoffset-counts", c));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_IN, &axis_data->eoffset_scale, 0.0, "axis.%c.eoffset-scale", c));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &axis_data->external_offset, 0.0, "axis.%c.eoffset", c));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &axis_data->external_offset_requested,
@@ -370,7 +370,7 @@ void axis_handle_jogwheels(bool motion_teleop_flag, bool motion_enable_flag, boo
int axis_num;
emcmot_axis_t *axis;
axis_hal_t *axis_data;
- int new_ajog_counts, delta;
+ rtapi_sint new_ajog_counts, delta;
double distance, pos, stop_dist;
static int first_pass = 1; /* used to set initial conditions */
@@ -486,7 +486,7 @@ bool axis_plan_external_offsets(double servo_period, bool motion_enable_flag, bo
int n;
emcmot_axis_t *axis;
axis_hal_t *axis_data;
- int new_eoffset_counts, delta;
+ rtapi_sint new_eoffset_counts, delta;
static int last_eoffset_enable[EMCMOT_MAX_AXIS];
double ext_offset_epsilon;
bool eoffset_active = 0;
@@ -499,7 +499,7 @@ bool axis_plan_external_offsets(double servo_period, bool motion_enable_flag, bo
axis_data = &hal_data->axis[n];
- new_eoffset_counts = hal_get_si32(axis_data->eoffset_counts);
+ new_eoffset_counts = hal_get_sint(axis_data->eoffset_counts);
delta = new_eoffset_counts - axis->old_eoffset_counts;
axis->old_eoffset_counts = new_eoffset_counts;
diff --git a/src/emc/motion/command.c b/src/emc/motion/command.c
index 17e9c767a37..c4bfcbb76d0 100644
--- a/src/emc/motion/command.c
+++ b/src/emc/motion/command.c
@@ -1879,7 +1879,7 @@ void emcmotCommandHandler_locked(void *arg, long servo_period)
// https://github.com/LinuxCNC/linuxcnc/issues/3389
hal_set_real(emcmot_hal_data->spindle[n].spindle_orient_angle, emcmotCommand->orientation);
- hal_set_si32(emcmot_hal_data->spindle[n].spindle_orient_mode, emcmotCommand->mode);
+ hal_set_sint(emcmot_hal_data->spindle[n].spindle_orient_mode, emcmotCommand->mode);
hal_set_bool(emcmot_hal_data->spindle[n].spindle_locked, 0);
hal_set_bool(emcmot_hal_data->spindle[n].spindle_orient, 1);
diff --git a/src/emc/motion/control.c b/src/emc/motion/control.c
index 43ad5854168..17fb96b7ddd 100644
--- a/src/emc/motion/control.c
+++ b/src/emc/motion/control.c
@@ -56,7 +56,7 @@ KINEMATICS_INVERSE_FLAGS iflags = 0;
************************************************************************/
/* the (nominal) period the last time the motion handler was invoked */
-static unsigned long last_period = 0;
+static rtapi_uint last_period = 0;
/* servo cycle time */
static double servo_period;
@@ -229,8 +229,8 @@ void emcmotController(void *arg, long period)
static long long int last = 0;
long long int now = rtapi_get_time();
- long int this_run = (long int)(now - last);
- hal_set_ui32(emcmot_hal_data->last_period, this_run);
+ rtapi_sint this_run = (rtapi_sint)(now - last);
+ hal_set_uint(emcmot_hal_data->last_period, this_run);
// we need this for next time
last = now;
@@ -239,7 +239,7 @@ void emcmotController(void *arg, long period)
/* calculate servo period as a double - period is in integer nsec */
servo_period = period * 0.000000001;
- if(period != (long)last_period) {
+ if((rtapi_uint)period != last_period) {
emcmotSetCycleTime(period);
last_period = period;
}
@@ -589,12 +589,12 @@ static void process_inputs(void)
emcmotStatus->spindle_status[spindle_num].fault = 0;
}
if (hal_get_bool(emcmot_hal_data->spindle[spindle_num].spindle_orient)) {
- if (hal_get_si32(emcmot_hal_data->spindle[spindle_num].spindle_orient_fault)) {
+ if (hal_get_sint(emcmot_hal_data->spindle[spindle_num].spindle_orient_fault)) {
emcmotStatus->spindle_status[spindle_num].orient_state = EMCMOT_ORIENT_FAULTED;
hal_set_bool(emcmot_hal_data->spindle[spindle_num].spindle_orient, 0);
emcmotStatus->spindle_status[spindle_num].orient_fault =
- hal_get_si32(emcmot_hal_data->spindle[spindle_num].spindle_orient_fault);
- reportError(_("fault %d during orient in progress"),
+ hal_get_sint(emcmot_hal_data->spindle[spindle_num].spindle_orient_fault);
+ reportError(_("fault %ld during orient in progress"),
emcmotStatus->spindle_status[spindle_num].orient_fault);
emcmotStatus->commandStatus = EMCMOT_COMMAND_INVALID_COMMAND;
tpAbort(&emcmotInternal->coord_tp);
@@ -1110,7 +1110,7 @@ static void handle_jjogwheels(void)
int joint_num;
emcmot_joint_t *joint;
joint_hal_t *joint_data;
- int new_jjog_counts, delta;
+ rtapi_sint new_jjog_counts, delta;
double distance, pos, stop_dist;
static int first_pass = 1; /* used to set initial conditions */
@@ -1133,7 +1133,7 @@ static void handle_jjogwheels(void)
jaccel_limit = jjog_accel_fraction * joint->acc_limit;
}
/* get counts from jogwheel */
- new_jjog_counts = hal_get_si32(joint_data->jjog_counts);
+ new_jjog_counts = hal_get_sint(joint_data->jjog_counts);
delta = new_jjog_counts - joint->old_jjog_counts;
/* save value for next time */
joint->old_jjog_counts = new_jjog_counts;
@@ -1972,9 +1972,9 @@ static void output_to_hal(void)
/* Performance Metadata */
hal_set_real(emcmot_hal_data->interp_feedrate, emcmotStatus->tag.fields_float[GM_FIELD_FLOAT_FEED]);
- /* Line and Motion Type (Casting to int for s32 HAL pins) */
- hal_set_si32(emcmot_hal_data->interp_line_number, (int)emcmotStatus->tag.fields[GM_FIELD_LINE_NUMBER]);
- hal_set_si32(emcmot_hal_data->interp_motion_type, (int)emcmotStatus->tag.fields[GM_FIELD_MOTION_MODE]);
+ /* Line and Motion Type (implicitly casted to integer for sint HAL pins) */
+ hal_set_sint(emcmot_hal_data->interp_line_number, emcmotStatus->tag.fields[GM_FIELD_LINE_NUMBER]);
+ hal_set_sint(emcmot_hal_data->interp_motion_type, emcmotStatus->tag.fields[GM_FIELD_MOTION_MODE]);
hal_set_bool(emcmot_hal_data->iscircle, (emcmotStatus->tag.packed_flags & (1UL << GM_FLAG_IS_CIRCLE)) != 0);
switch (emcmotStatus->motionType) {
case EMC_MOTION_TYPE_FEED: //fall thru
@@ -2048,9 +2048,9 @@ static void output_to_hal(void)
emcmotStatus->spindle_status[spindle_num].speed / 60.);
}
- hal_set_si32(emcmot_hal_data->program_line, emcmotStatus->id);
+ hal_set_sint(emcmot_hal_data->program_line, emcmotStatus->id);
hal_set_bool(emcmot_hal_data->tp_reverse, emcmotStatus->reverse_run);
- hal_set_si32(emcmot_hal_data->motion_type, emcmotStatus->motionType);
+ hal_set_sint(emcmot_hal_data->motion_type, emcmotStatus->motionType);
hal_set_real(emcmot_hal_data->distance_to_go, emcmotStatus->distance_to_go);
if(GET_MOTION_COORD_FLAG()) {
hal_set_real(emcmot_hal_data->current_vel, emcmotStatus->current_vel);
@@ -2076,14 +2076,14 @@ static void output_to_hal(void)
to one of the debug parameters. You can also comment out these lines
and copy elsewhere if you want to observe an automatic variable that
isn't in scope here. */
- hal_set_bool(emcmot_hal_data->debug_bit_0, joints[1].free_tp.active);
- hal_set_bool(emcmot_hal_data->debug_bit_1, emcmotStatus->enables_new & AF_ENABLED);
- hal_set_real(emcmot_hal_data->debug_float_0, emcmotStatus->spindle_status[0].speed);
- hal_set_real(emcmot_hal_data->debug_float_1, emcmotStatus->spindleSync);
- hal_set_real(emcmot_hal_data->debug_float_2, emcmotStatus->vel);
- hal_set_real(emcmot_hal_data->debug_float_3, emcmotStatus->spindle_status[0].net_scale);
- hal_set_si32(emcmot_hal_data->debug_s32_0, emcmotStatus->overrideLimitMask);
- hal_set_si32(emcmot_hal_data->debug_s32_1, emcmotStatus->tcqlen);
+ hal_set_bool(emcmot_hal_data->debug_bool_0, joints[1].free_tp.active);
+ hal_set_bool(emcmot_hal_data->debug_bool_1, emcmotStatus->enables_new & AF_ENABLED);
+ hal_set_real(emcmot_hal_data->debug_real_0, emcmotStatus->spindle_status[0].speed);
+ hal_set_real(emcmot_hal_data->debug_real_1, emcmotStatus->spindleSync);
+ hal_set_real(emcmot_hal_data->debug_real_2, emcmotStatus->vel);
+ hal_set_real(emcmot_hal_data->debug_real_3, emcmotStatus->spindle_status[0].net_scale);
+ hal_set_sint(emcmot_hal_data->debug_sint_0, emcmotStatus->overrideLimitMask);
+ hal_set_sint(emcmot_hal_data->debug_sint_1, emcmotStatus->tcqlen);
/* two way handshaking for the spindle encoder */
for (spindle_num = 0; spindle_num < emcmotConfig->numSpindles; spindle_num++){
@@ -2302,7 +2302,7 @@ static void update_status(void)
// Get the current executing trajectory component (the "Source of Truth")
/* Update the HAL Output Pins from the active tag */
// Line and Motion Type
- hal_set_si32(emcmot_hal_data->interp_line_number, (int)emcmotStatus->tag.fields[GM_FIELD_LINE_NUMBER]);
+ hal_set_sint(emcmot_hal_data->interp_line_number, emcmotStatus->tag.fields[GM_FIELD_LINE_NUMBER]);
// Performance Metadata
hal_set_real(emcmot_hal_data->interp_feedrate, emcmotStatus->tag.fields_float[GM_FIELD_FLOAT_FEED]);
diff --git a/src/emc/motion/homing.c b/src/emc/motion/homing.c
index 662cd2f3591..04c26e4338d 100644
--- a/src/emc/motion/homing.c
+++ b/src/emc/motion/homing.c
@@ -249,7 +249,7 @@ static int base_make_joint_home_pins(int id,int njoints)
0, "joint.%d.homing", jno);
retval += hal_pin_new_bool(id, HAL_OUT, &(addr->homed),
0, "joint.%d.homed", jno);
- retval += hal_pin_new_si32(id, HAL_OUT, &(addr->home_state),
+ retval += hal_pin_new_sint(id, HAL_OUT, &(addr->home_state),
0, "joint.%d.home-state", jno);
retval += hal_pin_new_bool(id, HAL_IO, &(addr->index_enable),
0, "joint.%d.index-enable", jno);
@@ -558,7 +558,7 @@ static void base_write_homing_out_pins(int njoints)
hal_set_bool(addr->homing, H[jno].homing);
}
hal_set_bool(addr->homed, H[jno].homed); // OUT
- hal_set_si32(addr->home_state, H[jno].home_state); // OUT
+ hal_set_sint(addr->home_state, H[jno].home_state); // OUT
// index_enable is a HAL_IO pin: the encoder driver also writes it
// (clears it on the index pulse). We do not own it, so we must not
// clamp it every cycle; drive it only on our own edges and otherwise
diff --git a/src/emc/motion/mot_priv.h b/src/emc/motion/mot_priv.h
index a996e183fa6..954de98dd84 100644
--- a/src/emc/motion/mot_priv.h
+++ b/src/emc/motion/mot_priv.h
@@ -148,14 +148,14 @@ typedef struct {
hal_real_t requested_vel; /* RPI: requested velocity magnitude in machine units */
hal_real_t distance_to_go; /* RPI: distance to go in current move*/
- hal_bool_t debug_bit_0; /* RPA: generic param, for debugging */
- hal_bool_t debug_bit_1; /* RPA: generic param, for debugging */
- hal_real_t debug_float_0; /* RPA: generic param, for debugging */
- hal_real_t debug_float_1; /* RPA: generic param, for debugging */
- hal_real_t debug_float_2; /* RPA: generic param, for debugging */
- hal_real_t debug_float_3; /* RPA: generic param, for debugging */
- hal_sint_t debug_s32_0; /* RPA: generic param, for debugging */
- hal_sint_t debug_s32_1; /* RPA: generic param, for debugging */
+ hal_bool_t debug_bool_0; /* RPA: generic param, for debugging */
+ hal_bool_t debug_bool_1; /* RPA: generic param, for debugging */
+ hal_real_t debug_real_0; /* RPA: generic param, for debugging */
+ hal_real_t debug_real_1; /* RPA: generic param, for debugging */
+ hal_real_t debug_real_2; /* RPA: generic param, for debugging */
+ hal_real_t debug_real_3; /* RPA: generic param, for debugging */
+ hal_sint_t debug_sint_0; /* RPA: generic param, for debugging */
+ hal_sint_t debug_sint_1; /* RPA: generic param, for debugging */
hal_bool_t synch_do[EMCMOT_MAX_DIO]; /* WPI array: output pins for motion synched IO */
hal_bool_t synch_di[EMCMOT_MAX_DIO]; /* RPI array: input pins for motion synched IO */
diff --git a/src/emc/motion/motion.c b/src/emc/motion/motion.c
index b0b5acd91da..30ce42a6315 100644
--- a/src/emc/motion/motion.c
+++ b/src/emc/motion/motion.c
@@ -597,7 +597,7 @@ static int init_hal_io(void)
/* export machine wide hal pins */
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->motion_enabled), 0, "motion.motion-enabled"));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->in_position), 0, "motion.in-position"));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_OUT, &(emcmot_hal_data->motion_type), 0, "motion.motion-type"));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_OUT, &(emcmot_hal_data->motion_type), 0, "motion.motion-type"));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->coord_mode), 0, "motion.coord-mode"));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->teleop_mode), 0, "motion.teleop-mode"));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->coord_error), 0, "motion.coord-error"));
@@ -605,12 +605,12 @@ static int init_hal_io(void)
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(emcmot_hal_data->current_vel), 0.0, "motion.current-vel"));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(emcmot_hal_data->requested_vel), 0.0, "motion.requested-vel"));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(emcmot_hal_data->distance_to_go), 0.0, "motion.distance-to-go"));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_OUT, &(emcmot_hal_data->program_line), 0, "motion.program-line"));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_OUT, &(emcmot_hal_data->program_line), 0, "motion.program-line"));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(emcmot_hal_data->jog_is_active), 0, "motion.jog-is-active"));
/* Standard Interp State Pins */
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_OUT, &(emcmot_hal_data->interp_line_number), 0, "motion.interp.line-number"));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_OUT, &(emcmot_hal_data->interp_motion_type), 0, "motion.interp.motion-type"));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_OUT, &(emcmot_hal_data->interp_line_number), 0, "motion.interp.line-number"));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_OUT, &(emcmot_hal_data->interp_motion_type), 0, "motion.interp.motion-type"));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(emcmot_hal_data->interp_feedrate), 0.0, "motion.interp.feedrate"));
/* New Geometric Metadata Pins */
@@ -625,21 +625,21 @@ static int init_hal_io(void)
/* export debug parameters */
/* these can be used to view any internal variable, simply change a line
in control.c:output_to_hal() and recompile */
- CALL_CHECK(hal_param_new_bool(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_bit_0), 0, "motion.debug-bit-0"));
- CALL_CHECK(hal_param_new_bool(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_bit_1), 0, "motion.debug-bit-1"));
- CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_float_0), 0.0, "motion.debug-float-0"));
- CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_float_1), 0.0, "motion.debug-float-1"));
- CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_float_2), 0.0, "motion.debug-float-2"));
- CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_float_3), 0.0, "motion.debug-float-3"));
- CALL_CHECK(hal_param_new_si32(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_s32_0), 0, "motion.debug-s32-0"));
- CALL_CHECK(hal_param_new_si32(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_s32_1), 0, "motion.debug-s32-1"));
+ CALL_CHECK(hal_param_new_bool(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_bool_0), 0, "motion.debug-bool-0"));
+ CALL_CHECK(hal_param_new_bool(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_bool_1), 0, "motion.debug-bool-1"));
+ CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_real_0), 0.0, "motion.debug-real-0"));
+ CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_real_1), 0.0, "motion.debug-real-1"));
+ CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_real_2), 0.0, "motion.debug-real-2"));
+ CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_real_3), 0.0, "motion.debug-real-3"));
+ CALL_CHECK(hal_param_new_sint(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_sint_0), 0, "motion.debug-sint-0"));
+ CALL_CHECK(hal_param_new_sint(mot_comp_id, HAL_RO, &(emcmot_hal_data->debug_sint_1), 0, "motion.debug-sint-1"));
// FIXME - debug only, remove later
// export HAL parameters for some trajectory planner internal variables
// so they can be scoped
CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->traj_pos_out), 0.0, "traj.pos_out"));
CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->traj_vel_out), 0.0, "traj.vel_out"));
- CALL_CHECK(hal_param_new_ui32(mot_comp_id, HAL_RO, &(emcmot_hal_data->traj_active_tc), 0, "traj.active_tc"));
+ CALL_CHECK(hal_param_new_uint(mot_comp_id, HAL_RO, &(emcmot_hal_data->traj_active_tc), 0, "traj.active_tc"));
for (n = 0; n < 4; n++) {
CALL_CHECK(hal_param_new_real(mot_comp_id, HAL_RO, &(emcmot_hal_data->tc_pos[n]), 0.0, "tc.%d.pos", n));
@@ -649,7 +649,7 @@ static int init_hal_io(void)
// end of exporting trajectory planner internals
// export timing related HAL pins so they can be scoped and/or connected
- CALL_CHECK(hal_pin_new_ui32(mot_comp_id, HAL_OUT, &(emcmot_hal_data->last_period), 0, "motion.servo.last-period"));
+ CALL_CHECK(hal_pin_new_uint(mot_comp_id, HAL_OUT, &(emcmot_hal_data->last_period), 0, "motion.servo.last-period"));
// export timing related HAL pins so they can be scoped
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(emcmot_hal_data->tooloffset_x), 0.0, "motion.tooloffset.x"));
@@ -728,11 +728,11 @@ static int export_spindle(int num, spindle_hal_t * addr){
// spindle orient pins
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_OUT, &(addr->spindle_orient_angle), 0.0, "spindle.%d.orient-angle", num));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_OUT, &(addr->spindle_orient_mode), 0, "spindle.%d.orient-mode", num));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_OUT, &(addr->spindle_orient_mode), 0, "spindle.%d.orient-mode", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(addr->spindle_orient), 0, "spindle.%d.orient", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(addr->spindle_locked), 0, "spindle.%d.locked", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->spindle_is_oriented), 0, "spindle.%d.is-oriented", num));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_IN, &(addr->spindle_orient_fault), 0, "spindle.%d.orient-fault", num));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_IN, &(addr->spindle_orient_fault), 0, "spindle.%d.orient-fault", num));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_IN, &(addr->spindle_revs), 0.0, "spindle.%d.revs", num));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_IN, &(addr->spindle_speed_in), 0.0, "spindle.%d.speed-in", num));
@@ -764,7 +764,7 @@ static int export_joint(int num, joint_hal_t * addr)
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->neg_lim_sw), 0, "joint.%d.neg-lim-sw-in", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_OUT, &(addr->amp_enable), 0, "joint.%d.amp-enable-out", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->amp_fault), 0, "joint.%d.amp-fault-in", num));
- CALL_CHECK(hal_pin_new_si32(mot_comp_id, HAL_IN, &(addr->jjog_counts), 0, "joint.%d.jog-counts", num));
+ CALL_CHECK(hal_pin_new_sint(mot_comp_id, HAL_IN, &(addr->jjog_counts), 0, "joint.%d.jog-counts", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->jjog_enable), 0, "joint.%d.jog-enable", num));
CALL_CHECK(hal_pin_new_real(mot_comp_id, HAL_IN, &(addr->jjog_scale), 0.0, "joint.%d.jog-scale", num));
CALL_CHECK(hal_pin_new_bool(mot_comp_id, HAL_IN, &(addr->jjog_vel_mode), 0, "joint.%d.jog-vel-mode", num));
@@ -1027,7 +1027,7 @@ static int init_threads(void)
/* create HAL threads for each period */
/* only create base thread if it is faster than servo thread */
if (servo_base_ratio > 1) {
- retval = hal_create_thread("base-thread", base_period_nsec, base_thread_fp);
+ retval = hal_create_thread("base-thread", base_period_nsec);
if (retval < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"MOTION: failed to create %ld nsec base thread\n",
@@ -1035,7 +1035,7 @@ static int init_threads(void)
return -1;
}
}
- retval = hal_create_thread("servo-thread", servo_period_nsec, 1);
+ retval = hal_create_thread("servo-thread", servo_period_nsec);
if (retval < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"MOTION: failed to create %ld nsec servo thread\n",
@@ -1044,14 +1044,14 @@ static int init_threads(void)
}
/* export realtime functions that do the real work */
retval = hal_export_funct("motion-controller", emcmotController, 0 /* arg
- */ , 1 /* uses_fp */ , 0 /* reentrant */ , mot_comp_id);
+ */ , 0 /* reentrant */ , mot_comp_id);
if (retval < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"MOTION: failed to export controller function\n");
return -1;
}
retval = hal_export_funct("motion-command-handler", emcmotCommandHandler, 0 /* arg
- */ , 1 /* uses_fp */ , 0 /* reentrant */ , mot_comp_id);
+ */ , 0 /* reentrant */ , mot_comp_id);
if (retval < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"MOTION: failed to export command handler function\n");
diff --git a/src/emc/motion/motion.h b/src/emc/motion/motion.h
index b107b232811..9ec430b7ee1 100644
--- a/src/emc/motion/motion.h
+++ b/src/emc/motion/motion.h
@@ -487,7 +487,7 @@ Suggestion: Split this in to an Error and a Status flag register..
double motor_offset; /* diff between internal and motor pos, used
to set position to zero during homing */
- int old_jjog_counts; /* prior value, used for deltas */
+ rtapi_sint old_jjog_counts; /* prior value, used for deltas */
double big_vel; /* used for "debouncing" velocity */
} emcmot_joint_t;
@@ -538,7 +538,7 @@ Suggestion: Split this in to an Error and a Status flag register..
int direction; // 0 stopped, 1 forward, -1 reverse
int brake; // 0 released, 1 engaged
int locked; // spindle lock engaged after orient
- int orient_fault; // fault code from motion.spindle-orient-fault
+ rtapi_sint orient_fault; // fault code from motion.spindle-orient-fault
int orient_state; // orient_state_t
int spindle_index_enable; /* hooked to a canon encoder index-enable */
double spindleRevs; /* position of spindle in revolutions */
diff --git a/src/emc/nml_intf/state_tag.h b/src/emc/nml_intf/state_tag.h
index 3bc2262aa74..2e2842733d1 100644
--- a/src/emc/nml_intf/state_tag.h
+++ b/src/emc/nml_intf/state_tag.h
@@ -26,6 +26,7 @@
#ifndef STATE_TAG_H
#define STATE_TAG_H
+#include
/**
* Enum to define bit names for StateTag's flags register.
@@ -132,7 +133,7 @@ struct state_tag_t {
// Any G / M code states that doesn't pack nicely into a single bit
// These are an array mostly because it's easier to pass an
// arbitrary-length array through NML than individual fields
- int fields[GM_FIELD_MAX_FIELDS];
+ rtapi_sint fields[GM_FIELD_MAX_FIELDS];
/** G / M mode flags for simple states like inch / mm, feedhold enable, etc.
* This stores packed bits in one field (since we can't use a bitset in a
diff --git a/src/emc/rs274ngc/interp_namedparams.cc b/src/emc/rs274ngc/interp_namedparams.cc
index fb12f1e8d26..b20fabbda34 100644
--- a/src/emc/rs274ngc/interp_namedparams.cc
+++ b/src/emc/rs274ngc/interp_namedparams.cc
@@ -327,8 +327,6 @@ int Interp::fetch_hal_param( const char *nameBuf, int *status, double *value)
assign:
switch (type) {
case HAL_BOOL: *value = (double)qval.b; break;
- case HAL_U32: *value = (double)qval.u; break;
- case HAL_S32: *value = (double)qval.s; break;
case HAL_UINT: *value = (double)qval.u; break;
case HAL_SINT: *value = (double)qval.s; break;
case HAL_REAL: *value = (double)qval.r; break;
diff --git a/src/emc/rs274ngc/rs274ngc_pre.cc b/src/emc/rs274ngc/rs274ngc_pre.cc
index d5744e27bfc..1ccb5ad67de 100644
--- a/src/emc/rs274ngc/rs274ngc_pre.cc
+++ b/src/emc/rs274ngc/rs274ngc_pre.cc
@@ -2293,7 +2293,7 @@ void Interp::print_state_tag(StateTag const &tag)
{
// Extract as-is field values directly into appropriate array
// position
- logStateTags("State tag (%s @ %p): fields LINE_NUMBER %d, MOTION_MODE %d "
+ logStateTags("State tag (%s @ %p): fields LINE_NUMBER %ld, MOTION_MODE %ld "
"ORIGIN G%0.1f; flags UNITS %s, DISTANCE_MODE %s, "
"SPINDLE_ON %s",
tag.is_valid() ? "valid" : "invalid",
diff --git a/src/emc/usr_intf/axis/scripts/hal_manualtoolchange.py b/src/emc/usr_intf/axis/scripts/hal_manualtoolchange.py
index cb4acceaff6..65ec28150ec 100644
--- a/src/emc/usr_intf/axis/scripts/hal_manualtoolchange.py
+++ b/src/emc/usr_intf/axis/scripts/hal_manualtoolchange.py
@@ -78,7 +78,7 @@ def get_tool_change_message(n):
h = hal.component("hal_manualtoolchange")
-h.newpin("number", hal.HAL_S32, hal.Dir.IN)
+h.newpin("number", hal.Type.SINT, hal.Dir.IN)
h.newpin("change", hal.Type.BOOL, hal.Dir.IN)
h.newpin("change_button", hal.Type.BOOL, hal.Dir.IN)
h.newpin("changed", hal.Type.BOOL, hal.Dir.OUT)
diff --git a/src/emc/usr_intf/gmoccapy/gmoccapy.py b/src/emc/usr_intf/gmoccapy/gmoccapy.py
index cae34386ee7..a090b7dc318 100644
--- a/src/emc/usr_intf/gmoccapy/gmoccapy.py
+++ b/src/emc/usr_intf/gmoccapy/gmoccapy.py
@@ -6434,13 +6434,13 @@ def _make_hal_pins(self):
hal_glib.GPin(pin).connect("value_changed", self._on_unlock_settings_changed)
# generate the pins to connect encoders to the sliders
- pin = self.halcomp.newpin("feed.feed-override.counts", hal.HAL_S32, hal.Dir.IN)
+ pin = self.halcomp.newpin("feed.feed-override.counts", hal.Type.SINT, hal.Dir.IN)
hal_glib.GPin(pin).connect("value_changed", self._on_counts_changed, "spc_feed")
- pin = self.halcomp.newpin("spindle.spindle-override.counts", hal.HAL_S32, hal.Dir.IN)
+ pin = self.halcomp.newpin("spindle.spindle-override.counts", hal.Type.SINT, hal.Dir.IN)
hal_glib.GPin(pin).connect("value_changed", self._on_counts_changed, "spc_spindle")
- pin = self.halcomp.newpin("jog.jog-velocity.counts", hal.HAL_S32, hal.Dir.IN)
+ pin = self.halcomp.newpin("jog.jog-velocity.counts", hal.Type.SINT, hal.Dir.IN)
hal_glib.GPin(pin).connect("value_changed", self._on_counts_changed, "spc_lin_jog_vel")
- pin = self.halcomp.newpin("rapid.rapid-override.counts", hal.HAL_S32, hal.Dir.IN)
+ pin = self.halcomp.newpin("rapid.rapid-override.counts", hal.Type.SINT, hal.Dir.IN)
hal_glib.GPin(pin).connect("value_changed", self._on_counts_changed, "spc_rapid")
self.halcomp.newpin("feed.feed-override.count-enable", hal.Type.BOOL, hal.Dir.IN)
self.halcomp.newpin("spindle.spindle-override.count-enable", hal.Type.BOOL, hal.Dir.IN)
@@ -6491,7 +6491,7 @@ def _make_hal_pins(self):
hal_glib.GPin(pin).connect("value_changed", self._del_message_changed)
# for manual tool change dialog
- self.halcomp.newpin("toolchange-number", hal.HAL_S32, hal.Dir.IN)
+ self.halcomp.newpin("toolchange-number", hal.Type.SINT, hal.Dir.IN)
self.halcomp.newpin("toolchange-changed", hal.Type.BOOL, hal.Dir.OUT)
pin = self.halcomp.newpin('toolchange-change', hal.Type.BOOL, hal.Dir.IN)
hal_glib.GPin(pin).connect('value_changed', self.on_tool_change)
@@ -6516,8 +6516,8 @@ def _make_hal_pins(self):
self.halcomp.newpin("error", hal.Type.BOOL, hal.Dir.OUT)
# make pins to indicate program progress information
- self.halcomp.newpin("program.length", hal.HAL_S32, hal.Dir.OUT)
- self.halcomp.newpin("program.current-line", hal.HAL_S32, hal.Dir.OUT)
+ self.halcomp.newpin("program.length", hal.Type.SINT, hal.Dir.OUT)
+ self.halcomp.newpin("program.current-line", hal.Type.SINT, hal.Dir.OUT)
self.halcomp.newpin("program.progress", hal.Type.REAL, hal.Dir.OUT)
# make a pin to set ignore limits
diff --git a/src/emc/usr_intf/gscreen/gscreen.py b/src/emc/usr_intf/gscreen/gscreen.py
index 80ae44eed34..8f86f0ace7f 100755
--- a/src/emc/usr_intf/gscreen/gscreen.py
+++ b/src/emc/usr_intf/gscreen/gscreen.py
@@ -1672,9 +1672,9 @@ def init_jog_pins(self):
self.halcomp.newpin("jog-enable-%s-out"% (axis), hal.Type.BOOL, hal.Dir.OUT)
self.halcomp.newpin("jog-enable-out", hal.Type.BOOL, hal.Dir.OUT)
self.halcomp.newpin("jog-increment-out", hal.Type.REAL, hal.Dir.OUT)
- #self.data['jog-increment-in'] = hal_glib.GPin(self.halcomp.newpin('jog-increment-in', hal.HAL_S32, hal.Dir.IN))
+ #self.data['jog-increment-in'] = hal_glib.GPin(self.halcomp.newpin('jog-increment-in', hal.Type.SINT, hal.Dir.IN))
#self.data['jog-increment-in'].connect('value-changed', self.on_hal_jog_increments_changed)
- #self.data['jog-rate-in'] = hal_glib.GPin(self.halcomp.newpin('jog-rate-in', hal.HAL_S32, hal.Dir.IN))
+ #self.data['jog-rate-in'] = hal_glib.GPin(self.halcomp.newpin('jog-rate-in', hal.Type.SINT, hal.Dir.IN))
#self.data['jog-rate-in'].connect('value-changed', self.on_hal_jog_rate_changed)
# pins used for selecting an encoder to adjust overrides
@@ -1706,7 +1706,7 @@ def initialize_manual_toolchange(self):
or the default function
"""
# for manual tool change dialog
- self.halcomp.newpin("tool-number", hal.HAL_S32, hal.Dir.IN)
+ self.halcomp.newpin("tool-number", hal.Type.SINT, hal.Dir.IN)
self.halcomp.newpin("tool-changed", hal.Type.BOOL, hal.Dir.OUT)
self.data['change-tool'] = hal_glib.GPin(self.halcomp.newpin('change-tool', hal.Type.BOOL, hal.Dir.IN))
# you can override manual tool change
diff --git a/src/emc/usr_intf/halui.cc b/src/emc/usr_intf/halui.cc
index 6796e4cf48d..1d0cb6e2542 100644
--- a/src/emc/usr_intf/halui.cc
+++ b/src/emc/usr_intf/halui.cc
@@ -51,14 +51,6 @@ static int axis_mask = 0;
#define MDI_MAX 64
-// FIXME: This will have to go again when we do proper 64-bit
-// The typedefs are necessary to map to hal_[gs]et_[su]i32() in the expansion
-// of below macros because they are selected based on text-concatenation in the
-// preprocessor. Even the 32-bit version use sint/uint, but the expansion would
-// then select the 64-bit versions.
-typedef hal_sint_t hal_si32_t;
-typedef hal_uint_t hal_ui32_t;
-
#define HAL_FIELDS \
FIELD(bool,machine_on) /* pin for setting machine On */ \
FIELD(bool,machine_off) /* pin for setting machine Off */ \
@@ -216,12 +208,8 @@ struct PTR {
template struct NATIVE {};
template<> struct NATIVE { typedef rtapi_bool type; };
-template<> struct NATIVE { typedef rtapi_s32 type; };
-template<> struct NATIVE { typedef rtapi_u32 type; };
-// FIXME: These need to be 64-bit. Can't set them now because the compiler sees
-// the typedef mapped overlap.
-//template<> struct NATIVE { typedef rtapi_sint type; };
-//template<> struct NATIVE { typedef rtapi_uint type; };
+template<> struct NATIVE { typedef rtapi_sint type; };
+template<> struct NATIVE { typedef rtapi_uint type; };
template<> struct NATIVE { typedef rtapi_real type; };
struct VALUE {
template struct field { typedef typename NATIVE::type type; };
@@ -488,7 +476,7 @@ static ANGULAR_UNIT_CONVERSION angularUnitConversion = ANGULAR_UNITS_AUTO;
#define GRAD_PER_DEG (100.0/90.0)
#define RAD_PER_DEG TO_RAD // from posemath.h
-int halui_export_pin_IN_bit(hal_bool_t *pin, const char *name)
+static int halui_export_pin_IN_bool(hal_bool_t *pin, const char *name)
{
int retval;
retval = hal_pin_new_bool(comp_id, HAL_IN, pin, 0, "%s", name);
@@ -500,10 +488,10 @@ int halui_export_pin_IN_bit(hal_bool_t *pin, const char *name)
return 0;
}
-int halui_export_pin_IN_s32(hal_sint_t *pin, const char *name)
+static int halui_export_pin_IN_sint(hal_sint_t *pin, const char *name)
{
int retval;
- retval = hal_pin_new_si32(comp_id, HAL_IN, pin, 0, "%s", name);
+ retval = hal_pin_new_sint(comp_id, HAL_IN, pin, 0, "%s", name);
if (retval < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,"HALUI: ERROR: halui pin %s export failed with err=%i\n", name, retval);
hal_exit(comp_id);
@@ -512,7 +500,7 @@ int halui_export_pin_IN_s32(hal_sint_t *pin, const char *name)
return 0;
}
-int halui_export_pin_IN_float(hal_real_t *pin, const char *name)
+static int halui_export_pin_IN_real(hal_real_t *pin, const char *name)
{
int retval;
retval = hal_pin_new_real(comp_id, HAL_IN, pin, 0.0, "%s", name);
@@ -525,7 +513,7 @@ int halui_export_pin_IN_float(hal_real_t *pin, const char *name)
}
-int halui_export_pin_OUT_bit(hal_bool_t *pin, const char *name)
+static int halui_export_pin_OUT_bool(hal_bool_t *pin, const char *name)
{
int retval;
retval = hal_pin_new_bool(comp_id, HAL_OUT, pin, 0, "%s", name);
@@ -574,25 +562,25 @@ int halui_hal_init(void)
/* STEP 3a: export the out-pin(s) */
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->units_per_mm), 0.0, "halui.machine.units-per-mm"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->machine_is_on), "halui.machine.is-on"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->estop_is_activated), "halui.estop.is-activated"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mode_is_manual), "halui.mode.is-manual"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mode_is_auto), "halui.mode.is-auto"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mode_is_mdi), "halui.mode.is-mdi"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mode_is_teleop), "halui.mode.is-teleop"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mode_is_joint), "halui.mode.is-joint"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->mist_is_on), "halui.mist.is-on"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->flood_is_on), "halui.flood.is-on"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->program_is_idle), "halui.program.is-idle"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->program_is_running), "halui.program.is-running"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->machine_is_on), "halui.machine.is-on"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->estop_is_activated), "halui.estop.is-activated"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mode_is_manual), "halui.mode.is-manual"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mode_is_auto), "halui.mode.is-auto"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mode_is_mdi), "halui.mode.is-mdi"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mode_is_teleop), "halui.mode.is-teleop"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mode_is_joint), "halui.mode.is-joint"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->mist_is_on), "halui.mist.is-on"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->flood_is_on), "halui.flood.is-on"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->program_is_idle), "halui.program.is-idle"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->program_is_running), "halui.program.is-running"));
if (num_mdi_commands > 0) {
- CHK(halui_export_pin_OUT_bit(&(halui_data->halui_mdi_is_running), "halui.halui-mdi-is-running"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->halui_mdi_is_running), "halui.halui-mdi-is-running"));
}
- CHK(halui_export_pin_OUT_bit(&(halui_data->program_is_paused), "halui.program.is-paused"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->program_os_is_on), "halui.program.optional-stop.is-on"));
- CHK(halui_export_pin_OUT_bit(&(halui_data->program_bd_is_on), "halui.program.block-delete.is-on"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->program_is_paused), "halui.program.is-paused"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->program_os_is_on), "halui.program.optional-stop.is-on"));
+ CHK(halui_export_pin_OUT_bool(&(halui_data->program_bd_is_on), "halui.program.block-delete.is-on"));
for (int spindle = 0; spindle < num_spindles; spindle++){
CHK(hal_pin_new_bool(comp_id, HAL_OUT, &(halui_data->spindle_is_on[spindle]), 0, "halui.spindle.%i.is-on", spindle));
@@ -608,7 +596,7 @@ int halui_hal_init(void)
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->spindle_brake_on[spindle]), 0, "halui.spindle.%i.brake-on", spindle));
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->spindle_brake_off[spindle]), 0, "halui.spindle.%i.brake-off", spindle));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->so_value[spindle]), 0.0, "halui.spindle.%i.override.value", spindle));
- CHK(hal_pin_new_si32(comp_id, HAL_IN, &(halui_data->so_counts[spindle]), 0, "halui.spindle.%i.override.counts", spindle));
+ CHK(hal_pin_new_sint(comp_id, HAL_IN, &(halui_data->so_counts[spindle]), 0, "halui.spindle.%i.override.counts", spindle));
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->so_count_enable[spindle]), 1, "halui.spindle.%i.override.count-enable", spindle));
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->so_direct_value[spindle]), 0, "halui.spindle.%i.override.direct-value", spindle));
CHK(hal_pin_new_real(comp_id, HAL_IN, &(halui_data->so_scale[spindle]), 0.0, "halui.spindle.%i.override.scale", spindle));
@@ -655,9 +643,9 @@ int halui_hal_init(void)
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->mv_value), 0.0, "halui.max-velocity.value"));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->fo_value), 0.0, "halui.feed-override.value"));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->ro_value), 0.0, "halui.rapid-override.value"));
- CHK(hal_pin_new_ui32(comp_id, HAL_OUT, &(halui_data->joint_selected), 0, "halui.joint.selected"));
- CHK(hal_pin_new_ui32(comp_id, HAL_OUT, &(halui_data->axis_selected), 0, "halui.axis.selected"));
- CHK(hal_pin_new_ui32(comp_id, HAL_OUT, &(halui_data->tool_number), 0, "halui.tool.number"));
+ CHK(hal_pin_new_uint(comp_id, HAL_OUT, &(halui_data->joint_selected), 0, "halui.joint.selected"));
+ CHK(hal_pin_new_uint(comp_id, HAL_OUT, &(halui_data->axis_selected), 0, "halui.axis.selected"));
+ CHK(hal_pin_new_uint(comp_id, HAL_OUT, &(halui_data->tool_number), 0, "halui.tool.number"));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->tool_length_offset_x), 0.0, "halui.tool.length_offset.x"));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->tool_length_offset_y), 0.0, "halui.tool.length_offset.y"));
CHK(hal_pin_new_real(comp_id, HAL_OUT, &(halui_data->tool_length_offset_z), 0.0, "halui.tool.length_offset.z"));
@@ -671,60 +659,60 @@ int halui_hal_init(void)
/* STEP 3b: export the in-pin(s) */
- CHK(halui_export_pin_IN_bit(&(halui_data->machine_on), "halui.machine.on"));
- CHK(halui_export_pin_IN_bit(&(halui_data->machine_off), "halui.machine.off"));
- CHK(halui_export_pin_IN_bit(&(halui_data->estop_activate), "halui.estop.activate"));
- CHK(halui_export_pin_IN_bit(&(halui_data->estop_reset), "halui.estop.reset"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mode_manual), "halui.mode.manual"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mode_auto), "halui.mode.auto"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mode_mdi), "halui.mode.mdi"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mode_teleop), "halui.mode.teleop"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mode_joint), "halui.mode.joint"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mist_on), "halui.mist.on"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mist_off), "halui.mist.off"));
- CHK(halui_export_pin_IN_bit(&(halui_data->flood_on), "halui.flood.on"));
- CHK(halui_export_pin_IN_bit(&(halui_data->flood_off), "halui.flood.off"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_run), "halui.program.run"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_pause), "halui.program.pause"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_resume), "halui.program.resume"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_step), "halui.program.step"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_stop), "halui.program.stop"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_os_on), "halui.program.optional-stop.on"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_os_off), "halui.program.optional-stop.off"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_bd_on), "halui.program.block-delete.on"));
- CHK(halui_export_pin_IN_bit(&(halui_data->program_bd_off), "halui.program.block-delete.off"));
-
- CHK(halui_export_pin_IN_s32(&(halui_data->mv_counts), "halui.max-velocity.counts"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mv_count_enable), "halui.max-velocity.count-enable"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->machine_on), "halui.machine.on"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->machine_off), "halui.machine.off"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->estop_activate), "halui.estop.activate"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->estop_reset), "halui.estop.reset"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mode_manual), "halui.mode.manual"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mode_auto), "halui.mode.auto"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mode_mdi), "halui.mode.mdi"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mode_teleop), "halui.mode.teleop"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mode_joint), "halui.mode.joint"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mist_on), "halui.mist.on"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mist_off), "halui.mist.off"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->flood_on), "halui.flood.on"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->flood_off), "halui.flood.off"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_run), "halui.program.run"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_pause), "halui.program.pause"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_resume), "halui.program.resume"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_step), "halui.program.step"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_stop), "halui.program.stop"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_os_on), "halui.program.optional-stop.on"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_os_off), "halui.program.optional-stop.off"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_bd_on), "halui.program.block-delete.on"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->program_bd_off), "halui.program.block-delete.off"));
+
+ CHK(halui_export_pin_IN_sint(&(halui_data->mv_counts), "halui.max-velocity.counts"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mv_count_enable), "halui.max-velocity.count-enable"));
hal_set_bool(halui_data->mv_count_enable, 1);
- CHK(halui_export_pin_IN_bit(&(halui_data->mv_direct_value), "halui.max-velocity.direct-value"));
- CHK(halui_export_pin_IN_float(&(halui_data->mv_scale), "halui.max-velocity.scale"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mv_increase), "halui.max-velocity.increase"));
- CHK(halui_export_pin_IN_bit(&(halui_data->mv_decrease), "halui.max-velocity.decrease"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mv_direct_value), "halui.max-velocity.direct-value"));
+ CHK(halui_export_pin_IN_real(&(halui_data->mv_scale), "halui.max-velocity.scale"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mv_increase), "halui.max-velocity.increase"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->mv_decrease), "halui.max-velocity.decrease"));
- CHK(halui_export_pin_IN_s32(&(halui_data->fo_counts), "halui.feed-override.counts"));
- CHK(halui_export_pin_IN_bit(&(halui_data->fo_count_enable), "halui.feed-override.count-enable"));
+ CHK(halui_export_pin_IN_sint(&(halui_data->fo_counts), "halui.feed-override.counts"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->fo_count_enable), "halui.feed-override.count-enable"));
hal_set_bool(halui_data->fo_count_enable, 1);
- CHK(halui_export_pin_IN_bit(&(halui_data->fo_direct_value), "halui.feed-override.direct-value"));
- CHK(halui_export_pin_IN_float(&(halui_data->fo_scale), "halui.feed-override.scale"));
- CHK(halui_export_pin_IN_bit(&(halui_data->fo_increase), "halui.feed-override.increase"));
- CHK(halui_export_pin_IN_bit(&(halui_data->fo_decrease), "halui.feed-override.decrease"));
- CHK(halui_export_pin_IN_bit(&(halui_data->fo_reset), "halui.feed-override.reset"));
-
- CHK(halui_export_pin_IN_s32(&(halui_data->ro_counts), "halui.rapid-override.counts"));
- CHK(halui_export_pin_IN_bit(&(halui_data->ro_count_enable), "halui.rapid-override.count-enable"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->fo_direct_value), "halui.feed-override.direct-value"));
+ CHK(halui_export_pin_IN_real(&(halui_data->fo_scale), "halui.feed-override.scale"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->fo_increase), "halui.feed-override.increase"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->fo_decrease), "halui.feed-override.decrease"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->fo_reset), "halui.feed-override.reset"));
+
+ CHK(halui_export_pin_IN_sint(&(halui_data->ro_counts), "halui.rapid-override.counts"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->ro_count_enable), "halui.rapid-override.count-enable"));
hal_set_bool(halui_data->ro_count_enable, 1);
- CHK(halui_export_pin_IN_bit(&(halui_data->ro_direct_value), "halui.rapid-override.direct-value"));
- CHK(halui_export_pin_IN_float(&(halui_data->ro_scale), "halui.rapid-override.scale"));
- CHK(halui_export_pin_IN_bit(&(halui_data->ro_increase), "halui.rapid-override.increase"));
- CHK(halui_export_pin_IN_bit(&(halui_data->ro_decrease), "halui.rapid-override.decrease"));
- CHK(halui_export_pin_IN_bit(&(halui_data->ro_reset), "halui.rapid-override.reset"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->ro_direct_value), "halui.rapid-override.direct-value"));
+ CHK(halui_export_pin_IN_real(&(halui_data->ro_scale), "halui.rapid-override.scale"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->ro_increase), "halui.rapid-override.increase"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->ro_decrease), "halui.rapid-override.decrease"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->ro_reset), "halui.rapid-override.reset"));
if (have_home_all) {
- CHK(halui_export_pin_IN_bit(&(halui_data->home_all), "halui.home-all"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->home_all), "halui.home-all"));
}
- CHK(halui_export_pin_IN_bit(&(halui_data->abort), "halui.abort"));
+ CHK(halui_export_pin_IN_bool(&(halui_data->abort), "halui.abort"));
for (int joint = 0; joint < num_joints ; joint++) {
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->joint_home[joint]), 0, "halui.joint.%d.home", joint));
@@ -762,11 +750,11 @@ int halui_hal_init(void)
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->ajog_increment_plus[EMCMOT_MAX_AXIS]), 0, "halui.axis.selected.increment-plus"));
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->ajog_increment_minus[EMCMOT_MAX_AXIS]), 0, "halui.axis.selected.increment-minus"));
- CHK(halui_export_pin_IN_float(&(halui_data->jjog_speed), "halui.joint.jog-speed"));
- CHK(halui_export_pin_IN_float(&(halui_data->jjog_deadband), "halui.joint.jog-deadband"));
+ CHK(halui_export_pin_IN_real(&(halui_data->jjog_speed), "halui.joint.jog-speed"));
+ CHK(halui_export_pin_IN_real(&(halui_data->jjog_deadband), "halui.joint.jog-deadband"));
- CHK(halui_export_pin_IN_float(&(halui_data->ajog_speed), "halui.axis.jog-speed"));
- CHK(halui_export_pin_IN_float(&(halui_data->ajog_deadband), "halui.axis.jog-deadband"));
+ CHK(halui_export_pin_IN_real(&(halui_data->ajog_speed), "halui.axis.jog-speed"));
+ CHK(halui_export_pin_IN_real(&(halui_data->ajog_deadband), "halui.axis.jog-deadband"));
for (int n = 0; n < num_mdi_commands; n++) {
CHK(hal_pin_new_bool(comp_id, HAL_IN, &(halui_data->mdi_commands[n]), 0, "halui.mdi-command-%02d", n));
@@ -1395,8 +1383,8 @@ static void hal_init_pins()
hal_set_real(halui_data->ajog_deadband, 0.2);
hal_set_real(halui_data->ajog_speed, 0);
- hal_set_ui32(halui_data->joint_selected, 0); // select joint 0 by default
- hal_set_ui32(halui_data->axis_selected, 0); // select axis 0 by default
+ hal_set_uint(halui_data->joint_selected, 0); // select joint 0 by default
+ hal_set_uint(halui_data->axis_selected, 0); // select no axis by default
hal_set_real(halui_data->fo_scale, old_halui_data.fo_scale = 0.1); //sane default
hal_set_real(halui_data->ro_scale, old_halui_data.ro_scale = 0.1); //sane default
@@ -1465,7 +1453,7 @@ static bool jogging_selected_axis(local_halui_str &hal) {
// and sends appropriate messages if so
static void check_hal_changes()
{
- rtapi_s32 counts;
+ rtapi_sint counts;
int jselect_changed, joint;
int aselect_changed, axis_num;
rtapi_bool bit;
@@ -1750,7 +1738,7 @@ static void check_hal_changes()
bit = new_halui_data.joint_nr_select[joint];
if (bit != old_halui_data.joint_nr_select[joint]) {
if (bit != 0) {
- hal_set_ui32(halui_data->joint_selected, joint);
+ hal_set_uint(halui_data->joint_selected, joint);
jselect_changed = joint; // flag that we changed the selected joint
}
old_halui_data.joint_nr_select[joint] = bit;
@@ -1824,7 +1812,7 @@ static void check_hal_changes()
bit = new_halui_data.axis_nr_select[axis_num];
if (bit != old_halui_data.axis_nr_select[axis_num]) {
if (bit != 0) {
- hal_set_ui32(halui_data->axis_selected, axis_num);
+ hal_set_uint(halui_data->axis_selected, axis_num);
aselect_changed = axis_num; // flag that we changed the selected axis
}
old_halui_data.axis_nr_select[axis_num] = bit;
@@ -1992,7 +1980,7 @@ static void modify_hal_pins()
hal_set_bool(halui_data->mist_is_on, emcStatus->io.coolant.mist);
hal_set_bool(halui_data->flood_is_on, emcStatus->io.coolant.flood);
- hal_set_ui32(halui_data->tool_number, emcStatus->io.tool.toolInSpindle);
+ hal_set_uint(halui_data->tool_number, emcStatus->io.tool.toolInSpindle);
hal_set_real(halui_data->tool_length_offset_x, emcStatus->task.toolOffset.tran.x);
hal_set_real(halui_data->tool_length_offset_y, emcStatus->task.toolOffset.tran.y);
hal_set_real(halui_data->tool_length_offset_z, emcStatus->task.toolOffset.tran.z);
@@ -2101,7 +2089,7 @@ static void modify_hal_pins()
hal_set_real(halui_data->axis_pos_relative[8], emcStatus->motion.traj.actualPosition.w - emcStatus->task.g5x_offset.w - emcStatus->task.g92_offset.w - emcStatus->task.toolOffset.w);
}
- rtapi_u32 joint_selected = hal_get_ui32(halui_data->joint_selected);
+ rtapi_uint joint_selected = hal_get_uint(halui_data->joint_selected);
hal_set_bool(halui_data->joint_is_homed[num_joints], emcStatus->motion.joint[joint_selected].homed);
hal_set_bool(halui_data->joint_on_soft_min_limit[num_joints], emcStatus->motion.joint[joint_selected].minSoftLimit);
hal_set_bool(halui_data->joint_on_soft_max_limit[num_joints], emcStatus->motion.joint[joint_selected].maxSoftLimit);
diff --git a/src/emc/usr_intf/pncconf/options.glade b/src/emc/usr_intf/pncconf/options.glade
index caab2c39f70..4788efe0990 100644
--- a/src/emc/usr_intf/pncconf/options.glade
+++ b/src/emc/usr_intf/pncconf/options.glade
@@ -602,7 +602,7 @@
True
False
5
- Number of digital (bit) in pins:
+ Number of digital (bool) in pins:
True
digitsin
0.019999999552965164
@@ -619,7 +619,7 @@
True
False
3
- Number of digital (bit) out pins:
+ Number of digital (bool) out pins:
True
digitsout
0.039999999105930328
@@ -635,7 +635,7 @@
True
False
6
- Number of analog (s32) in pins:
+ Number of analog (sint) in pins:
True
word-char
s32in
@@ -652,7 +652,7 @@
True
False
5
- Number of analog (s32) out pins:
+ Number of analog (sint) out pins:
True
s32out
0
@@ -668,7 +668,7 @@
True
False
5
- Number of analog (float) in pins:
+ Number of analog (real) in pins:
True
s32out
0
@@ -684,7 +684,7 @@
True
False
5
- Number of analog (float) out pins:
+ Number of analog (real) out pins:
True
s32out
0
diff --git a/src/emc/usr_intf/pncconf/tests.py b/src/emc/usr_intf/pncconf/tests.py
index 64bf2507b06..09df67b28ed 100644
--- a/src/emc/usr_intf/pncconf/tests.py
+++ b/src/emc/usr_intf/pncconf/tests.py
@@ -1415,7 +1415,7 @@ def update(self):
def make_blank(self,container,boardnum,number):
#blankname = "enc-%d" % (number)
#self.data2["brd%denc%d" % (boardnum,number)]= Gtk.Button("Reset-%d"% number)
- #self.hal.c.newpin(encname, hal.HAL_S32, hal.Dir.IN)
+ #self.hal.c.newpin(encname, hal.Type.SINT, hal.Dir.IN)
label = Gtk.Label(" ")
container.pack_start(label, False, False, 10)
label = Gtk.Label(" ")
@@ -1431,9 +1431,9 @@ def make_enc(self,container,boardnum,number):
self.data2["brd%denc%dreset" % (boardnum,number)]= Gtk.Button("Reset-%d"% number)
container.pack_start(self.data2["brd%denc%dreset" % (boardnum,number)], False, False, 10)
encname = "brd.%d.enc.%d.count" % (boardnum,number)
- print("making HAL pin enc s32 brd %d num %d"%(boardnum,number))
- self.hal.c.newpin(encname, hal.HAL_S32, hal.Dir.IN)
- hal.new_sig(encname+"-signal",hal.HAL_S32)
+ print("making HAL pin enc sint brd %d num %d"%(boardnum,number))
+ self.hal.c.newpin(encname, hal.Type.SINT, hal.Dir.IN)
+ hal.new_sig(encname+"-signal",hal.Type.SINT)
hal.connect("testpanel."+encname,encname+"-signal")
label = self.data2["brd%denc%dcount" % (boardnum,number)] = Gtk.Label("Encoder-%d"% (number))
label.set_size_request(100, -1)
diff --git a/src/emc/usr_intf/pyui/_panelui.ini b/src/emc/usr_intf/pyui/_panelui.ini
index 5818f15cc09..9feb5906252 100644
--- a/src/emc/usr_intf/pyui/_panelui.ini
+++ b/src/emc/usr_intf/pyui/_panelui.ini
@@ -1,7 +1,7 @@
[RADIO_BUTTONS]
[[mpg_scale]]
KEY = NONE
- OUTPUT = FLOAT
+ OUTPUT = REAL
DEFAULT = mpg_small
[[[mpg_small]]]
KEY = R6C2
@@ -25,20 +25,20 @@
KEY = R0C3
GROUP = mpg_scale
GROUP_OUTPUT = .01
- OUTPUT = S32
+ OUTPUT = SINT
STATUS_PIN = True
TRUE_STATE = 20
FALSE_STATE = 0
DEFAULT = false
[[axis_select]]
KEY = select_axis
- OUTPUT = S32
+ OUTPUT = SINT
DEFAULT = select_x
[[[select_x]]]
KEY = R5C2
GROUP = axis_select
GROUP_OUTPUT = 1
- OUTPUT = BIT
+ OUTPUT = BOOL
TRUE_STATE = True
FALSE_STATE = False
STATUS_PIN = True
@@ -47,7 +47,7 @@
KEY = R4C2
GROUP = axis_select
GROUP_OUTPUT = 2
- OUTPUT = BIT
+ OUTPUT = BOOL
TRUE_STATE = True
FALSE_STATE = False
STATUS_PIN = True
@@ -56,7 +56,7 @@
[TOGGLE_BUTTONS]
[[tool_change]]
KEY = R2C5
- OUTPUT = BIT
+ OUTPUT = BOOL
TRUE_COMMAND = NONE, NONE
FALSE_COMMAND = NONE, NONE
STATUS_PIN = True
diff --git a/src/emc/usr_intf/pyui/panelui_spec.ini b/src/emc/usr_intf/pyui/panelui_spec.ini
index de686301ce3..b0e6b5b1054 100644
--- a/src/emc/usr_intf/pyui/panelui_spec.ini
+++ b/src/emc/usr_intf/pyui/panelui_spec.ini
@@ -8,12 +8,13 @@
# Radio button need two levels of sections
# The first level: [GROUP_NAME] defines the groups name
# KEY=None
-# OUTPUT= HAL PIN TYPE (S32 U32 or FLOAT)
+# OUTPUT= HAL PIN TYPE (SINT UINT or REAL)
+# We keep the old names so user's systems don't break right away
# DEFAULT= KEYNAME of the default selected key in level two
[[__many__]]
KEY = string
- OUTPUT = option('NONE','S32', 'U32', 'FLOAT',default='S32')
+ OUTPUT = option('NONE','SINT','UINT','REAL','S32','U32','FLOAT',default='SINT')
DEFAULT = string
# The second sections define the keys in this group
@@ -21,7 +22,7 @@
KEY = string
GROUP = string
GROUP_OUTPUT = number()
- OUTPUT = option('S32', 'U32', 'FLOAT', 'BIT','COMMAND','ZMQ','NONE',default='S32')
+ OUTPUT = option('SINT','UINT','REAL','BOOL','S32','U32','FLOAT','BIT','COMMAND','ZMQ','NONE',default='SINT')
STATUS_PIN = boolean
TRUE_STATE = string
FALSE_STATE = string
@@ -33,7 +34,7 @@
[TOGGLE_BUTTONS]
[[__many__]]
KEY = string
- OUTPUT = option('S32', 'U32', 'FLOAT', 'BIT','COMMAND','ZMQ','NONE',default='S32')
+ OUTPUT = option('SINT','UINT','REAL','BOOL','S32','U32','FLOAT','BIT','COMMAND','ZMQ','NONE',default='SINT')
STATUS_PIN = boolean
TRUE_COMMAND = list(default='NONE',)
FALSE_COMMAND = list(default='NONE',)
@@ -46,7 +47,7 @@
[MOMENTARY_BUTTONS]
[[__many__]]
KEY = string
- OUTPUT = option('S32', 'U32', 'FLOAT', 'BIT','COMMAND','ZMQ','NONE',default='S32')
+ OUTPUT = option('SINT','UINT','REAL','BOOL','S32','U32','FLOAT','BIT','COMMAND','ZMQ','NONE',default='SINT')
STATUS_PIN = boolean
TRUE_COMMAND = list(default='NONE')
FALSE_COMMAND = list(default='NONE')
diff --git a/src/emc/usr_intf/pyui/widgets.py b/src/emc/usr_intf/pyui/widgets.py
index 53be78a0f96..a6e64f79a37 100644
--- a/src/emc/usr_intf/pyui/widgets.py
+++ b/src/emc/usr_intf/pyui/widgets.py
@@ -8,6 +8,9 @@ def DBG(str):
if not DBG_state or DBG_suppress: return
print(str)
+_old_types_warned = []
+_old_types = {'S32':'SINT', 'U32':'"UINT', 'FLOAT':'REAL', 'BIT':'BOOL'}
+
""" Set of base classes """
class _WidgetBase:
def hal_init(self, master, comp, name,metadata,command,widgets,dbg):
@@ -28,20 +31,26 @@ def hal_init(self, master, comp, name,metadata,command,widgets,dbg):
if not 'FALSE_STATE' in self.metadata:
self.metadata['FALSE_STATE'] = 0
+ global _old_types, _old_types_warned
+ smdo = self.metadata['OUTPUT']
+ if smdo in _old_types and smdo not in _old_types_warned:
+ print(f"Deprecation notice: Old HAL type '{smdo}' has been replaced with '{_old_types[smdo]}'. Please update your configuration.")
+ _old_types_warned += [smdo]
+
# convert and set pintype and states based on metadata types
- if self.metadata['OUTPUT'] == 'S32':
- self.pintype=hal.HAL_S32
+ if self.metadata['OUTPUT'] in ('SINT', 'S32'):
+ self.pintype=hal.Type.SINT
self.true_state = int(self.metadata['TRUE_STATE'])
self.false_state = int(self.metadata['FALSE_STATE'])
- elif self.metadata['OUTPUT'] == 'U32':
- self.pintype=hal.HAL_U32
+ elif self.metadata['OUTPUT'] in ('UINT', 'U32'):
+ self.pintype=hal.Type.UINT
self.true_state = int(self.metadata['TRUE_STATE'])
self.false_state = int(self.metadata['FALSE_STATE'])
- elif self.metadata['OUTPUT'] == 'REAL' or self.metadata['OUTPUT'] == 'FLOAT':
+ elif self.metadata['OUTPUT'] in ('REAL', 'FLOAT'):
self.pintype=hal.Type.REAL
self.true_state = float(self.metadata['TRUE_STATE'])
self.false_state = float(self.metadata['FALSE_STATE'])
- elif self.metadata['OUTPUT'] == 'BOOL' or self.metadata['OUTPUT'] == 'BIT':
+ elif self.metadata['OUTPUT'] in ('BOOL', 'BIT'):
self.pintype=hal.Type.BOOL
self.true_state = True#self.metadata['TRUE_STATE']
self.false_state = False#self.metadata['FALSE_STATE']
@@ -255,9 +264,9 @@ def toggle_state(self,skip):
self.widgets[i].set_state(False)
self.widgets[i].hal_update()
raw = float(self.widgets[skip].metadata['GROUP_OUTPUT'])
- if self.metadata['OUTPUT'] in('U32', 'S32'):
+ if self.metadata['OUTPUT'] in ('SINT', 'UINT', 'U32', 'S32'):
self.output = int(raw)
- elif self.metadata['OUTPUT'] == 'FLOAT':
+ elif self.metadata['OUTPUT'] in ('REAL', 'FLOAT'):
self.output = float(raw)
self.hal_update()
diff --git a/src/emc/usr_intf/stepconf/options.glade b/src/emc/usr_intf/stepconf/options.glade
index 95af24da530..0c2f32117a6 100644
--- a/src/emc/usr_intf/stepconf/options.glade
+++ b/src/emc/usr_intf/stepconf/options.glade
@@ -976,7 +976,7 @@ panel
True
False
6
- Number of analog (s32) in pins:
+ Number of analog (sint) in pins:
True
word-char
s32in
@@ -992,7 +992,7 @@ panel
True
False
5
- Number of analog (s32) out pins:
+ Number of analog (sint) out pins:
True
s32out
0
diff --git a/src/emc/usr_intf/touchy/hal_interface.py b/src/emc/usr_intf/touchy/hal_interface.py
index 4864d2bf9f8..18802297492 100644
--- a/src/emc/usr_intf/touchy/hal_interface.py
+++ b/src/emc/usr_intf/touchy/hal_interface.py
@@ -82,7 +82,7 @@ def __init__(self, gui, emc_control, mdi_control, emc):
self.abort = 0
self.c.newpin("single-block", hal.Type.BOOL, hal.Dir.IN)
self.singleblock = 0
- self.c.newpin("wheel-counts", hal.HAL_S32, hal.Dir.IN)
+ self.c.newpin("wheel-counts", hal.Type.SINT, hal.Dir.IN)
self.counts = 0
self.jog_velocity = 1
self.c.ready()
diff --git a/src/hal/classicladder/module_hal.c b/src/hal/classicladder/module_hal.c
index d3ac7495548..bb72cb84f29 100644
--- a/src/hal/classicladder/module_hal.c
+++ b/src/hal/classicladder/module_hal.c
@@ -178,7 +178,7 @@ int rtapi_app_main(void) {
rtapi_print("creating ladder-state\n");
- result = hal_export_funct("classicladder.0.refresh",hal_task,0,1, 0, compId);
+ result = hal_export_funct("classicladder.0.refresh", hal_task, 0, 0, compId);
if(result < 0) {
error:
hal_exit(compId);
diff --git a/src/hal/components/.gitignore b/src/hal/components/.gitignore
index 01a447a5a38..c18fb61471b 100644
--- a/src/hal/components/.gitignore
+++ b/src/hal/components/.gitignore
@@ -1 +1,2 @@
conv_*.comp
+!conv_real_bool.comp
diff --git a/src/hal/components/Submakefile b/src/hal/components/Submakefile
index 62c9940cfbb..6c6ed4850de 100644
--- a/src/hal/components/Submakefile
+++ b/src/hal/components/Submakefile
@@ -3,35 +3,17 @@ COMPS := $(filter-out %/tpcomp.comp, $(patsubst $(BASEPWD)/%,%,$(wildcard $(BASE
include $(patsubst %.comp, $(BASEPWD)/objects/%.mak, $(COMPS))
else
CONVERTERS := \
- conv_bit_float.comp \
- conv_bit_s32.comp \
- conv_bit_u32.comp \
- conv_bit_s64.comp \
- conv_bit_u64.comp \
- conv_float_s32.comp \
- conv_float_u32.comp \
- conv_float_s64.comp \
- conv_float_u64.comp \
- conv_s32_bit.comp \
- conv_s32_float.comp \
- conv_s32_u32.comp \
- conv_s32_s64.comp \
- conv_s32_u64.comp \
- conv_s64_bit.comp \
- conv_s64_float.comp \
- conv_s64_s32.comp \
- conv_s64_u32.comp \
- conv_s64_u64.comp \
- conv_u32_bit.comp \
- conv_u32_float.comp \
- conv_u32_s32.comp \
- conv_u32_s64.comp \
- conv_u32_u64.comp \
- conv_u64_bit.comp \
- conv_u64_float.comp \
- conv_u64_s32.comp \
- conv_u64_u32.comp \
- conv_u64_s64.comp
+ conv_bool_real.comp \
+ conv_bool_sint.comp \
+ conv_bool_uint.comp \
+ conv_real_sint.comp \
+ conv_real_uint.comp \
+ conv_sint_bool.comp \
+ conv_sint_real.comp \
+ conv_sint_uint.comp \
+ conv_uint_bool.comp \
+ conv_uint_real.comp \
+ conv_uint_sint.comp
COMPS := $(filter-out hal/components/tpcomp.comp, $(sort $(wildcard hal/components/*.comp) $(addprefix hal/components/, $(CONVERTERS))))
COMP_MANPAGES := $(patsubst hal/components/%.comp, ../docs/build/man/man9/%.9, $(COMPS)) ../docs/build/man/man9/tpcomp.9
ifeq ($(BUILD_SYS),uspace)
@@ -136,118 +118,46 @@ PYFLAGS := $(PYTHON_EXTRA_LDFLAGS) $(BOOST_PYTHON_LIB) $(PYTHON_LIBS) $(PYTHON_E
$(Q)$(CC) -Wl,-z,relro -o $@ $^ $(PYFLAGS)
TARGETS += ../bin/panelui
-hal/components/conv_float_s32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_real_sint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh float s32 < $< > $@
+ $(Q)sh hal/components/mkconv.sh real sint < $< > $@
-hal/components/conv_float_u32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_real_uint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh float u32 < $< > $@
+ $(Q)sh hal/components/mkconv.sh real uint < $< > $@
-hal/components/conv_float_s64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_bool_sint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh float s64 < $< > $@
+ $(Q)sh hal/components/mkconv.sh bool sint < $< > $@
-hal/components/conv_float_u64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_bool_uint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh float u64 < $< > $@
+ $(Q)sh hal/components/mkconv.sh bool uint < $< > $@
-hal/components/conv_bit_s32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_bool_real.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh bit s32 < $< > $@
+ $(Q)sh hal/components/mkconv.sh bool real < $< > $@
-hal/components/conv_bit_u32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_sint_real.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh bit u32 < $< > $@
+ $(Q)sh hal/components/mkconv.sh sint real < $< > $@
-hal/components/conv_bit_s64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_sint_bool.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh bit s64 < $< > $@
+ $(Q)sh hal/components/mkconv.sh sint bool < $< > $@
-hal/components/conv_bit_u64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_sint_uint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh bit u64 < $< > $@
+ $(Q)sh hal/components/mkconv.sh sint uint < $< > $@
-hal/components/conv_bit_float.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_uint_real.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh bit float < $< > $@
+ $(Q)sh hal/components/mkconv.sh uint real < $< > $@
-hal/components/conv_s32_float.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_uint_bool.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s32 float < $< > $@
+ $(Q)sh hal/components/mkconv.sh uint bool < $< > $@
-hal/components/conv_s32_bit.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
+hal/components/conv_uint_sint.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
$(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s32 bit < $< > $@
-
-hal/components/conv_s32_u32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s32 u32 < $< > $@
-
-hal/components/conv_s32_u64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s32 u64 < $< > $@
-
-hal/components/conv_s32_s64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s32 s64 < $< > $@
-
-hal/components/conv_u32_float.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u32 float < $< > $@
-
-hal/components/conv_u32_bit.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u32 bit < $< > $@
-
-hal/components/conv_u32_s32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u32 s32 < $< > $@
-
-hal/components/conv_u32_u64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u32 u64 < $< > $@
-
-hal/components/conv_u32_s64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u32 s64 < $< > $@
-
-hal/components/conv_s64_float.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s64 float < $< > $@
-
-hal/components/conv_s64_bit.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s64 bit < $< > $@
-
-hal/components/conv_s64_u32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s64 u32 < $< > $@
-
-hal/components/conv_s64_s32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s64 s32 < $< > $@
-
-hal/components/conv_s64_u64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh s64 u64 < $< > $@
-
-hal/components/conv_u64_float.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u64 float < $< > $@
-
-hal/components/conv_u64_bit.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u64 bit < $< > $@
-
-hal/components/conv_u64_u32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u64 u32 < $< > $@
-
-hal/components/conv_u64_s32.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u64 s32 < $< > $@
-
-hal/components/conv_u64_s64.comp: hal/components/conv.comp.in hal/components/mkconv.sh hal/components/Submakefile
- $(ECHO) converting conv for $(notdir $@)
- $(Q)sh hal/components/mkconv.sh u64 s64 < $< > $@
+ $(Q)sh hal/components/mkconv.sh uint sint < $< > $@
diff --git a/src/hal/components/abs_s32.comp b/src/hal/components/abs_s32.comp
deleted file mode 100644
index 4ee33a9cf4e..00000000000
--- a/src/hal/components/abs_s32.comp
+++ /dev/null
@@ -1,41 +0,0 @@
-// This is a component for LinuxCNC HAL
-// Copyright 2011 Sebastian Kuzminsky
-//
-// This program is free software; you can redistribute it and/or
-// modify it under the terms of version 2 of the GNU General
-// Public License as published by the Free Software Foundation.
-//
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program; if not, write to the Free Software
-// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-component abs_s32 "Compute the absolute value and sign of a integer input signal";
-
-pin in si32 in "input value" ;
-pin out si32 out "output value, always non-negative";
-pin out bool sign "Sign of input, false for positive, true for negative" ;
-pin out bool is_positive_ "TRUE if input is positive, FALSE if input is 0 or negative";
-pin out bool is_negative_ "TRUE if input is negative, FALSE if input is 0 or positive";
-
-option period no;
-function _;
-license "GPL";
-author "Sebastian Kuzminsky";
-;;
-FUNCTION(_) {
- rtapi_s32 i = in;
- if ( i >= 0 ) {
- sign_set(false);
- out_set(i);
- } else {
- sign_set(true);
- out_set(-i);
- }
-
- is_positive__set(i > 0);
- is_negative__set(i < 0);
-}
diff --git a/src/hal/components/abs_s64.comp b/src/hal/components/abs_sint.comp
similarity index 94%
rename from src/hal/components/abs_s64.comp
rename to src/hal/components/abs_sint.comp
index 012552b83c6..311030c7e5a 100644
--- a/src/hal/components/abs_s64.comp
+++ b/src/hal/components/abs_sint.comp
@@ -15,7 +15,7 @@
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-component abs_s64 "Computes the absolute value and sign of a 64 bit integer input signal";
+component abs_sint "Computes the absolute value and sign of an integer input signal";
pin in sint in "input value" ;
pin out sint out "output value, always non-negative";
diff --git a/src/hal/components/anglejog.comp b/src/hal/components/anglejog.comp
index 876d04bf66a..23b4747bffb 100644
--- a/src/hal/components/anglejog.comp
+++ b/src/hal/components/anglejog.comp
@@ -21,7 +21,7 @@ is false. The value in use is output on the current-scale pin.
pin is false. The value in use is output on the current-angle-degrees
pin.
4. The value of the iscale-factor pin multiplies counts-in internally
-to support integer (s32) calculations for counting. The current-scale-out
+to support integer calculations for counting. The current-scale-out
is divided by the same amount. The pin is sampled only when the
enable-in pin is false. The default value should work in most
applications.
@@ -37,9 +37,9 @@ Simulation Config: `configs/sim/axis/anglejog/anglejog.in`
""";
pin in bool enable_in "enables motion (disables alteration of angle and scale)";
-pin in si32 counts_in "MPG (wheel) counts";
+pin in sint counts_in "MPG (wheel) counts";
pin in real angle_degrees_in "vector angle";
-pin in si32 iscale_factor = 10000 "integer scaling factor (>1)";
+pin in sint iscale_factor = 10000 "integer scaling factor (>1)";
pin in real scale_in "magnitude units/count (mag = counts * scale)";
pin in real max_vel "vector max velocity magnitude";
pin in real max_accel "vector max acceleration magnitude";
@@ -48,8 +48,8 @@ pin in real accel_fraction_in = 1 "acceleration fraction input";
pin out bool enable_out "to: axis.M.jog-enable AND axis.N.jog-enable";
pin out real current_scale "effective scale (informational)";
pin out real current_scale_out "to: axis.M.jog-scale AND axis.N.jog-scale";
-pin out si32 coscounts "to: axis.M.jog-counts (cosine counts)";
-pin out si32 sincounts "to: axis.N.jog-counts (sine counts)";
+pin out sint coscounts "to: axis.M.jog-counts (cosine counts)";
+pin out sint sincounts "to: axis.N.jog-counts (sine counts)";
pin out real cos_accel_fraction "to: axis.M.jog-accel-fraction";
pin out real sin_accel_fraction "to: axis.N.jog-accel-fraction";
@@ -73,14 +73,14 @@ author "Dewey Garrett";
FUNCTION(_) {
static bool once = 1;
static bool wait_for_count_change = 0;
-static int tot_counts;
-static int old_enable_in;
-static int old_counts_in;
-static int ifactor = 0;
+static rtapi_sint tot_counts;
+static rtapi_bool old_enable_in;
+static rtapi_sint old_counts_in;
+static rtapi_sint ifactor = 0;
double max_dv, tiny_dp, mag_err, vel_req;
double mag_cmd;
- int delta_counts = 0;
- int newcounts;
+ rtapi_sint delta_counts = 0;
+ rtapi_sint newcounts;
if (once) {
current_angle_degrees_set(angle_degrees_in);
@@ -147,12 +147,12 @@ static int ifactor = 0;
if ( iscale_factor >= MIN_ISCALE_FACTOR
&& iscale_factor <= MAX_ISCALE_FACTOR) {
ifactor = iscale_factor;
- rtapi_print("new ifactor=%d\n",ifactor);
+ rtapi_print("new ifactor=%ld\n",ifactor);
new_ifactor = 1;
gave_msg = 0;
} else {
if (!gave_msg) {
- rtapi_print("BOGUS iscale_factor=%d (min=%d max=%d)\n"
+ rtapi_print("BOGUS iscale_factor=%ld (min=%d max=%d)\n"
,ifactor,MIN_ISCALE_FACTOR,MAX_ISCALE_FACTOR);
gave_msg = 1;
}
diff --git a/src/hal/components/axistest.comp b/src/hal/components/axistest.comp
index a66f091e1e3..692b158f42c 100644
--- a/src/hal/components/axistest.comp
+++ b/src/hal/components/axistest.comp
@@ -5,7 +5,7 @@ pin in bool jog-plus "Drive TRUE to jog the axis in its positive direction.";
pin in bool run "Drive TRUE to run the axis near its current position_fb with a trapezoidal velocity profile.";
pin in real maxvel "Maximum velocity";
pin in real amplitude "Approximate amplitude of positions to command during 'run'";
-pin in si32 dir "Direction from central point to test: 0 = both, 1 = positive, 2 = negative";
+pin in sint dir "Direction from central point to test: 0 = both, 1 = positive, 2 = negative";
pin in real position-fb;
pin out real position-cmd;
pin out bool running;
@@ -13,7 +13,7 @@ pin out real run-target;
pin out real run-start;
pin out real run-low;
pin out real run-high;
-pin in si32 pause = 0 "Pause time for each end of run in seconds";
+pin in sint pause = 0 "Pause time for each end of run in seconds";
param rw real epsilon = .001;
variable double timer;
param r real elapsed "Current value of the internal timer";
diff --git a/src/hal/components/bin2gray.comp b/src/hal/components/bin2gray.comp
index 10c47d0c90f..527b6a28bed 100644
--- a/src/hal/components/bin2gray.comp
+++ b/src/hal/components/bin2gray.comp
@@ -1,11 +1,11 @@
component bin2gray "convert a number to the gray-code representation";
description """Converts a number into gray-code""";
-pin in ui32 in "binary code in";
-pin out ui32 out "gray code out";
+pin in uint in "binary code in";
+pin out uint out "gray code out";
license "GPL";
author "Andy Pugh";
option period no;
function _;
;;
-rtapi_u32 i = in;
+rtapi_uint i = in;
out_set((i >> 1) ^ i);
diff --git a/src/hal/components/biquad.comp b/src/hal/components/biquad.comp
index 7e42ad2eaea..936a68368a4 100644
--- a/src/hal/components/biquad.comp
+++ b/src/hal/components/biquad.comp
@@ -48,7 +48,7 @@ coefficients to be calculated according to the current \
pin out bool valid = 0 "When false, indicates an error occurred when calculating \
filter coefficients (require 2>**Q**>0.5 and *f0*>sampleRate/2)";
-pin in ui32 type_ = 0 "Filter type determines the type of filter \
+pin in uint type_ = 0 "Filter type determines the type of filter \
coefficients calculated. When 0, coefficients must be loaded directly \
from the *n0,n1,n2,d1* params. When 1, \
a low pass filter is created specified by the *f0,Q* pins. \
diff --git a/src/hal/components/bitmerge.comp b/src/hal/components/bitmerge.comp
index 11760d35ce5..16300d31489 100644
--- a/src/hal/components/bitmerge.comp
+++ b/src/hal/components/bitmerge.comp
@@ -1,17 +1,17 @@
-component bitmerge "Converts individual bits into an unsigned-32";
-description """This component creates a compound unsigned-32 from individual
-bit-inputs for each bit of an unsigned-32 output. The number of bits can be
+component bitmerge "Converts individual bits into an unsigned-64";
+description """This component creates a compound unsigned-64 from individual
+bit-inputs for each bit of an unsigned-64 output. The number of bits can be
limited by the "personality" modparam.
The inverse process can be performed by the bitslice HAL component.""";
-pin out ui32 out "The output value";
-pin in bool in-##[32:personality];
+pin out uint out "The output value";
+pin in bool in-##[64:personality];
author "Andy Pugh";
license "GPL2+";
function _;
option personality yes;
option period no;
;;
-rtapi_u32 v = 0;
+rtapi_uint v = 0;
for (int i = personality; i > 0;) {
v <<= 1;
if (in(--i))
diff --git a/src/hal/components/bitslice.comp b/src/hal/components/bitslice.comp
index 11c440aae43..a213a129a82 100644
--- a/src/hal/components/bitslice.comp
+++ b/src/hal/components/bitslice.comp
@@ -1,17 +1,17 @@
-component bitslice "Converts an unsigned-32 input into individual bits";
+component bitslice "Converts an unsigned-64 input into individual bits";
description """This component creates individual bit-outputs for each bit of an
-unsigned-32 input. The number of bits can be limited by the "personality"
+unsigned-64 input. The number of bits can be limited by the "personality"
modparam.
The inverse process can be performed by the bitmerge HAL component.""";
-pin in ui32 in "The input value";
-pin out bool out-##[32:personality];
+pin in uint in "The input value";
+pin out bool out-##[64:personality];
author "Andy Pugh";
license "GPL2+";
function _;
option personality yes;
option period no;
;;
-rtapi_u32 v = in;
+rtapi_uint v = in;
for (int i = 0; i < personality; i++) {
out_set(i, v & 1);
v >>= 1;
diff --git a/src/hal/components/bitwise.comp b/src/hal/components/bitwise.comp
index 38a0b6791be..55df2f0f77e 100644
--- a/src/hal/components/bitwise.comp
+++ b/src/hal/components/bitwise.comp
@@ -1,12 +1,12 @@
component bitwise "Computes various bitwise operations on the two input values";
-pin in ui32 in0 "First input value";
-pin in ui32 in1 "Second input value";
-pin out ui32 out-and "The bitwise AND of the two inputs";
-pin out ui32 out-or "The bitwise OR of the two inputs";
-pin out ui32 out-xor "The bitwise XOR of the two inputs";
-pin out ui32 out-nand "The inverse of the bitwise AND";
-pin out ui32 out-nor "The inverse of the bitwise OR";
-pin out ui32 out-xnor "The inverse of the bitwise XOR";
+pin in uint in0 "First input value";
+pin in uint in1 "Second input value";
+pin out uint out-and "The bitwise AND of the two inputs";
+pin out uint out-or "The bitwise OR of the two inputs";
+pin out uint out-xor "The bitwise XOR of the two inputs";
+pin out uint out-nand "The inverse of the bitwise AND";
+pin out uint out-nor "The inverse of the bitwise OR";
+pin out uint out-xnor "The inverse of the bitwise XOR";
author "Andy Pugh";
license "GPL 2+";
@@ -14,8 +14,8 @@ function _;
option period no;
;;
-rtapi_u32 i0 = in0;
-rtapi_u32 i1 = in1;
+rtapi_uint i0 = in0;
+rtapi_uint i1 = in1;
out_nand_set(~out_and_set(i0 & i1));
out_nor_set( ~out_or_set( i0 | i1));
out_xnor_set(~out_xor_set(i0 ^ i1));
diff --git a/src/hal/components/bldc.comp b/src/hal/components/bldc.comp
index 438b330f9a1..0955c545332 100644
--- a/src/hal/components/bldc.comp
+++ b/src/hal/components/bldc.comp
@@ -25,7 +25,7 @@ pin in real frequency if (personality & 0x0F)==0 """Frequency input for motors w
pin in real initvalue = 0.2 if personality & 0x04 """The current to be used for the homing sequence in applications where an incremental encoder is used with no hall-sensor feedback""";
-pin in si32 rawcounts = 0 if personality & 0x06
+pin in sint rawcounts = 0 if personality & 0x06
"""Encoder counts input. This must be linked to the encoder rawcounts pin or encoder index resets will cause the motor commutation to fail.""";
pin io bool index-enable if personality & 0x08 """This pin should be connected to the associated encoder index-enable pin to zero the encoder when it passes index.
@@ -91,28 +91,28 @@ pin out bool out-dir
pin out real out-abs
"Absolute value of the input value";
-param r si32 in_type = -1 "state machine output, will probably hide after debug";
-param r si32 out_type = -1 "state machine output, will probably hide after debug";
+param r sint in_type = -1 "state machine output, will probably hide after debug";
+param r sint out_type = -1 "state machine output, will probably hide after debug";
-param rw si32 scale = 512 if personality & 0x06
+param rw sint scale = 512 if personality & 0x06
"The number of encoder counts per rotor revolution.";
-param rw si32 poles = 4 if personality & 0x06
+param rw sint poles = 4 if personality & 0x06
"""The number of motor poles. The encoder scale will be divided by this value
to determine the number of encoder counts per electrical revolution.""";
-param rw si32 encoder-offset = 0 if personality & 0x0A
+param rw sint encoder-offset = 0 if personality & 0x0A
"""The offset, in encoder counts, between the motor electrical zero and the
encoder zero modulo the number of counts per electrical revolution""";
-param r si32 offset_measured = 0 if personality & 0x04
+param r sint offset_measured = 0 if personality & 0x04
"""The encoder offset measured by the homing sequence (in certain modes)""";
param rw real drive-offset = 0 """The angle, in degrees, applied to the commanded angle by the drive in degrees.
This value is only used during the homing sequence of drives with incremental encoder feedback.
It is used to back-calculate from commanded angle to actual phase angle.
It is only relevant to drives which expect rotor-angle input rather than phase-angle demand. Should be 0 for most drives.""";
-param rw ui32 output-pattern=25 if personality & 0x400
+param rw uint output-pattern=25 if personality & 0x400
"""Commutation pattern to be output in Hall Signal translation mode. See the description of *pattern* for details.""";
-param rw ui32 pattern=25 if personality & 0x01
+param rw uint pattern=25 if personality & 0x01
"""Commutation pattern to use, from 0 to 47. Default is type 25.
Every plausible combination is included.
The table below shows the excitation pattern along the top, and the pattern code on the left hand side.
@@ -289,11 +289,11 @@ option count_function yes;
variable int old_init = 0;
variable char old_ph = 000;
-variable int old_pattern = -1;
+variable rtapi_sint old_pattern = -1;
variable double counter = 0;
-variable rtapi_s64 long_rawcounts = 0;
-variable rtapi_s64 old_long_rawcounts = 0;
-variable rtapi_s32 old_rawcounts = 0;
+variable rtapi_sint long_rawcounts = 0;
+variable rtapi_sint old_long_rawcounts = 0;
+variable rtapi_sint old_rawcounts = 0;
variable int force_trap = 0;
;;
@@ -398,6 +398,9 @@ FUNCTION(_) {
if (personality & 0x06) {
// Handle s32 rollover of rawcounts
+ // No longer necessary locally since all here are 64-bit. But we leave
+ // the calculation for now because the upstream connection may not be
+ // fixed yet.
old_long_rawcounts = long_rawcounts;
long_rawcounts += (rawcounts-old_rawcounts);
old_rawcounts = rawcounts;
@@ -431,7 +434,7 @@ FUNCTION(_) {
if (pattern > 47){
rtapi_print_msg(RTAPI_MSG_ERR,
"Only `Hall patterns 0-47 are allowed, you have"
- " requested pattern %i\n", pattern);
+ " requested pattern %ld\n", pattern);
pattern_set(0);
return;
}
@@ -455,7 +458,7 @@ FUNCTION(_) {
phase_angle_set(phase_angle - floor(phase_angle));
if (! (ph & old_ph)){ hall_error_set(1);}
- if (pattern != (unsigned)old_pattern){hall_error_set(0);}
+ if (pattern != (rtapi_uint)old_pattern){hall_error_set(0);}
if (force_trap) break;
@@ -624,7 +627,7 @@ FUNCTION(_) {
in_type_set(0x02);
return;
default:
- rtapi_print_msg(RTAPI_MSG_ERR, "Unknown input type pattern (%X) in "
+ rtapi_print_msg(RTAPI_MSG_ERR, "Unknown input type pattern (%lX) in "
"bldc\n", in_type);
in_type_set(-2);
return;
@@ -781,7 +784,7 @@ FUNCTION(_) {
out_type_set(0x400);
return;
default:
- rtapi_print_msg(RTAPI_MSG_ERR, "Unsupported output type (%X) in bldc"
+ rtapi_print_msg(RTAPI_MSG_ERR, "Unsupported output type (%lX) in bldc"
, out_type);
in_type_set(-2);
return;
diff --git a/src/hal/components/boss_plc.c b/src/hal/components/boss_plc.c
index 8b1016320b9..a77f4080f2d 100644
--- a/src/hal/components/boss_plc.c
+++ b/src/hal/components/boss_plc.c
@@ -14,74 +14,74 @@
* the component id number and is formatted as "%d".
*
* Pins (former parameters):
- * u32 boss_plc..amp-ready-delay
- * u32 boss_plc..brake-on-delay
- * u32 boss_plc..brake-off-delay
- * u32 boss_plc..spindle-lo-to-hi
- * float boss_plc..jog-scale-0
- * float boss_plc..jog-scale-1
- * float boss_plc..jog-scale-2
+ * uint boss_plc..amp-ready-delay
+ * uint boss_plc..brake-on-delay
+ * uint boss_plc..brake-off-delay
+ * uint boss_plc..spindle-lo-to-hi
+ * real boss_plc..jog-scale-0
+ * real boss_plc..jog-scale-1
+ * real boss_plc..jog-scale-2
*
* Pins:
- * bit boss_plc..cycle-start-in
- * bit boss_plc..cycle-hold-in
- * bit boss_plc..feed-hold-out
- * float boss_plc..adaptive-feed-in
- * float boss_plc..adaptive-feed-out
- * bit boss_plc..tool-change-in
- * bit boss_plc..tool-changed-out
- * bit boss_plc..wait-user-out
- * bit boss_plc..mist-on-in
- * bit boss_plc..mist-on-out
- * bit boss_plc..flood-on-in
- * bit boss_plc..flood-on-out
+ * bool boss_plc..cycle-start-in
+ * bool boss_plc..cycle-hold-in
+ * bool boss_plc..feed-hold-out
+ * real boss_plc..adaptive-feed-in
+ * real boss_plc..adaptive-feed-out
+ * bool boss_plc..tool-change-in
+ * bool boss_plc..tool-changed-out
+ * bool boss_plc..wait-user-out
+ * bool boss_plc..mist-on-in
+ * bool boss_plc..mist-on-out
+ * bool boss_plc..flood-on-in
+ * bool boss_plc..flood-on-out
*
- * bit boss_plc..limit-override-in
- * bit boss_plc..limit-active-out
- * float boss_plc..x-position-in
- * bit boss_plc..x-jog-en-in
- * bit boss_plc..x-limit-in
- * bit boss_plc..x-limit-pos-out
- * bit boss_plc..x-limit-neg-out
- * float boss_plc..y-position-in
- * bit boss_plc..y-jog-en-in
- * bit boss_plc..y-limit-in
- * bit boss_plc..y-limit-pos-out
- * bit boss_plc..y-limit-neg-out
- * bit boss_plc..z-jog-en-in
- * bit boss_plc..z-limit-pos-in
- * bit boss_plc..z-limit-neg-in
- * bit boss_plc..z-limit-pos-out
- * bit boss_plc..z-limit-neg-out
+ * bool boss_plc..limit-override-in
+ * bool boss_plc..limit-active-out
+ * real boss_plc..x-position-in
+ * bool boss_plc..x-jog-en-in
+ * bool boss_plc..x-limit-in
+ * bool boss_plc.