avr/cpp/IO.h File Reference

#include <avr/io.h>
#include "atmega8/IO.h"

Go to the source code of this file.

Namespaces

namespace  AVRCpp
namespace  AVRCpp::Internal

Classes

struct  AVRCpp::Internal::Register8< Derived >
struct  AVRCpp::Internal::Register16< Derived >
struct  AVRCpp::Internal::Register16< Derived >::Low
struct  AVRCpp::Internal::Register16< Derived >::High
struct  AVRCpp::Port< DDRReg, PORTReg, PINReg >
struct  AVRCpp::OutputPins< PortClass, flags >
struct  AVRCpp::InputPins< PortClass, flags >
struct  AVRCpp::Pins< PortClass, flags >
struct  AVRCpp::Bits< Register, bitFlags >
struct  AVRCpp::BasicInterrupt< EnableBit >
struct  AVRCpp::Interrupt< EnableBit, FlagBit >
struct  AVRCpp::InputPin0< PortClass >
struct  AVRCpp::OutputPin0< PortClass >
struct  AVRCpp::Pin0< PortClass >
struct  AVRCpp::InputPin1< PortClass >
struct  AVRCpp::OutputPin1< PortClass >
struct  AVRCpp::Pin1< PortClass >
struct  AVRCpp::InputPin2< PortClass >
struct  AVRCpp::OutputPin2< PortClass >
struct  AVRCpp::Pin2< PortClass >
struct  AVRCpp::InputPin3< PortClass >
struct  AVRCpp::OutputPin3< PortClass >
struct  AVRCpp::Pin3< PortClass >
struct  AVRCpp::InputPin4< PortClass >
struct  AVRCpp::OutputPin4< PortClass >
struct  AVRCpp::Pin4< PortClass >
struct  AVRCpp::InputPin5< PortClass >
struct  AVRCpp::OutputPin5< PortClass >
struct  AVRCpp::Pin5< PortClass >
struct  AVRCpp::InputPin6< PortClass >
struct  AVRCpp::OutputPin6< PortClass >
struct  AVRCpp::Pin6< PortClass >
struct  AVRCpp::InputPin7< PortClass >
struct  AVRCpp::OutputPin7< PortClass >
struct  AVRCpp::Pin7< PortClass >

Defines

#define __DECLARE_8BIT_REGISTER__(registerName)   struct _ ## registerName : Internal::Register8<_ ## registerName> { static inline reg8_t GetRegister() { return registerName; } }
#define __DECLARE_16BIT_REGISTER__(registerName)   struct _ ## registerName : Internal::Register16<_ ## registerName> { static inline reg16_t GetRegister() { return registerName; } }
#define __DECLARE_PORT__(portLetter)   typedef struct Port<_DDR ## portLetter, _PORT ## portLetter, _PIN ## portLetter> Port ## portLetter
#define __DECLARE_PORT_PIN__(pinNr)
#define __INTERRUPT_HANDLER_SUPPORT__
#define __DECLARE_BASIC_INTERRUPT__(interruptName, enableBitStart, enableBitEnd)   struct interruptName ## Interrupt : BasicInterrupt<enableBitStart, enableBitEnd> { __INTERRUPT_HANDLER_SUPPORT__ }
#define __DECLARE_INTERRUPT__(interruptName, enableBitStart, enableBitEnd, flagBitStart, flagBitEnd)   struct interruptName ## Interrupt : Interrupt<enableBitStart, enableBitEnd, flagBitStart, flagBitEnd> { __INTERRUPT_HANDLER_SUPPORT__ }
#define _P7   0x80
#define _P6   0x40
#define _P5   0x20
#define _P4   0x10
#define _P3   0x08
#define _P2   0x04
#define _P1   0x02
#define _P0   0x01
#define _DD7   0x80
#define _DD6   0x40
#define _DD5   0x20
#define _DD4   0x10
#define _DD3   0x08
#define _DD2   0x04
#define _DD1   0x02
#define _DD0   0x01
#define _PIN7   0x80
#define _PIN6   0x40
#define _PIN5   0x20
#define _PIN4   0x10
#define _PIN3   0x08
#define _PIN2   0x04
#define _PIN1   0x02
#define _PIN0   0x01

Typedefs

typedef volatile uint16_tAVRCpp::reg16_t
typedef volatile uint8_tAVRCpp::reg8_t

Functions

