examples/triface/hw/hw_sipo.h

Go to the documentation of this file.
00001 
00041 #ifndef HW_SIPO_H
00042 #define HW_SIPO_H
00043 
00044 #define LOAD_HIGH     (PORTB |= BV(PB3))
00045 #define LOAD_LOW      (PORTB &= ~BV(PB3))
00046 #define LOAD_INIT     (DDRB |= BV(PB3))
00047 #define SET_SCK_OUT   (DDRB |= BV(PB1))
00048 #define SET_SOUT_OUT  (DDRB |= BV(PB2))
00049 #define CLOCK_HIGH    (PORTB |= BV(PB1))
00050 #define CLOCK_LOW     (PORTB &= ~BV(PB1))
00051 #define SET_SOUT_HIGH (PORTB |= BV(PB2))
00052 #define SET_SOUT_LOW  (PORTB &= ~BV(PB2))
00053 #define CLOCK_PULSE   do { CLOCK_HIGH; CLOCK_LOW; } while(0)
00054 
00055 #define OE_OUT        (DDRG |= BV(PG3))
00056 #define OE_LOW        (PORTG &= BV(PG3))
00057 
00058 
00059 #endif // HW_SIPO_H