Has anyone had any experience interfacing the AD7321 (Analog Devices) ADC using SPI. I could do with some code examples (C or 8051 Assembler). I have it connected up (hardware) ok but am having trouble selecting the correct clock idle state and phase.