- Posts: 35
- Thank you received: 0
Getting a WHB04B-4 working.
- photomankc
- Topic Author
- Offline
- Junior Member
-
I found documentation on the xhc-whb04b-6xhc-whb04b-6 component but the example file in there seems to do nothing for me. After adding it to the [HAL] section of my machine ini, I had to comment each and every single line in the file as it bombed out with errors that there was no such pin. With everything commented out but the loadrt statement I got past the crashes but then I see why it complains. Looking at HAL configuration there are none of the pins mentioned in the sample config for whb.*
So, is there any concise set of instructions to get this sucker working? I've got a stripped out config that works with keyboard and mouse but I really would like to get my pendant back to working. Right now I'd be happy to just see some X/Y/Z coordinates so that I know communication is occurring and I can probably work it out from there.
Please Log in to join the conversation.
- tommylight
-
- Away
- Administrator
-
- Posts: 22012
- Thank you received: 4
So if you get "access denied" in the error messages, search for arduino access denied, the user needs to be added to dialout group.
here you have everything available inside the linuxcnc.org site:
www.google.com/search?source=hp&ei=QDP6X...SRCLkQ4dUDCAY&uact=5
Please Log in to join the conversation.
- photomankc
- Topic Author
- Offline
- Junior Member
-
- Posts: 35
- Thank you received: 0
So when looking at that linked page I posted page I interpreted this as the what I needed to do:
Add sample HAL file shown to the configuration directory named as "xhc-whb04b.hal"
Add that file into my mills PM25-MV.ini as an additional HAL file to load:
[HAL]
HALFILE = PM-25MV.hal
HALUI = halui
HALFILE = xhc-whb04b.hal
POSTGUI_HALFILE = custom_postgui.hal
At first it just complained of missing pins on each uncommented line. Then once all lines other than the loadrt were commented out, LinuxCNC would start and bring up Axis but when I looked at HAL configuration from the menu there is no top level whb device and so there can't be any whb,* pins. It seems the load is not working but there is no error message about it.
ETA: Tried loading it on cmdline with halrun, at first just silence but then I added the command "sudo udevadm trigger" and see this:
$ halrun
halcmd: loadusr -W xhc-whb04b-6 -H
failed to claim interface
halcmd: exit
Note: Using POSIX realtime
Please Log in to join the conversation.
- photomankc
- Topic Author
- Offline
- Junior Member
-
- Posts: 35
- Thank you received: 0
First check the folder "/etc/udev/rules.d/" is there the files 90-smoothie.rules ?
you can also try sudo nano /etc/udev/rules.d/90-smoothie.rules for check if the files is ok.
This was installed via apt-get and the buildbot URIs.
dmesg text when it's inserted:
Please Log in to join the conversation.
I think something is broken in the 2.8 but i have successfully used 2.9 some time ago.
you need to have a file inside rules.d folder called "99-xhc-whb04b-6.rules" if this file is missing you need to create one !:
sudo nano /etc/udev/rules.d/99-xhc-whb04b-6.rules
You need to reboot computer or
MovT wrote: If you add confs to the udev you need to run:
Code:udevadm control -R
to reload the confs and database.
Secondly
open a terminal without starting linuxcnc and type :
halrun
loadusr -W xhc-whb04b-6 -Hsf
and open a second terminal and type :
watch -n0.4 halcmd show pin whb.
If the device and driver work you can see several entry in the second terminal.
ps : you can try reread my post from this link
forum.linuxcnc.org/38-general-linuxcnc-q...king?start=90#164533
Please Log in to join the conversation.
- photomankc
- Topic Author
- Offline
- Junior Member
-
- Posts: 35
- Thank you received: 0
The xhc−whb04b−6 executable needs permission for reading the pendant’s USB device. There may be the need for additional udev rules. If so, this file /etc/udev/rules.d/99−xhc−whb04b−6.rules should be created with the single line ATTR{idProduct}=="eb93", ATTR{idVendor}=="10ce", MODE="0666", OWNER="root", GROUP="plugdev".
So based on the fact that I was missing the rules file mentioned in the earlier post and that snip of text I gathered I needed to create it. I did change the group from "plugdev" to "dialout" following the pattern of the other devices but not sure that makes a difference. I tried again and no joy. But I decided to give it a reboot in case something had not picked up on the rules or the device file lingered after unplugging somehow.
After the reboot there was rejoicing:
And then testing to see if I was getting data from the device:
So, tommylight was right about permissions it just was not immediately obvious that the device file was not going to have the right permissions. In fact, I'm completely lost as to where that device file even really is. But this is good. I think I can get on with loading it and connecting it up now!
Please Log in to join the conversation.
- photomankc
- Topic Author
- Offline
- Junior Member
-
- Posts: 35
- Thank you received: 0
Nope, not working. Will not load the module in the live config. No errors, not messages, no 'whb' pins in hal so nothing in that hal file can possibly work.
This is wearing me down.
Please Log in to join the conversation.
- photomankc
- Topic Author
- Offline
- Junior Member
-
- Posts: 35
- Thank you received: 0
Best guess is that there is some non-printing character in there that's messing things up.
Please Log in to join the conversation.
- tommylight
-
- Away
- Administrator
-
- Posts: 22012
- Thank you received: 4
Notepad or Notepad++ for windows.
No word processors.
Please Log in to join the conversation.
if not exist create rule file with this exact things and reboot after saving
sudo nano /etc/udev/rules.d99-xhc-whb04b-6.rules
So basically you only need to download this file : (untested wget command...)
Edit your "know as working config.ini"
nano your_config.ini
for adding
and add to HAL section (i think before POSTGUI_HALFILE)
thats all ! (i hope :laugh: )
Please Log in to join the conversation.
