Mesa 7i90 in SPI mode

More
9 years 7 months ago #89536 by sleepybishop
Replied by sleepybishop on topic Mesa 7i90 in SPI mode
yes, the mesaflash from github has spi support. something like

mesaflash --device 7i90 --spi --addr /dev/spidev0.0 --write myfile.bit

your mileage may vary depending on kernel support. spi support on the pi has improved with later kernel releases, but depending on your distribution, the spi drivers may be a bit behind the times.

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

More
9 years 7 months ago #89538 by PKM
Replied by PKM on topic Mesa 7i90 in SPI mode
Thanks sleepybishop!

I use the latest RASPBIAN image. But the kernel must be one-year-old, 4.4.4rt9 from machinekit website...
If you know how where to get a more recent rt kernel, please give me a hint.
Compiling a kernel must take eternity on a raspberry...

Anyways, tomorrow I'll try installing mesaflash on Pi.

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

More
9 years 7 months ago #89579 by PKM
Replied by PKM on topic Mesa 7i90 in SPI mode
So, mesaflash compiled well, but it can't see 7i90 on my Pi 2.

Another question: what are symptoms of lost connection?
Say, I loaded hm2_rpspi and addf-ed it to a thread, so I can control CR leds. After 3-4 hrs, I can still issue setp and it works. Does it mean that the connection has been stable and never lost?

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

More
9 years 7 months ago #89584 by andypugh
Replied by andypugh on topic Mesa 7i90 in SPI mode
If that is the case then it at least means that the watchdog has never bitten, so there has been no interruption in the read/write sequence.
The following user(s) said Thank You: PKM

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

More
9 years 7 months ago #89957 by sleepybishop
Replied by sleepybishop on topic Mesa 7i90 in SPI mode
i noticed on my machines that sometimes mesaflash would only work after a fresh boot, if i had started and stopped linuxcnc, eg modules were loaded. then the card wouldnt be detected. what is the output of mesaflash?

you can also try running this tool too see if the card is responding with a "AA AA AA AA" preamble on /dev/spidev0.0
github.com/torvalds/linux/blob/master/tools/spi/spidev_test.c

also wrt to kernel build times, i used to have a separate box running distcc to cross compile kernels but it fried, i just compiled 4.9.15 directly on some boards, it took about 4 hours on a pi 3 and 16 hours on a pi zero.
The following user(s) said Thank You: PKM

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

More
9 years 7 months ago #89962 by jtheath
Replied by jtheath on topic Mesa 7i90 in SPI mode
One thing to note, mesaflash and spidev_test both assume the standard spi driver is loaded and available. The hm2_rpspi solution goes directly to the low-level hardware and at least originally required disabling the standard spi driver.
The following user(s) said Thank You: PKM

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

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