LinuxCNC-RIO - RealtimeIO for LinuxCNC based on FPGA (ICE40 / ECP5)

More
05 Feb 2025 18:00 - 05 Feb 2025 18:08 #320771 by meister
Works for me :)
www.youtube.com/shorts/ZcQjW4829R0

the modbus has some delay, thats why it is a little asynchronous
M64 P0
G4 P0.1
M64 P1
G4 P0.1
M64 P2
G4 P0.1
...
M65 P1
G4 P0.1
M65 P2
G4 P0.1
M65 P3
...


@Andrew
there is also a template now for your board, but without input yet, would be nice if you can give me your config for the inputs
Last edit: 05 Feb 2025 18:08 by meister.

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

More
07 Feb 2025 08:38 #320891 by babinda01
Hi Olli
Thank you once again for your prompt response to my issue.
I have done a very quick test and at the moment I am over the moon, all the outputs work as they should.
I am using your template for N4D3E16, with exactly your settings.
When I use LinuxCNC it works perfectly, but if I use the test-gui in riocore the outputs work, but i get the following errors in the terminal window.

loading board setup: Tangbob
connection via: UDP
IP: 192.168.10.194
PORT: 2390
WARNING: can not set timeouts: timed out
qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 457, resource id: 11699426, major code: 40 (TranslateCoords), minor code: 0
ERROR: modbus CSUM failed [173, 219] != [136, 17]
ERROR: modbus CSUM failed [92, 27] != [136, 17]
ERROR: modbus CSUM failed [92, 27] != [136, 17]
ERROR: modbus CSUM failed [173, 219] != [136, 17]
ERROR: modbus CSUM failed [60, 136] != [1, 225]
ERROR: modbus CSUM failed [108, 27] != [73, 209]
ERROR: modbus CSUM failed [173, 219] != [136, 17]


I will test for a little while longer to see if I can figure out if I have configured something incorrectly.

To use the inputs originally I used the following settings. I cant remember why I broke them into lots of 4, I'm thinking that if I put a "values" as 16 it wouldn't work

"inputs1_4": {
"address": 1,
"type": 3,
"register": 129,
"values": 4,
"is_float": false,
"scale": 1.0,
"unit": "",
"error_values": "",
"format": "d",
"timeout": 100,
"delay": 60,
"direction": "input"
},
"inputs5_8": {
"address": 1,
"type": 3,
"register": 133,
"values": 4,
"is_float": false,
"scale": 1.0,
"unit": "",
"error_values": "",
"format": "d",
"timeout": 100,
"delay": 60,
"direction": "input"
},
"inputs9_12": {
"address": 1,
"type": 3,
"register": 137,
"values": 4,
"is_float": false,
"scale": 1.0,
"unit": "",
"error_values": "",
"format": "d",
"timeout": 100,
"delay": 60,
"direction": "input"
},
"inputs13_16": {
"address": 1,
"type": 3,
"register": 140,
"values": 4,
"is_float": false,
"scale": 1.0,
"unit": "",
"error_values": "",
"format": "d",
"timeout": 100,
"delay": 60,
"direction": "input"
}
},


Thanks again.

Andrew

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

More
07 Feb 2025 10:24 #320902 by babinda01
Hi
Please ignore the last post.......The test-gui isn't so happy with the idea of modbus, but I have all 16 ins and 16 outs using the N4D3E16 working under Linuxcnc!!!!

Very Happy.

Thank you again Olli for such a great system.

Attached is my .json file for reference. This file has only really been used for configuring modbus, at this stage. Tomorrow I will try and configure it for using 2 modbus cards on separate addresses.

Regards

Andrew

 

File Attachment:

File Name: config.txt
File Size:10 KB
Attachments:
The following user(s) said Thank You: meister

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

More
10 Feb 2025 08:53 #321145 by meister
i have released a new version (dev->main),

but remember, never change a running system :)

If you update you also have to rebuild the gateware.

if you use i2c devices you probably have to change your config, it no longer runs individually but really as a bus (or several).

github.com/multigcs/riocore/blob/main/CHANGELOG.md
The following user(s) said Thank You: besriworld, kzali

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

More
10 Feb 2025 19:13 #321182 by meister
# Installer-Script (debian-bookworm only)

if you have a Debian-Bookworm installation (e.g. from the LinuxCNC ISO or the LinuxCNC raspberry image) you can simply use this script to install all depends and the icestorm and gowin toolchain (gowin only on Intel/AMD)

wget -O- www.multixmedia.org/riocore-installer.sh | bash

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

More
12 Feb 2025 08:08 #321329 by meister

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

More
14 Feb 2025 20:34 #321583 by meister
i found a bug in the avg call (wrong place)

if you use an avg filter and have problems with strange spikes, you should update :(


fixed in master and dev
The following user(s) said Thank You: tommylight

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

More
22 Feb 2025 01:16 #322249 by epineh
  I have managed to get one of my mill servos running on the bench, running closed loop to Linuxcnc via a Tang Nano, works very well, now waiting for PCB's to properly retrofit the mill. Thanks Olli for your awesome work.
 
Attachments:
The following user(s) said Thank You: tommylight

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

Time to create page: 0.153 seconds
Powered by Kunena Forum