Hi was trying to interface the accelerometer available on the nexys 4 board. But i was not getting any data. Then I mapped the output pins to the JA PMOD header so I could probe them
Using an logic analyzer I saw that the sclk and Chip_select were working but the MOSI signal is full of zeroes.
I connected an 50MHz clk coming from the clock wizard, and then connected it to the ext_spi_clk and used an scale of 16 so the clk is about 3.16MHz
Question
dfdias
Hi was trying to interface the accelerometer available on the nexys 4 board. But i was not getting any data. Then I mapped the output pins to the JA PMOD header so I could probe them
Using an logic analyzer I saw that the sclk and Chip_select were working but the MOSI signal is full of zeroes.
I connected an 50MHz clk coming from the clock wizard, and then connected it to the ext_spi_clk and used an scale of 16 so the clk is about 3.16MHz
Below is the Block_Design
helloworld.c
Below is the data I acquired using saleae logic analyzer:
I submitted the C files containing the main (helloworld.c) wich is a almost linear copy of the polled example;
The accelmacros file has some values with the commands and register addressees of the SPI slave.
Do you have any hint of what I am missing?
Thanks in advance.
accelmacros.h
Link to comment
Share on other sites
2 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.