[Solved] Probe Basic - program timer error
02 Oct 2024 02:05 #311137
by spumco
Probe Basic - program timer error was created by spumco
New install of PB and have a couple problems with the program timer.
First, I get an error on startup when I connect qtpyvcp.timerseconds.in (or minutes/hours) to the time.comp pins.
According to the LCNC docs (and halshow), time.comp creates u32 pins, but the qtpyvcp pins are floats:
Second, the clock/timer display is distorted. Stylesheet in pb.ui shows it's supposed to be 17pt font, but this seems to be too large.
I seem to recall something quite some time ago about why this is happening, but searcing the qtpyvcp page and everywhere else hasn't turned up anything.
Anybody remember why it's distorted?
First, I get an error on startup when I connect qtpyvcp.timerseconds.in (or minutes/hours) to the time.comp pins.
According to the LCNC docs (and halshow), time.comp creates u32 pins, but the qtpyvcp pins are floats:
Warning: Spoiler!
Loading POSTGUI_HALFILE: /home/mill/linuxcnc/configs/MILL_REV5.1.4/hallib/07_postgui.hal (launcher.py:96)
/home/mill/linuxcnc/configs/MILL_REV5.1.4/hallib/07_postgui.hal:32: Signal 'CYCLE-SECONDS' of type 'u32' cannot add pin 'qtpyvcp.timerseconds.in' of type 'float'
Failed to load POSTGUI_HALFILE with error: 1
/home/mill/linuxcnc/configs/MILL_REV5.1.4/hallib/07_postgui.hal:32: Signal 'CYCLE-SECONDS' of type 'u32' cannot add pin 'qtpyvcp.timerseconds.in' of type 'float'
Failed to load POSTGUI_HALFILE with error: 1
Second, the clock/timer display is distorted. Stylesheet in pb.ui shows it's supposed to be 17pt font, but this seems to be too large.
I seem to recall something quite some time ago about why this is happening, but searcing the qtpyvcp page and everywhere else hasn't turned up anything.
Anybody remember why it's distorted?
Attachments:
Please Log in or Create an account to join the conversation.
02 Oct 2024 03:15 #311140
by Lcvette
Replied by Lcvette on topic Probe Basic - program timer error
postgui hal setup correctly, use the sim as a reference. the other issue is sometime the timer conflicts with something else but i don't recall what it was. the formatting is fine on sim, check there to verify on your install, if so, then it is almost certainly a sonfig conflict or postgui is missing the timer requirements, just use the sim to add to your existing file!
Please Log in or Create an account to join the conversation.
02 Oct 2024 05:15 #311152
by spumco
Replied by spumco on topic Probe Basic - program timer error
The only difference between my config and the sim are the pin/signal names, and the fact that i have my time.comp and not.comp in a different hal file:
Connections are the same, and everything is connecting properly...
Issue is the pin types - float vs. u32
time.comp is u32
qtpuvcp.timersomething.in is float
Can't connect the two.
I vaguely recall seeing something on the PB web page about the clock being distorted (like mine) a couple years ago. Just can't remember, and it appears to be gone now. I feel like it was on one of the installation pages...
#PROBE BASIC - PROGRAM TIMER
net PROGRAM-IDLE => not.pgm-idle.in #SIGNAL FROM CLASSIC LADDER
net CYCLE-PAUSED <= halui.program.is-paused
net CYCLE-PAUSED => time.pgm-timer.pause
net CYCLE-TIMER <= not.pgm-idle.out
net CYCLE-TIMER => time.pgm-timer.start
net CYCLE-SECONDS <= time.pgm-timer.seconds
#net CYCLE-SECONDS => qtpyvcp.timerseconds.in
net CYCLE-MINUTES <= time.pgm-timer.minutes
#net CYCLE-MINUTES => qtpyvcp.timerminutes.in
net CYCLE-HOURS <= time.pgm-timer.hours
#net CYCLE-HOURS => qtpyvcp.timerhours.in
Connections are the same, and everything is connecting properly...
Issue is the pin types - float vs. u32
time.comp is u32
qtpuvcp.timersomething.in is float
Can't connect the two.
I vaguely recall seeing something on the PB web page about the clock being distorted (like mine) a couple years ago. Just can't remember, and it appears to be gone now. I feel like it was on one of the installation pages...
Please Log in or Create an account to join the conversation.
03 Oct 2024 01:28 #311205
by spumco
Replied by spumco on topic Probe Basic - program timer error
Something appears to be hosed up in my PB or QtPyVCP installation.
I found the file which creates the timer hal pins - probe_basic_ui.py - and that file is supposed to create u32 pins, not floats.
And same-same for timerminutes & timerseconds. But... when I start either my config or the sim configs QtPyVCP creates float pins.
My PB sim timer on a Windows VM is working, but not the live machine. And the VM sim's timer is displayed correctly.
I made a couple minor edits to the probe_basic.ui file, but that was just changing the ATC button M-code numbers. Certainly didn't touch the py file or anything but the ui file. And switching back to the 'stock' ui file results in the same behavior for both my config and the sim.
I don't think I did something dumb and install PB twice and my config is looking in an odd place with an edited ui.py file. Probe_basic_ui.py has the same modified date as all the rest of the files in /lib/python3/dist-packages/probe_basic/
What would cause LCNC to ignore the QtPyVCP/Probe Basic python instruction?
I found the file which creates the timer hal pins - probe_basic_ui.py - and that file is supposed to create u32 pins, not floats.
self.timerhours.setProperty("pinType", HalLabel.u32)
And same-same for timerminutes & timerseconds. But... when I start either my config or the sim configs QtPyVCP creates float pins.
My PB sim timer on a Windows VM is working, but not the live machine. And the VM sim's timer is displayed correctly.
I made a couple minor edits to the probe_basic.ui file, but that was just changing the ATC button M-code numbers. Certainly didn't touch the py file or anything but the ui file. And switching back to the 'stock' ui file results in the same behavior for both my config and the sim.
I don't think I did something dumb and install PB twice and my config is looking in an odd place with an edited ui.py file. Probe_basic_ui.py has the same modified date as all the rest of the files in /lib/python3/dist-packages/probe_basic/
What would cause LCNC to ignore the QtPyVCP/Probe Basic python instruction?
The following user(s) said Thank You: Lcvette
Please Log in or Create an account to join the conversation.
03 Oct 2024 02:13 #311207
by spumco
Replied by spumco on topic [Solved] Probe Basic - program timer error
Well, Linux backstage nonsense strikes again.
It appears that flippantly ignoring a GPG key thingie error during installation caused LCNC not to update/install properly. LCNC was starting and running, so why worry?
sudo apt update revealed a GPG error.
Once I fixed that by editing the repository to buildbot2, adding the GPG key file, and doing another update/upgrade, both the timer hal pins and the display were magically fixed.
It appears that flippantly ignoring a GPG key thingie error during installation caused LCNC not to update/install properly. LCNC was starting and running, so why worry?
sudo apt update revealed a GPG error.
Once I fixed that by editing the repository to buildbot2, adding the GPG key file, and doing another update/upgrade, both the timer hal pins and the display were magically fixed.
Please Log in or Create an account to join the conversation.
03 Oct 2024 12:32 #311226
by Lcvette
Replied by Lcvette on topic [Solved] Probe Basic - program timer error
Hurray, glad to hear it!
Please Log in or Create an account to join the conversation.
Time to create page: 0.170 seconds