- Posts: 11
- Thank you received: 1
ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
- RiJa
- Offline
- New Member
-
Less
More
3 years 3 months ago - 3 years 3 months ago #275191
by RiJa
Replied by RiJa on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
I'm having trouble doing that, I get this error
Code:
halcmd: loadrt litexcnc
Note: Using POSIX realtime
litexcnc: Loading Litex CNC driver version 1.1.0
litexcnc: Loading and registering default modules:
Cannot load default module 'gpio': /usr/share/rtlib/litexcnc_gpio.so: cannot open shared object file: No such file or directory
litexcnc: rtapi_app_main: Operation not permitted (-1)
<stdin>:2: waitpid failed /usr/bin/rtapi_app litexcnc
<stdin>:2: /usr/bin/rtapi_app exited without becoming ready
<stdin>:2: insmod for litexcnc failed, returned -1
Last edit: 3 years 3 months ago by RiJa.
Please Log in or Create an account to join the conversation.
- deroj
- Offline
- Senior Member
-
Less
More
- Posts: 63
- Thank you received: 21
3 years 3 months ago #275212
by deroj
Replied by deroj on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Hi.
I changed the encoder to have index input.
All I did was edit the config.json -> encoder section
Then flashed the board with firmware, opened LinuxCNC and the encoder works as expected.
I made a small video.
First set encoder.index-enable true.
Then when it detects the index pulse, the counter will be set to zero and index-enable back to false.
www.dropbox.com/s/zg66ako64gm8v3w/VID_20230711_160304.mp4?dl=0
I changed the encoder to have index input.
All I did was edit the config.json -> encoder section
Then flashed the board with firmware, opened LinuxCNC and the encoder works as expected.
I made a small video.
First set encoder.index-enable true.
Then when it detects the index pulse, the counter will be set to zero and index-enable back to false.
www.dropbox.com/s/zg66ako64gm8v3w/VID_20230711_160304.mp4?dl=0
Please Log in or Create an account to join the conversation.
- deroj
- Offline
- Senior Member
-
Less
More
- Posts: 63
- Thank you received: 21
3 years 3 months ago #275213
by deroj
Replied by deroj on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
@RiJa
can you show the terminal output when you run
litexcnc install_driver?
can you show the terminal output when you run
litexcnc install_driver?
Please Log in or Create an account to join the conversation.
- tuxcnc
- Offline
- Elite Member
-
Less
More
- Posts: 297
- Thank you received: 56
3 years 3 months ago #275216
by tuxcnc
The encoder.index-enable should be set by user only and never reset by software.
This pin is for reset the encoder counter at EVERY index pulse, not only once on the first.
So this is a bug.
I can't get the index pulse in Linuxcnc - the halscope does not show this, but I didn't detailed test and I don't know is this a bug or I do some wrong...
Replied by tuxcnc on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
You are right, this works as you wrote, but should not.First set encoder.index-enable true.
Then when it detects the index pulse, the counter will be set to zero and index-enable back to false.
The encoder.index-enable should be set by user only and never reset by software.
This pin is for reset the encoder counter at EVERY index pulse, not only once on the first.
So this is a bug.
I can't get the index pulse in Linuxcnc - the halscope does not show this, but I didn't detailed test and I don't know is this a bug or I do some wrong...
Please Log in or Create an account to join the conversation.
- PCW
- Offline
- Moderator
-
Less
More
- Posts: 18115
- Thank you received: 5334
3 years 3 months ago - 3 years 3 months ago #275218
by PCW
Replied by PCW on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
That is how index is handled by LinuxCNC
Typically LinuxCNC's motion component sets index-enable true
for homing to index or spindle synchronized moves. Then, when the hardware
(or software) encoder component detects the index, it clears its hal position pin
and sets index-enable false to tell motion that index has be detected.
Typically LinuxCNC's motion component sets index-enable true
for homing to index or spindle synchronized moves. Then, when the hardware
(or software) encoder component detects the index, it clears its hal position pin
and sets index-enable false to tell motion that index has be detected.
Last edit: 3 years 3 months ago by PCW.
The following user(s) said Thank You: tommylight
Please Log in or Create an account to join the conversation.
- tuxcnc
- Offline
- Elite Member
-
Less
More
- Posts: 297
- Thank you received: 56
3 years 3 months ago #275222
by tuxcnc
linuxcnc.org/docs/html/man/man9/encoder.9.html
Well, I must finish my lathe model for real test...
Replied by tuxcnc on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
You are right, I was wrong.That is how index is handled by LinuxCNC
Typically LinuxCNC's motion component sets index-enable true
for homing to index or spindle synchronized moves. Then when the hardware
(or software) encoder component detect the index, it clears its hal position pin
and sets index-enable false to tell motion that index has be detected.
linuxcnc.org/docs/html/man/man9/encoder.9.html
Well, I must finish my lathe model for real test...
Please Log in or Create an account to join the conversation.
Moderators: PCW, jmelson
Time to create page: 0.191 seconds