cia402.comp - can't compile in 2.10-pre2
- tuxcnc
- Offline
- Elite Member
-
Less
More
- Posts: 294
- Thank you received: 55
27 Oct 2026 18:57 #350490
by tuxcnc
cia402.comp - can't compile in 2.10-pre2 was created by tuxcnc
I am using a file from github.com/rodw-au/cia402_homecomp/blob/main/cia402.comp.
It has always compiled successfully for me in the past, and it has nothing to do with the internal homing routines of the drives.
I am attempting to transition from LinuxCNC 2.10-pre1 to 2.10-pre2.
I have managed to resolve a few issues, but I have no idea why `cia402.comp` refuses to compile.
The full output is:The initial lines regarding the replacement of old variable types with new ones seem fine, but the parts referring to lines 139 and 140 of the `cia402.comp` file look suspicious to me.
It appears that the declarations on lines 139 and 140 are incorrect; this is likely the source of all those error messages stating that a floating-point constant cannot be assigned to variables whose types the compiler fails to recognize.
I could be wrong, but I don’t see any other likely culprits.
Additionally, there might be a type conflict further down in the code, as `hal_real` in C corresponds to `double` rather than `float`.
In any case, this problem is beyond my capabilities, and without `CIA402.so`, my machine simply won't work...
It has always compiled successfully for me in the past, and it has nothing to do with the internal homing routines of the drives.
I am attempting to transition from LinuxCNC 2.10-pre1 to 2.10-pre2.
I have managed to resolve a few issues, but I have no idea why `cia402.comp` refuses to compile.
The full output is:
root@HP-15:~/Pobrane# halcompile --install cia402.comp
cia402.comp:97: Warning: Old type 'unsigned' was replaced by 'ui32', but you should be upgrading to 'uint'.
cia402.comp:98: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:99: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:100: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:102: Warning: Old type 'unsigned' was replaced by 'ui32', but you should be upgrading to 'uint'.
cia402.comp:103: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:104: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:105: Warning: Old type 'signed' was replaced by 'si32', but you should be upgrading to 'sint'.
cia402.comp:108: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:109: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:110: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:112: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:113: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:114: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:117: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:118: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:119: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:121: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:122: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:123: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:124: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:125: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:126: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:127: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:128: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:129: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:130: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:131: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:132: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:133: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:134: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:136: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:139: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:140: Warning: Old type 'float' has been replaced by 'real'
cia402.comp:141: Warning: Old type 'bit' has been replaced by 'bool'
cia402.comp:142: Warning: Old type 'bit' has been replaced by 'bool'
Compiling realtime cia402.c
cia402.comp: In function ‘extra_setup’:
cia402.comp:173:13: error: lvalue required as left operand of assignment
cia402.comp:176:14: error: lvalue required as left operand of assignment
cia402.comp:179:20: error: lvalue required as left operand of assignment
cia402.comp:180:12: error: lvalue required as left operand of assignment
cia402.c:313:86: warning: unused parameter ‘prefix’ [-Wunused-parameter]
313 | #define EXTRA_SETUP() static int extra_setup(struct __comp_state *__comp_inst, char *prefix, long extra_arg)
| ~~~~~~^~~~~~
cia402.comp:171:1: note: in expansion of macro ‘EXTRA_SETUP’
cia402.c:313:99: warning: unused parameter ‘extra_arg’ [-Wunused-parameter]
313 | #define EXTRA_SETUP() static int extra_setup(struct __comp_state *__comp_inst, char *prefix, long extra_arg)
| ~~~~~^~~~~~~~~
cia402.comp:171:1: note: in expansion of macro ‘EXTRA_SETUP’
cia402.comp: At top level:
cia402.comp:185:19: error: unknown type name ‘hal_float_t’; did you mean ‘hal_port_t’?
cia402.comp: In function ‘read_all’:
cia402.comp:203:3: error: implicit declaration of function ‘check_scales’ [-Wimplicit-function-declaration]
cia402.comp:203:16: error: lvalue required as unary ‘&’ operand
cia402.comp:204:16: error: lvalue required as unary ‘&’ operand
cia402.comp:207:10: error: lvalue required as left operand of assignment
cia402.comp:210:15: error: lvalue required as left operand of assignment
cia402.comp:213:18: error: lvalue required as left operand of assignment
cia402.comp:214:17: error: lvalue required as left operand of assignment
cia402.comp:215:26: error: lvalue required as left operand of assignment
cia402.comp:216:26: error: lvalue required as left operand of assignment
cia402.comp:219:26: error: lvalue required as left operand of assignment
cia402.comp:220:26: error: lvalue required as left operand of assignment
cia402.comp:221:26: error: lvalue required as left operand of assignment
cia402.comp:222:26: error: lvalue required as left operand of assignment
cia402.comp:223:26: error: lvalue required as left operand of assignment
cia402.comp:224:26: error: lvalue required as left operand of assignment
cia402.comp:225:26: error: lvalue required as left operand of assignment
cia402.comp:226:26: error: lvalue required as left operand of assignment
cia402.comp:227:26: error: lvalue required as left operand of assignment
cia402.comp:230:25: error: lvalue required as left operand of assignment
cia402.comp:232:27: error: lvalue required as left operand of assignment
cia402.comp:239:18: error: lvalue required as left operand of assignment
cia402.comp:240:19: error: lvalue required as left operand of assignment
cia402.comp:246:15: error: lvalue required as left operand of assignment
cia402.comp:248:15: error: lvalue required as left operand of assignment
cia402.comp: In function ‘write_all’:
cia402.comp:266:15: error: lvalue required as left operand of assignment
cia402.comp:268:10: error: lvalue required as left operand of assignment
cia402.comp:270:19: error: lvalue required as left operand of assignment
cia402.comp:274:19: error: lvalue required as left operand of assignment
cia402.comp:278:19: error: lvalue required as left operand of assignment
cia402.comp:280:21: error: lvalue required as left operand of assignment
cia402.comp:282:23: error: lvalue required as left operand of assignment
cia402.comp:289:23: error: lvalue required as left operand of assignment
cia402.comp:291:23: error: lvalue required as left operand of assignment
cia402.comp:295:10: error: lvalue required as left operand of assignment
cia402.comp:302:12: error: lvalue required as left operand of assignment
cia402.comp:306:12: error: lvalue required as left operand of assignment
cia402.comp:310:12: error: lvalue required as left operand of assignment
cia402.comp:313:19: error: lvalue required as left operand of assignment
cia402.c:311:80: warning: unused parameter ‘period’ [-Wunused-parameter]
311 | #define FUNCTION(name) static void name(struct __comp_state *__comp_inst, long period)
| ~~~~~^~~~~~
cia402.comp:252:1: note: in expansion of macro ‘FUNCTION’
make: *** [/usr/share/linuxcnc/Makefile.modinc:117: cia402.o] Błąd 1
root@HP-15:~/Pobrane# It appears that the declarations on lines 139 and 140 are incorrect; this is likely the source of all those error messages stating that a floating-point constant cannot be assigned to variables whose types the compiler fails to recognize.
I could be wrong, but I don’t see any other likely culprits.
Additionally, there might be a type conflict further down in the code, as `hal_real` in C corresponds to `double` rather than `float`.
In any case, this problem is beyond my capabilities, and without `CIA402.so`, my machine simply won't work...
Please Log in or Create an account to join the conversation.
Time to create page: 0.070 seconds