Subversion Repositories Projects

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1702 - 1
#ifndef Spi_h
2
#define Spi_h
3
 
4
// Get the common arduino functions
5
#if defined(ARDUINO) && ARDUINO >= 100
6
        #include "Arduino.h"
7
#else
8
        #include "wiring.h"
9
#endif
10
 
11
#define SCK_PIN   13
12
#define MISO_PIN  12
13
#define MOSI_PIN  11
14
#define SS_PIN    10  // <------- !!! (Remember! This pin will select USB host chip Max3421)
15
 
16
class SPI
17
{
18
  public:
19
    SPI(void);
20
    void mode(byte);
21
    byte transfer(byte);
22
    byte transfer(byte, byte);
23
};
24
 
25
extern SPI Spi;
26
 
27
#endif