| Line 13... |
Line 13... |
| 13 |
#define SPI_SER_INTF SER_INTF_USCIB0
|
13 |
#define SPI_SER_INTF SER_INTF_USCIB0
|
| 14 |
|
14 |
|
| 15 |
// SPI port definitions // Adjust this according to the
|
15 |
// SPI port definitions // Adjust this according to the
|
| 16 |
#define SPI_PxSEL P1SEL // MSP430 device being used.
|
16 |
#define SPI_PxSEL P1SEL // MSP430 device being used.
|
| 17 |
#define SPI_PxSEL2 P1SEL2 // Adjust the values for the chosen
|
17 |
#define SPI_PxSEL2 P1SEL2 // Adjust the values for the chosen
|
| 18 |
#define SPI_PxDIR P1DIR // interfaces, according to the pin
|
18 |
#define SPI_PxREN P1REN // interfaces, according to the pin
|
| 19 |
#define SPI_PxIN P1IN // assignments indicated in the
|
19 |
#define SPI_PxDIR P1DIR // assignments indicated in the
|
| 20 |
#define SPI_PxOUT P1OUT // chosen MSP430 device datasheet.
|
20 |
#define SPI_PxIN P1IN // chosen MSP430 device datasheet.
|
| - |
|
21 |
#define SPI_PxOUT P1OUT
|
| 21 |
#define SPI_SIMO BIT7
|
22 |
#define SPI_SIMO BIT7
|
| 22 |
#define SPI_SOMI BIT6
|
23 |
#define SPI_SOMI BIT6
|
| 23 |
#define SPI_UCLK BIT5
|
24 |
#define SPI_UCLK BIT5
|
| 24 |
|
25 |
|
| 25 |
//----------------------------------------------------------------------------
|
26 |
//----------------------------------------------------------------------------
|
| Line 47... |
Line 48... |
| 47 |
|
48 |
|
| 48 |
// CS Control
|
49 |
// CS Control
|
| 49 |
#define MMC_CS_LOW() MMC_CS_PxOUT &= ~MMC_CS // Card Select
|
50 |
#define MMC_CS_LOW() MMC_CS_PxOUT &= ~MMC_CS // Card Select
|
| 50 |
#define MMC_CS_HIGH() while(!halSPITXDONE); MMC_CS_PxOUT |= MMC_CS // Card Deselect
|
51 |
#define MMC_CS_HIGH() while(!halSPITXDONE); MMC_CS_PxOUT |= MMC_CS // Card Deselect
|
| 51 |
|
52 |
|
| - |
|
53 |
// Chip Detect
|
| - |
|
54 |
#define MMC_CD_STAT() MMC_CD_PxIN & MMC_CD
|
| - |
|
55 |
|
| 52 |
//----------------------------------------------------------------------------
|
56 |
//----------------------------------------------------------------------------
|
| 53 |
// VS10XX port selections. Select which port will be used for the interface
|
57 |
// VS10XX port selections. Select which port will be used for the interface
|
| 54 |
//----------------------------------------------------------------------------
|
58 |
//----------------------------------------------------------------------------
|
| 55 |
|
59 |
|
| 56 |
// VS10xx port definitions
|
60 |
// VS10xx port definitions
|