Advanced Search

Search Results (Searched for: )

  • digiex_chris
  • digiex_chris
16 Dec 2024 23:01

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

Category: Computers and Hardware

Many thanks Zayoo !

i have add the code to the dev branch for testing.

if you want to use it, you can add
"rpi5": true,

to your json config

like this:


[code]{
"name": "IceShield",
"description": "RIO-IceShield on Raspberry PI5",
"boardcfg": "IceShield",
"protocol": "SPI",
"rpi5": true,
....
[/code]


I have tested it on dev. It works good with 2 changes:
I needed to set my spi speed at 1mhz due to my clock speed (I think), instead of 1.5mhz. I think we may need a way to configure this, as well as which spi dev to use. If we can configure which spi dev to use, it would be easier to use this on other systems as well. But for the main branch, I think we just need to support setting the spi speed.

Also, in toolchain.py, {cmd_cp} and {cmd_rm} were not evaluating correctly:
{cmd_cp} hash_new.txt hash_compiled.txt
/bin/sh: 1: {cmd_cp}: not found
I was able to make it work by changing the make by hand to cp -v. Probably not related to the rpi5 changes.

spiflash.sh doesn't work for an iceshield board, but that's to be expected I think. I'll look into that a little later. It's about not being able to set the board into reset mode via gpio25 I think, so flashrom can't read the rom size. I think there's an rpi4/5 compatible python gpio library out there, I'll see about writing a simple python helper for that instead of hitting the dev tree directly.
io.bin
bitfile: ./rio.bin ...
  reload drivers / set FPGA into reset mode
./spiflash.sh: line 52: echo: write error: Invalid argument
./spiflash.sh: line 54: /sys/class/gpio/gpio25/direction: No such file or directory
./spiflash.sh: line 61: test: : integer expression expected
  fill bitfile with zeros to reach flashsize:
   ERROR: dd can not read/write: dd if=/dev/zero of=/tmp/_flash.bin  bs= count=1


# ls /sys/class/gpio/
export  gpiochip399  gpiochip453  gpiochip459  gpiochip476  gpiochip480  unexport
  • COFHAL
  • COFHAL
16 Dec 2024 22:53
Replied by COFHAL on topic AX58100

AX58100

Category: EtherCAT

Are these values ​​in the xml file okay?
<master idx="0" appTimePeriod="1000000" refClockSyncCycles="-1"> <!-- was "5" -->
<dcConf assignActivate="300" sync0Cycle="*1" sync0Shift="1000000"/> <!-- was "0" -->
Displaying 21826 - 21827 out of 21827 results.
Time to create page: 0.383 seconds
Powered by Kunena Forum