MSP430F1611 SPI.



Hi everyone,

I'm trying to interface an external ADC with the MSP430F1611's SPI.

I've written the code to initialize the SPI (seen below), but I now
want to test my Init_SPI by writing some data to it and probing it
using the scope to see that I've written data to it.

Eventually, I want to get data from an external ADC using SPI and
store it in memory.

Can anyone point me in the right direction?

Thank you so much! Much appreciated.

- Amy


====================INIT_SPI=========================

void Init_SPI(void)
{
P3SEL |= 0x3F; // Select P3.0,1,2,3,4,5
P3DIR |= 0x0B; // Select P3.1,3 as output
directions
P3OUT &= ~0x01;
ME1 |= USPIE0; // ENABLE USART0 SPI
UCTL0 |= CHAR + SYNC + MM; // 8-bit data, SPI mode
UTCTL0 |= CKPH + CKPL + SSEL1; // Inv.delay, ACLK
UBR00 = 0x2A; // Baud Rate = 115200
UBR10 = 0x0;
UMCTL0 = 0x0; // Clear Modulation
UCTL0 &= ~SWRST; // Initialize USART state machine

//_BIS_SR(LPM3_bits + GIE); // Enter LPM0 w/interrupt

} //end Init_SPI

===============================================

.



Relevant Pages

  • MSP430F1611 SPI Interface w/ADC
    ... I want to know how I can interface the SPI with an external ADC. ... I prefer using polling instead of ... interrups. ...
    (comp.arch.embedded)
  • Re: [spi-devel-general] Accelerometer, Gyros and ADCs etc within the kernel.
    ... say the HW SPI is pushed down to some lower level driver. ... interface via sysfs and something similar to the input subsystems ... a larger ring buffer in the kernel if necessary. ...
    (Linux-Kernel)
  • Re: FPGA programming driver architecture
    ... the second a parallel interface. ... as well as better in line with the Linux driver ... Considering the several FPGA models available and ways to program it, ... what goes into the specific interface modules (spi, parallel, etc). ...
    (Linux-Kernel)
  • Using... SPI and shift registers to expand PIC outputs
    ... using SPI to interface with shift registers. ... At this point it's become more or less clear to me that the SPI ... interface is the intuitive wiring job (data out to data in, clock out to ... One of the app notes has a spiel about disambiguating the ...
    (sci.electronics.design)
  • Re: SPI on the User Port ... Mode Hang-Ups.
    ... hard pressed to give up their RS232 port for this, ... Ethernet cart, or they have a cardreader on a PC/Linux box on the net ... registers between an SPI interface and a RS-232C interface, ...
    (comp.sys.cbm)