ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
21 Nov 2022 05:34 - 21 Nov 2022 05:42 #257193
by romanetz
Replied by romanetz on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
AI, AO (these are just must-have), RS-485 (spindle VFD communication over modbus RTU), CAN, SPI - for DRO LED displays, I2C. for digital communications a kind of FIFO is needed to match network packet exchange interval and throughput of the serial bus .
it's a point to discuss whether include riscv-cpu in firmware or not, but the possibilities with that options are incredible: any kind of user-defined packet-based digital communication, say, modbus rtu onboard processing, or mapping of modbus rtu registers onto etherbone addresses.
I'm exploring the possibility to update the firmware over network and Lattice dual-boot capability.
Regarding PCBs, jlcpcb.com is very popular among countries near China
it's a point to discuss whether include riscv-cpu in firmware or not, but the possibilities with that options are incredible: any kind of user-defined packet-based digital communication, say, modbus rtu onboard processing, or mapping of modbus rtu registers onto etherbone addresses.
I'm exploring the possibility to update the firmware over network and Lattice dual-boot capability.
Regarding PCBs, jlcpcb.com is very popular among countries near China
Last edit: 21 Nov 2022 05:42 by romanetz.
The following user(s) said Thank You: tommylight, besriworld
Please Log in or Create an account to join the conversation.
21 Nov 2022 11:16 - 21 Nov 2022 11:22 #257199
by muvideo
Replied by muvideo on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
I've updated my repository with some new features:
- unified driver
- acceleration limit in stepgen is now working
- FPGA internal clock for peripherals Is 40MHz and Is passing the timing closure.
- some pre coocked firmware are available
Now the board communicates to driver the peripherals configuration and the driver adapts automatically, no need to rebuild the driver for changes in peripherals or board version or revision. The only change that still require a rebuild of the driver Is the change of ip address. I suppose that there a way to pass parameters to the driver at invocation but still didnt try.
Todo:
- pass to the driver the ip and frequency when invoked
- create a configurator utility for speeding up the board configuration
here you can find the driver, firmwares, template for litex and the hal I'm using in my machine:
github.com/faeboli/Lcnc
if anybody wants to try out my implementation I would be grateful, I was able to test only a pair of boards
Thanks!
- unified driver
- acceleration limit in stepgen is now working
- FPGA internal clock for peripherals Is 40MHz and Is passing the timing closure.
- some pre coocked firmware are available
Now the board communicates to driver the peripherals configuration and the driver adapts automatically, no need to rebuild the driver for changes in peripherals or board version or revision. The only change that still require a rebuild of the driver Is the change of ip address. I suppose that there a way to pass parameters to the driver at invocation but still didnt try.
Todo:
- pass to the driver the ip and frequency when invoked
- create a configurator utility for speeding up the board configuration
here you can find the driver, firmwares, template for litex and the hal I'm using in my machine:
github.com/faeboli/Lcnc
if anybody wants to try out my implementation I would be grateful, I was able to test only a pair of boards
Thanks!
Last edit: 21 Nov 2022 11:22 by muvideo.
The following user(s) said Thank You: besriworld
Please Log in or Create an account to join the conversation.
22 Nov 2022 21:42 #257382
by andypugh
Replied by andypugh on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Rather than develop a whole new protocol, why not integrate Smart Serial? It is already well supported by LinuxCNC, it's open-source and at least one non-Mesa project (STMBL) uses it successfully.
Please Log in or Create an account to join the conversation.
22 Nov 2022 21:43 #257383
by andypugh
Replied by andypugh on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Rather than develop a whole new protocol, why not integrate Smart Serial? It is already well supported by LinuxCNC, it's open-source and at least one non-Mesa project (STMBL) uses it successfully.
Please Log in or Create an account to join the conversation.
23 Nov 2022 04:05 #257424
by wuyatom
Replied by wuyatom on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Attachments:
Please Log in or Create an account to join the conversation.
23 Nov 2022 07:15 - 23 Nov 2022 07:27 #257433
by muvideo
Hi @wuyatom
my 75e is a 8.0, so I cannot test directly on a 7.1,
the ping response is a good starting point, at least the fpga firmware is doing something good.
I see you have opened an issue on github, I'll follow up on there
Edit: I forgot to mention in the documentation that in case the ip is changed the driver need to
be updated changing the line 13 in Lcnc.h and then built.
This will be addressed in a future version where the ip will become an argument to insmod.
Maybe this is the issue you are facing?
Thanks.
Replied by muvideo on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
I used the firmware generated by your firmware lnc_75e_v7_30029i9s9e8p.py. I changed the IP address to test, and I can PING the board, but I can’t connect to the board with the test HAL. I use 5A-75E-V7.1colorlight, which can help Let me see what's wrong, thank you
Hi @wuyatom
my 75e is a 8.0, so I cannot test directly on a 7.1,
the ping response is a good starting point, at least the fpga firmware is doing something good.
I see you have opened an issue on github, I'll follow up on there
Edit: I forgot to mention in the documentation that in case the ip is changed the driver need to
be updated changing the line 13 in Lcnc.h and then built.
This will be addressed in a future version where the ip will become an argument to insmod.
Maybe this is the issue you are facing?
Thanks.
Last edit: 23 Nov 2022 07:27 by muvideo.
Please Log in or Create an account to join the conversation.
23 Nov 2022 15:40 #257482
by wuyatom
Replied by wuyatom on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Attachments:
Please Log in or Create an account to join the conversation.
23 Nov 2022 18:45 #257498
by muvideo
the first I would check is of the board is enabled.
In halshow check the status of Lcnc.00.enable Lcnc.00.enabled and Lcnc.00.enable-request
My setup for board enable Is here:
Lcnc/support_files/LcncMill/LcncMill.hal lines 13-24
Replied by muvideo on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
This can depend on a lot of things,谢谢,我按照你教的改了lcnc.h的IP地址,现在可以和板子通信了,现在出现新问题,不知道是否需要连接硬件测试还是什么,linuxcnc按jog或者运行代码会导致关节跟随错误
the first I would check is of the board is enabled.
In halshow check the status of Lcnc.00.enable Lcnc.00.enabled and Lcnc.00.enable-request
My setup for board enable Is here:
Lcnc/support_files/LcncMill/LcncMill.hal lines 13-24
Please Log in or Create an account to join the conversation.
24 Nov 2022 09:14 #257547
by TOLP2
Replied by TOLP2 on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
Spend last few days on cleaning the repository and create a package which is installable using pip. I've just tested an upload to
test.pypi.org
and this looks promising. The package has the following functions:
The process to get the driver and firmware up and running would be:
The process above will result in both a .svf-file and a .bit-file which can be uploaded to the FPGA.
NOTES:
- install Litex
- install the ECP5 toolchain (supported boards: 5A-75B and 5A-75E);
- build the firmware from the JSON-file
- install the driver in LinuxCNC
The process to get the driver and firmware up and running would be:
pip install chardet
pip install --extra-index-url https://test.pypi.org/simple/ litexcnc
litexcnc install_litex
litexcnc install_toolchain
litexcnc install_driver
litexcnc build_firmware <path-to-configuration-json> -o ./build --build
The process above will result in both a .svf-file and a .bit-file which can be uploaded to the FPGA.
NOTES:
- chardet will be included in the next release.
- As soon as the package is released to the main-server (pypi.org) the switch -i test.pypi.org/simple/ is no longer necessary
- Depending on your installation pip might be required to be replaced with pip3.
- To install Litex and the toolchain elevated acces might be required (sudo ...)
The following user(s) said Thank You: tuzki
Please Log in or Create an account to join the conversation.
27 Nov 2022 21:19 #257766
by TOLP2
Replied by TOLP2 on topic ColorCNC Colorlight 5A-75E/5A-75B as FPGA controller board
At this moment working on documenting Litex-CNC. A preview on the documentation is available on
readthedocs
.
Please Log in or Create an account to join the conversation.
Time to create page: 0.490 seconds