MB2HAL not fully compatible with LinuxCNC 2.9 ?
19 Jan 2022 19:28 #232474
by rebelx
MB2HAL not fully compatible with LinuxCNC 2.9 ? was created by rebelx
Dear All,
I have been running my Gerber Sabre 408 on LinuxCNC 2.7 and 2.8 without problems for several years, using MB2HAL for communication with my Omron P5+ VFD. Since I wanted to switch to qtdragon_hd as a UI for my touchscreen display, I decided to upgrade to LinuxCNC 2.9. However, somehow MB2HAL seems to give a problem. After the hal pins are successfully created and the module seems running, it suddenly shuts down with the following error:
It seems weird to me, as the pins were created successfully. When I comment out that particular line in my omron-mb2hal,hal file, a similar error occurs on line 25. When I comment that out too, the UI starts up without problems and the machine runs, except no spindle control obviously.
I have attached the debug file (linuxcnc.report) as well as the omron-mb2hal.ini and omron-mb2hal.hal files.
Any help will be much appreciated!
Thanks, Eric
I have been running my Gerber Sabre 408 on LinuxCNC 2.7 and 2.8 without problems for several years, using MB2HAL for communication with my Omron P5+ VFD. Since I wanted to switch to qtdragon_hd as a UI for my touchscreen display, I decided to upgrade to LinuxCNC 2.9. However, somehow MB2HAL seems to give a problem. After the hal pins are successfully created and the module seems running, it suddenly shuts down with the following error:
.....
./omron-mb2hal.hal:21: Pin 'spindle-vfd.runmode.00' does not exist
.....
It seems weird to me, as the pins were created successfully. When I comment out that particular line in my omron-mb2hal,hal file, a similar error occurs on line 25. When I comment that out too, the UI starts up without problems and the machine runs, except no spindle control obviously.
I have attached the debug file (linuxcnc.report) as well as the omron-mb2hal.ini and omron-mb2hal.hal files.
Any help will be much appreciated!
Thanks, Eric
Please Log in or Create an account to join the conversation.
20 Jan 2022 14:36 #232525
by HansU
Replied by HansU on topic MB2HAL not fully compatible with LinuxCNC 2.9 ?
Try changingtoandtoin your HAL-file.
Yes. The structure of the pins changed a bit to be more consistent and provide float and int pins and inverted bool pins.
Just have a look at the differences:
linuxcnc.org/docs/html/drivers/mb2hal.html
linuxcnc.org/docs/devel/html/drivers/mb2hal.html
spindle-vfd.runmode.00
spindle-vfd.runmode.float.00
spindle-vfd.target-freq.00
spindle-vfd.target-freq.float.00
Yes. The structure of the pins changed a bit to be more consistent and provide float and int pins and inverted bool pins.
Just have a look at the differences:
linuxcnc.org/docs/html/drivers/mb2hal.html
linuxcnc.org/docs/devel/html/drivers/mb2hal.html
Please Log in or Create an account to join the conversation.
20 Jan 2022 17:03 - 20 Jan 2022 17:19 #232538
by rebelx
Replied by rebelx on topic MB2HAL not fully compatible with LinuxCNC 2.9 ?
Hi Hansu, first of all thank you for your quick reply. I made the suggested changes, but the error still happens:
I have attached the debug report. As you can see it seems that pin spindle-vfd.runmode.00 is being created and after all the pins have been created the module runs and then somehow quit signal 15 is being received, resulting in the module to exit.
Perhaps my understanding may be incorrect, but I would expect a pin 'spindle-vfd.runmode.float.00' to be created instead of 'spindle-vfd.runmode.00'.
.....
./omron-mb2hal.hal:21: Pin 'spindle-vfd.runmode.float.00' does not exist
.....
I have attached the debug report. As you can see it seems that pin spindle-vfd.runmode.00 is being created and after all the pins have been created the module runs and then somehow quit signal 15 is being received, resulting in the module to exit.
....
185 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [0] pin_name [spindle-vfd.info.num_errors]
186 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [0] pin_name [spindle-vfd.info.00]
187 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [1] pin_name [spindle-vfd.real-freq.num_errors]
188 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [1] pin_name [spindle-vfd.real-freq.00]
189 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [2] pin_name [spindle-vfd.runmode.num_errors]
190 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [2] pin_name [spindle-vfd.runmode.00]
191 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [3] pin_name [spindle-vfd.target-freq.num_errors]
192 spindle-vfd create_each_mb_tx_hal_pins DEBUG: mb_tx_num [3] pin_name [spindle-vfd.target-freq.00]
193 spindle-vfd main OK: HAL components created OK
194 spindle-vfd main OK: Link thread loop and logic 0 created OK
195 spindle-vfd main OK: spindle-vfd is running
196 spindle-vfd quit_signal DEBUG: signal [15] received
197 spindle-vfd quit_cleanup DEBUG: started
198 spindle-vfd quit_cleanup DEBUG: unloading HAL module [45] ret[0]
199 spindle-vfd quit_cleanup DEBUG: done OK
200 spindle-vfd main OK: going to exit!
....
Perhaps my understanding may be incorrect, but I would expect a pin 'spindle-vfd.runmode.float.00' to be created instead of 'spindle-vfd.runmode.00'.
Last edit: 20 Jan 2022 17:19 by rebelx.
Please Log in or Create an account to join the conversation.
20 Jan 2022 18:09 #232542
by HansU
Replied by HansU on topic MB2HAL not fully compatible with LinuxCNC 2.9 ?
Sorry my mistake, try again with:A hint for debugging is to load the mb2hal component with it's ini file but don't connect any expected signals so far.
Then have a look in Halshow which signals are really created and if that is what you intended.
spindle-vfd.runmode.00.float spindle-vfd.target-freq.00.float
Then have a look in Halshow which signals are really created and if that is what you intended.
Please Log in or Create an account to join the conversation.
20 Jan 2022 19:04 #232546
by rebelx
Replied by rebelx on topic MB2HAL not fully compatible with LinuxCNC 2.9 ?
Hi Hansu, thank you once more for your quick reply and yes, that did the trick! I should have know that float should come at the end but it's been a while since I wrote some decent hal code. I apologize for my stupidity
Thank you for your debugging hint. I will certainly look into that next time.
Case closed
Take care,
Eric
Thank you for your debugging hint. I will certainly look into that next time.
Case closed
Take care,
Eric
Please Log in or Create an account to join the conversation.
Time to create page: 0.130 seconds