SPI

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
Emanuel Lourenco
Posts: 63
Joined: Mon Dec 23, 2013 5:51 pm
Been thanked: 8 times
Contact:

SPI

Post by Emanuel Lourenco »

Good night
I'm starting to study the SPI function. I found this table in the datasheet that will work.
My doubt is, how do I read the address 00h?


Greetings,
Emanuel Lourenço
Attachments
HEX.gif
HEX.gif (19.37 KiB) Viewed 5550 times

Spanish_dude
Posts: 594
Joined: Thu Sep 17, 2009 7:52 am
Location: Belgium
Has thanked: 63 times
Been thanked: 102 times
Contact:

Re: SPI

Post by Spanish_dude »

What device are you trying to communicate with ?
A datasheet would help.

You probably just have to send the 00h to the device, and a random byte to read what the device is outputting.

Emanuel Lourenco
Posts: 63
Joined: Mon Dec 23, 2013 5:51 pm
Been thanked: 8 times
Contact:

Re: SPI

Post by Emanuel Lourenco »

Good night

Yes, you're right.
I apologize
Then leave the equipment

http://datasheets.maximintegrated.com/e ... X31865.pdf

Thank you

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: SPI

Post by Benj »

Hello,

It looks like you pull the chip select low. send out a 0 to perfrom a read, then read a byte to collect the data from the register. Then raise the chip select to finish the transaction.

This might help.
http://matrixtsl.com/blog/?p=731

Emanuel Lourenco
Posts: 63
Joined: Mon Dec 23, 2013 5:51 pm
Been thanked: 8 times
Contact:

Re: SPI

Post by Emanuel Lourenco »

Benj wrote:Hello,

It looks like you pull the chip select low. send out a 0 to perfrom a read, then read a byte to collect the data from the register. Then raise the chip select to finish the transaction.

This might help.
http://matrixtsl.com/blog/?p=731
Very good information
helped a lot
Thanks

Post Reply