SPI low level driver for Virtex
Robert S. Grimes
rsg at alum.mit.edu
Fri Feb 29 17:56:03 UTC 2008
Hi Thomas,
Not that I'm ready yet, especially with my build problems, but does the
following make sense for inclusion in libbsp/powerpc/virtex/include/bsp.h?
#define RTEMS_BSP_SPI_AD7490_0_DEVICE_NAME "lsad0"
#define RTEMS_BSP_SPI_AD7490_0_DEVICE_PATH "/dev/spi0.lsad0"
#define RTEMS_BSP_SPI_AD7490_1_DEVICE_NAME "lsad1"
#define RTEMS_BSP_SPI_AD7490_1_DEVICE_PATH "/dev/spi0.lsad1"
#define RTEMS_BSP_SPI_AD7490_2_DEVICE_NAME "lsad2"
#define RTEMS_BSP_SPI_AD7490_2_DEVICE_PATH "/dev/spi0.lsad2"
#define RTEMS_BSP_SPI_AD7490_3_DEVICE_NAME "lsad3"
#define RTEMS_BSP_SPI_AD7490_3_DEVICE_PATH "/dev/spi0.lsad3"
#define RTEMS_BSP_SPI_AD7490_4_DEVICE_NAME "lsad4"
#define RTEMS_BSP_SPI_AD7490_4_DEVICE_PATH "/dev/spi0.lsad4"
#define RTEMS_BSP_SPI_AD7490_5_DEVICE_NAME "lsad5"
#define RTEMS_BSP_SPI_AD7490_5_DEVICE_PATH "/dev/spi0.lsad5"
#define RTEMS_BSP_SPI_FRAM_DEVICE_NAME "fram"
#define RTEMS_BSP_SPI_FRAM_DEVICE_PATH "/dev/spi1.fram"
#define RTEMS_BSP_SPI_SD_DEVICE_NAME "sd"
#define RTEMS_BSP_SPI_SD_DEVICE_PATH "/dev/spi2.sd"
As you may guess, my Virtex-4 configuration includes three instances of
their SPI IP (e.g. opb_spi), the first having 6 chip selects, and the
other two having just one each. I'm guessing the _DEVICE_NAME macros
don't really matter too much, as long as they are unique; I'm more
concerned about the _DEVICE_PATH macros.
Thomas Doerfler wrote:
> By the way: You wrote you would need a driver for a SPI Ramtron memory.
> I actually "virtualized" the spi-flash*.c driver to be adaptable to
> memory devices with similar interface, I already use it for a FM24L256.
> So I would recommend to write the the ADC driver first, and wait 'til I
> can update the CVS...)
>
> wkr,
> Thomas.
>
Again, not that I'm ready, but any updates?
Thanks much!
-Bob
More information about the users
mailing list