Subversion Repositories HomeAutomation

Rev

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

  1. #ifndef CHN_CHNMASTER
  2. #define CHN_CHNMASTER
  3.  
  4. /*-----------------------------------------------------------------------------
  5.  * Includes
  6.  *---------------------------------------------------------------------------*/
  7. /* system files */
  8. #include <avr/io.h>
  9. #include <avr/interrupt.h>
  10. #include <stdio.h>
  11. /* lib files */
  12. #include <config.h>
  13. #include <bios.h>
  14. #include <drivers/can/stdcan.h>
  15. #include <drivers/timer/timer.h>
  16. #include <drivers/mcu/gpio.h>
  17.  
  18. //to use PCINT lib. uncomment the line below
  19. //#include <drivers/mcu/pcint.h>
  20.  
  21. void chn_ChnMaster_RegisterListener( uint16_t channel_id, void (*UpdateFunc)(uint16_t, uint16_t) /* channel, value */ );
  22. void chn_ChnMaster_UpdateChannel( uint16_t channel_id, uint16_t value );
  23.  
  24. void chn_ChnMaster_Init(void);
  25. void chn_ChnMaster_Process(void);
  26. void chn_ChnMaster_HandleMessage(StdCan_Msg_t *rxMsg);
  27. void chn_ChnMaster_List(uint8_t ModuleSequenceNumber);
  28.  
  29.  
  30. #ifdef chn_ChnMaster_USEEEPROM
  31.     struct chn_ChnMaster_Data{
  32.         ///TODO: Define EEPROM variables needed by the module
  33.         uint8_t x;
  34.         uint16_t y;
  35.     }; 
  36. #endif
  37.  
  38. #endif // CHN_CHNMASTER
  39.