template<class Register>
void AVRCpp::SetBits (typename Register::Type flags)
template<class Register>
void AVRCpp::ClearBits (typename Register::Type flags)
template<class Register>
void AVRCpp::SetBitsTo (typename Register::Type flags, bool value)
template<class Register>
void AVRCpp::ToggleBits (typename Register::Type flags)
template<class Register>
void AVRCpp::ChangeBits (typename Register::Type selection, typename Register::Type value)
template<class Register>
Register::Type AVRCpp::SelectBits (typename Register::Type selection)
template<class Register>
bool AVRCpp::IsAnyBitSet (typename Register::Type flags)
template<class Register>
bool AVRCpp::IsBitsSet (typename Register::Type flags)


Define Documentation

#define __DECLARE_16BIT_REGISTER__ ( registerName   )     struct _ ## registerName : Internal::Register16<_ ## registerName> { static inline reg16_t GetRegister() { return registerName; } }

Definition at line 150 of file IO.h.

#define __DECLARE_8BIT_REGISTER__ ( registerName   )     struct _ ## registerName : Internal::Register8<_ ## registerName> { static inline reg8_t GetRegister() { return registerName; } }

Definition at line 147 of file IO.h.

#define __DECLARE_BASIC_INTERRUPT__ ( interruptName,
enableBitStart,
enableBitEnd   )     struct interruptName ## Interrupt : BasicInterrupt<enableBitStart, enableBitEnd> { __INTERRUPT_HANDLER_SUPPORT__ }

Definition at line 260 of file IO.h.

#define __DECLARE_INTERRUPT__ ( interruptName,
enableBitStart,
enableBitEnd,
flagBitStart,
flagBitEnd   )     struct interruptName ## Interrupt : Interrupt<enableBitStart, enableBitEnd, flagBitStart, flagBitEnd> { __INTERRUPT_HANDLER_SUPPORT__ }

Definition at line 263 of file IO.h.

#define __DECLARE_PORT__ ( portLetter   )     typedef struct Port<_DDR ## portLetter, _PORT ## portLetter, _PIN ## portLetter> Port ## portLetter

Definition at line 214 of file IO.h.

#define __DECLARE_PORT_PIN__ ( pinNr   ) 

Value:

template <class PortClass> struct InputPin ## pinNr : InputPins<PortClass, _P ## pinNr> {}; \
        template <class PortClass> struct OutputPin ## pinNr : OutputPins<PortClass, _P ## pinNr> {}; \
        template <class PortClass> struct Pin ## pinNr : Pins<PortClass, _P ## pinNr> {}

Definition at line 217 of file IO.h.

#define __INTERRUPT_HANDLER_SUPPORT__

Value:

static void Evoke(); \
                template <class DelegateType> static DelegateType & Me(); \
                template <class ControllerType> static ControllerType & Controller();

Definition at line 255 of file IO.h.

#define _DD0   0x01

Definition at line 285 of file IO.h.

#define _DD1   0x02

Definition at line 284 of file IO.h.

#define _DD2   0x04

Definition at line 283 of file IO.h.

#define _DD3   0x08

Definition at line 282 of file IO.h.

#define _DD4   0x10

Definition at line 281 of file IO.h.

#define _DD5   0x20

Definition at line 280 of file IO.h.

#define _DD6   0x40

Definition at line 279 of file IO.h.

#define _DD7   0x80

Definition at line 278 of file IO.h.

#define _P0   0x01

Definition at line 275 of file IO.h.

#define _P1   0x02

Definition at line 274 of file IO.h.

#define _P2   0x04

Definition at line 273 of file IO.h.

#define _P3   0x08

Definition at line 272 of file IO.h.

#define _P4   0x10

Definition at line 271 of file IO.h.

#define _P5   0x20

Definition at line 270 of file IO.h.

#define _P6   0x40

Definition at line 269 of file IO.h.

#define _P7   0x80

Definition at line 268 of file IO.h.

#define _PIN0   0x01

Definition at line 295 of file IO.h.

#define _PIN1   0x02

Definition at line 294 of file IO.h.

#define _PIN2   0x04

Definition at line 293 of file IO.h.

#define _PIN3   0x08

Definition at line 292 of file IO.h.

#define _PIN4   0x10

Definition at line 291 of file IO.h.

#define _PIN5   0x20

Definition at line 290 of file IO.h.

#define _PIN6   0x40

Definition at line 289 of file IO.h.

#define _PIN7   0x80

Definition at line 288 of file IO.h.


Generated on Sat Sep 15 23:41:29 2007 for AVR C++ Lib for ATmega8 by  doxygen 1.5.2
SourceForge.net Logo MTÜ TTÜ Robotiklubi