Subversion Repositories HomeAutomation

Rev

Rev 243 | Blame | Compare with Previous | Last modification | View Log | SVN | RSS feed

  1. #ifndef TC1047_H_
  2. #define TC1047_H_
  3.  
  4. #if defined(__AVR_ATmega88__)
  5.  
  6. /*-----------------------------------------------
  7.  * Includes
  8.  * ---------------------------------------------*/
  9. #include <stdlib.h>
  10. #include <inttypes.h>
  11.  
  12. /*-----------------------------------------------
  13.  * Defines
  14.  * ---------------------------------------------*/
  15.  
  16. /*
  17.  * Define which ADC that will be used, ADC0 to ADC7.
  18.  * If using ATmega88 PDIP ADC7 wont be aviable, only on TFQP.
  19.  * (syntax: TC_ADCx where x is the number och the ADC used)
  20.  */
  21. #define ADC5
  22.  
  23. /*
  24.  * For internal Vref 1.1 volt set VREF_INT, else  AVcc or Aref = 5 volt
  25.  * will be used.
  26.  *
  27.  */
  28. //#define VREF_INT
  29.  
  30. /*-----------------------------------------------
  31.  * Functions
  32.  * ---------------------------------------------*/
  33. void adcTemperatureInit();
  34. uint32_t getTC1047temperature();
  35. #else
  36.     #error Library still not compatible with others than mega88
  37. #endif
  38. #endif
  39.