ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board

More
3 years 9 months ago - 3 years 9 months ago #263075 by deroj
Hello.
It was time to get serious :side:
I connected a stepper to the card. It is moving. But at higher speeds I get
"Position Error"
How can I solve that?
I copied the example Stepgen config from the docs.

EDIT:
I changed the hal to use PID components. Now I can go up to 3000 mm/min. I used the Pncconf Wizard to make a start config.
with pos2vel I was limited to max 900 mm/min
Last edit: 3 years 9 months ago by deroj.
The following user(s) said Thank You: TOLP2

Please Log in or Create an account to join the conversation.

More
3 years 9 months ago #263154 by wuyatom
Your hal can only be used with a watchdog, otherwise the emergency stop in the GUI cannot be pressed, and if you want to use the 5A-75EV7.1 firmware, you need to modify the colorlight.py file. Now my 5A-75EV7.1 board can work normally
 

Please Log in or Create an account to join the conversation.

More
3 years 9 months ago #263187 by TOLP2

Hello.
It was time to get serious :side:
I connected a stepper to the card. It is moving. But at higher speeds I get
"Position Error"
How can I solve that?
I copied the example Stepgen config from the docs.

EDIT:
I changed the hal to use PID components. Now I can go up to 3000 mm/min. I used the Pncconf Wizard to make a start config.
with pos2vel I was limited to max 900 mm/min
Can you share your setup as an example?

Progress on re-write
At this moment I'm re-writing LitexCNC. The goals of this re-write is:
  • The config is stored on the FPGA. The HAL-driver won't need the JSON-file anymore! Connecting to the FPGA is as easy as loadrt litexcnc followed by loadrt litexcnc_eth connection_string="10.0.0.10". 
  • To name the pins of the FPGA the 'name' property of each module instance is still used to create a .hal-file containing all aliases for the pins. 
  • The CLI scripts for installing the driver and building the firmware automatically detect new modules and boards. This makes it possible to extend the modules and boards in the future. It is possible to do this with plugins.
  • The structure of the module driver has been seriously simplified.
At this moment 3 out of 4 modules have been re-written, only stepgen is still missing. If you want to try it out, you can try the current branch under development:  11-add-external-extensions-to-litexcnc
The following user(s) said Thank You: Pro_El

Please Log in or Create an account to join the conversation.

More
3 years 9 months ago #263214 by deroj

Can you share your setup as an example?

Yes I can.
I attach the hal and ini from each setup. 

File Attachment:

File Name: pos2vel-setup.tar.gz
File Size:2 KB
 

File Attachment:

File Name: pid-setup.tar.gz
File Size:3 KB
The following user(s) said Thank You: Pro_El, TOLP2

Please Log in or Create an account to join the conversation.

More
3 years 8 months ago - 3 years 8 months ago #263750 by deroj
So, what do you think is the reason for the speed limit?
With my Mesa 7i96 i can run 10000mm/min with no problems. Maybe higher. I haven`t test it yet.
Or is it just a setting I have to adjust?

EDIT:
Think I found my error. I set up the scale wy too high. It was about 2000 pulses per mm. Should be 800 pulses.
Now I can go up to 8500mm/min.
I won´t need this speed. But its nice to know it could :-)
Last edit: 3 years 8 months ago by deroj.
The following user(s) said Thank You: TOLP2

Please Log in or Create an account to join the conversation.

More
3 years 8 months ago #263931 by TOLP2

So, what do you think is the reason for the speed limit?
With my Mesa 7i96 i can run 10000mm/min with no problems. Maybe higher. I haven`t test it yet.
Or is it just a setting I have to adjust?

EDIT:
Think I found my error. I set up the scale wy too high. It was about 2000 pulses per mm. Should be 800 pulses.
Now I can go up to 8500mm/min.
I won´t need this speed. But its nice to know it could :-)
Good to hear that you have found the mistake. However, I think the stepgen still doesn't hold up to its expectation:
  • speed: 10,000 mm/min in combination with 2,000 pulses per mm gives a pulse-train with a frequency of 2,000 x 10,000 / 60 = 333 kHz ==> this leads to an error.
  • speed 8,500 mm/min in combination with 800 pulses per mm gives a pulse-train with a frequency of 800 * 8,500 / 60 = 113 kHz, which does work (but actually it should not, see below).
  • Max speed based on .ini-file: STEPLEN = 5000 ns, STEPSPACE = 5000 ns, combined 10 us, maximum speed will be 100 kHz. An error should have been visible and the speed should be lowered to the maximum. I think this did not happen, my apologies.
I just finished moving the stepgen also to the new structure . I will add this to the list of things to improve.

Please Log in or Create an account to join the conversation.

Moderators: PCW, jmelson
Time to create page: 7.251 seconds
Powered by Kunena Forum