Hi,
Reading the values from the sensor works for me (not writing, I don't
know why).
You can have a look at the airframe ENAC/fixed-wing/twinjet2.xml
The flags for SPI are :
ap.CFLAGS += -DUSE_SPI -DSPI_MASTER -DUSE_SPI_SLAVE0
ap.srcs += spi.c $(SRC_ARCH)/spi_hw.c
and do not forget the flag -DUSE_MODULES
The module is not complete yet. One bug I know is the conversion from
quaternion to euler angles. The DRDY is not used, so you should
configure manually the VN100 for not sending periodical messages.
And your wiring looks good !
Gautier
Le 09/06/2010 22:01, Gayan Gamage a écrit :
Hi,
i am trying to integrate a vectornav VN100 AHRS sensor to the paparazzi
board (tiny2) through the SPI port. There is the code inside the
modules/ins folder. I connected the wiring properly (I guess) and
configured the module in the airframe file and added -DUSE_SPI,
_DSPI_MASTER, DUSE_SPI_SLAVE0 too as cflags. But there is no connection
with the sensor. Any help is highly appreciated
(connection)
vectornav VN 100pin -> tiny 2 SPI port pins
Gnd -> Gnd
Vcc->+3.3 V
SPI_CS (SPI SLAVE SELECT) ->SSEL
MOSI -> SPI_MOSI
MISO ->SPI_MISO
SPI clock -> SCK (SPI serial clock)
DR_INT (data ready interrupt.) - > DRDY (external interrupt)
VN 100 sensor layout is at http://www.vectornav.com/Downloads/Support/UM002.pdf
--
Gayan
_______________________________________________
Paparazzi-devel mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
_______________________________________________