typedef _ADC AVRCpp::AnalogToDigital::Result |
Definition at line 114 of file ADC.h.
00115 { 00116 AlignRight = 0x00, 00117 AlignLeft = _ADLAR 00118 00119 }; // enum Adjustment
FreeRunningMode | |
AnalogComparator | |
ExternalInterruptRequest0 | |
Counter0CompareMatch | |
Counter0Overflow | |
Counter1CompareMatchB | |
Counter1Overflow | |
Counter1CaptureEvent |
Definition at line 209 of file ADC.h.
00210 { 00211 FreeRunningMode = 0x00, 00212 AnalogComparator = 0x01, 00213 ExternalInterruptRequest0 = 0x02, 00214 Counter0CompareMatch = 0x03, 00215 Counter0Overflow = 0x04, 00216 Counter1CompareMatchB = 0x05, 00217 Counter1Overflow = 0x06, 00218 Counter1CaptureEvent = 0x07 00219 00220 }; // enum AutoTriggerSource
Definition at line 135 of file ADC.h.
00136 { 00137 StartNow = _ADSC, 00138 StartLater = 0x00 00139 00140 }; // enum ConversionStart
Definition at line 128 of file ADC.h.
00129 { 00130 ADCEnable = _ADEN, 00131 ADCDisable = 0x00 00132 00133 }; // enum EnableFlag
Definition at line 142 of file ADC.h.
00143 { 00144 FreeRunMode = 0x20, 00145 FreeRunStopped = 0x00 00146 00147 }; // enum FreeRunning
Definition at line 121 of file ADC.h.
00122 { 00123 InterruptEnable = _ADIE, 00124 InterruptDisable = 0x00 00125 00126 }; // enum InterruptEnableFlag
void AVRCpp::AnalogToDigital::ControlSetUp | ( | EnableFlag | enableFlag, | |
ConversionStart | conversionStart, | |||
FreeRunning | freeRunning, | |||
InterruptEnableFlag | interruptEnableFlag, | |||
Prescaler | prescaler | |||
) | [inline] |
void AVRCpp::AnalogToDigital::Disable | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::DisableAutoTrigger | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::DisableFreeRun | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::Enable | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::EnableAutoTrigger | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::EnableFreeRun | ( | ) | [inline] |
Definition at line 320 of file ADC.h.
00320 { EnableAutoTrigger(); SetAutoTriggerSource(FreeRunningMode); }
void AVRCpp::AnalogToDigital::EnsureChangeSafety | ( | ) | [inline] |
Definition at line 229 of file ADC.h.
00230 { 00231 if (IsConverting() ) 00232 Assembler::NOP(); 00233 00234 } // EnsureChangeSafety
bool AVRCpp::AnalogToDigital::IsAutoTriggerEnabled | ( | ) | [inline] |
bool AVRCpp::AnalogToDigital::IsConverting | ( | ) | [inline] |
bool AVRCpp::AnalogToDigital::IsEnabled | ( | ) | [inline] |
bool AVRCpp::AnalogToDigital::IsFreeRunEnabled | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::SelectionSetUp | ( | Reference | reference, | |
Adjustment | adjustment, | |||
AnalogChannel | channel | |||
) | [inline] |
Definition at line 237 of file ADC.h.
00241 { 00242 EnsureChangeSafety(); 00243 ADMUX = reference | adjustment | channel; 00244 00245 } // SelectionSetUp
void AVRCpp::AnalogToDigital::SelectPrescaler | ( | Prescaler | prescaler | ) | [inline] |
void AVRCpp::AnalogToDigital::SetAutoTriggerSource | ( | AutoTriggerSource | source | ) | [inline] |
void AVRCpp::AnalogToDigital::SetChannel | ( | AnalogChannel | channel | ) | [inline] |
void AVRCpp::AnalogToDigital::SetDifferentialChannels | ( | AnalogChannel | positive, | |
AnalogChannel | negative, | |||
Gain | gain | |||
) | [inline] |
Definition at line 296 of file ADC.h.
00297 { 00298 if(gain == Gain1x) 00299 { 00300 ChangeBits<_ADMUX>(_MUX0 | _MUX1 | _MUX2 | _MUX3 | _MUX4, gain | positive | ((negative << 2) & 0x08)); 00301 } 00302 else 00303 { 00304 ChangeBits<_ADMUX>(_MUX0 | _MUX1 | _MUX2 | _MUX3, gain | (negative << 1) | (positive & 0x01)); 00305 } 00306 00307 } // SetDifferentialChannels
void AVRCpp::AnalogToDigital::StartConversion | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::StartFreeRun | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::StopFreeRun | ( | ) | [inline] |
void AVRCpp::AnalogToDigital::WaitWhileConverting | ( | ) | [inline] |
MTÜ TTÜ Robotiklubi |