Skip to content

sim_pin: use the HAL type names halcmd reports - #4699

Open
rene-dev wants to merge 1 commit into
LinuxCNC:masterfrom
rene-dev:sim-pin-types
Open

rene-dev wants to merge 1 commit into
LinuxCNC:masterfrom
rene-dev:sim-pin-types

Conversation

@rene-dev

Copy link
Copy Markdown
Member

Since the move to 64-bit HAL (ff27543), halcmd reports types as bool, real, sint and uint. sim_pin only knew bit, float, s32 and u32, so it refuses every item, e.g. in the external_offsets sim:

Unknown type for signal item <0 e:xcounts sint>

This renames the type names in the script (and the bit-named procs with them). The docs in hal/tools.adoc already use the new names.

Since the move to 64-bit HAL, halcmd reports types as bool, real, sint
and uint. sim_pin only knew bit, float, s32 and u32, so it refused every
pin, parameter and signal with 'Unknown type for signal item'. Rename
the type names in the script, and the bit-named procs with them.

@grandixximo grandixximo left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested this against master (64-bit HAL). Master sim_pin fails on every item with Unknown type for signal item <... bool>. With this PR it accepts bool, real, sint and uint signals and pins. Toggle and pulse work on bool, 2.5 and -7 round-trip on real and sint, a uint above 32 bits (5000000000) is set and shows correctly in hex, and a negative uint entry is still refused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants