- Posts: 59
- Thank you received: 0
Pokeys_homecomp EncoderSearch / Encoder Arm Topic: Pos_Fb Following errors
10 years 9 months ago #67709
by REEEN
Thank you !
I found out how to use the bus with the library, I only have one problem left, I can not connect to the device, the serial number is written on the board, i set the halpin devSerial to this number, but it won't connect ..... Any Ideas ?
I found out how to use the bus with the library, I only have one problem left, I can not connect to the device, the serial number is written on the board, i set the halpin devSerial to this number, but it won't connect ..... Any Ideas ?
Please Log in to join the conversation.
10 years 9 months ago #67717
by fixer
Those are USB VID and PID,
Serial is shown in windows software, where you configure IO pins functions. Should be downloadable somwhere on the Polabs webpage.
Hal pins are always shown, even if board is not connected. There is "alive" pin, that blinks every time the communication with the board is ok. If it is not blinking, something is wrong. You should make some logic in HAL to use that pin and safely stop the machine if something goes wrong (USB gets disconected, ...)
set the device serial in "devSerial" pin with setp command. If you have multiple boards, then you can do multiple instances of HAL component, each conected to its own board by serial number.
Do you have libusb installed? Follow the installation procedure from the link in my firs post, if you dont have it,
Please post back if you will expand the functionality of this component, someone else might find it useful.
Serial is shown in windows software, where you configure IO pins functions. Should be downloadable somwhere on the Polabs webpage.
Hal pins are always shown, even if board is not connected. There is "alive" pin, that blinks every time the communication with the board is ok. If it is not blinking, something is wrong. You should make some logic in HAL to use that pin and safely stop the machine if something goes wrong (USB gets disconected, ...)
set the device serial in "devSerial" pin with setp command. If you have multiple boards, then you can do multiple instances of HAL component, each conected to its own board by serial number.
Do you have libusb installed? Follow the installation procedure from the link in my firs post, if you dont have it,
Please post back if you will expand the functionality of this component, someone else might find it useful.
Please Log in to join the conversation.
10 years 9 months ago #67719
by REEEN
Hello fixer,
yes I found the serial in the software and it is also written on the usb board.
I have seen the alive pin, this pin is always on if I set serial to anything but 0.
I mada a "connected" pin that gets high if the pointer dev is not NULL.
Yes I have libusb installed if not there would be an error.
currently I use VMWARE virtual box to test the board, I captured the usb device in vmware.
I will post my changes when they are tested and working
but I can't without connection ...
yes I found the serial in the software and it is also written on the usb board.
I have seen the alive pin, this pin is always on if I set serial to anything but 0.
I mada a "connected" pin that gets high if the pointer dev is not NULL.
Yes I have libusb installed if not there would be an error.
currently I use VMWARE virtual box to test the board, I captured the usb device in vmware.
I will post my changes when they are tested and working
Please Log in to join the conversation.
10 years 9 months ago #67720
by fixer
maybe the virtualization is the problem. Try it on real HW, or try to compile some examples for command line from PoLabs,...
If even the examples dont work try contacting Polabs, they usually answer fast and are willing to help.
If even the examples dont work try contacting Polabs, they usually answer fast and are willing to help.
Please Log in to join the conversation.
10 years 9 months ago #68154
by REEEN
Hello,
I just tried the board again on a real debian pc, with no luck...
I made sone test files in C to test whether the board is recognized.
I ran the test files and yes, the board could not be identified.
Then I ran the same testfile under root (sudo).
And now it works....
So this is the problem !
Any idea how to solve this ?
Greets REEEN
I just tried the board again on a real debian pc, with no luck...
I made sone test files in C to test whether the board is recognized.
I ran the test files and yes, the board could not be identified.
Then I ran the same testfile under root (sudo).
And now it works....
So this is the problem !
Any idea how to solve this ?
Greets REEEN
Please Log in to join the conversation.
10 years 9 months ago #68185
by REEEN
Finally I got it!
I needed to create a new udev rule:
Create a new file in the /etc/udev/rules.d named 90-usb-pokeys.rules with the following contents:
SUBSYSTEM=="usb", ATTRS{idVendor}=="1dc3", ATTRS{idProduct}=="1001", GROUP="plugdev", MODE="664"
Save the file, then execute
udevadm control --reload-rules
That's it!
I needed to create a new udev rule:
Create a new file in the /etc/udev/rules.d named 90-usb-pokeys.rules with the following contents:
SUBSYSTEM=="usb", ATTRS{idVendor}=="1dc3", ATTRS{idProduct}=="1001", GROUP="plugdev", MODE="664"
Save the file, then execute
udevadm control --reload-rules
That's it!
Please Log in to join the conversation.
Time to create page: 0.412 seconds
