#ifndef _CONTROL_H_
#define _CONTROL_H_

#if defined(BOARD_SOLARIUM_VLAD)
    #define CHANNELS_NUM            3
    #define SOLAR_MODES_COUNT       3
    #define SOLAR_MODE_COLLATEN     0
    #define SOLAR_MODE_UF           1
    #define SOLAR_MODE_MAX          2
#else
    #define CHANNELS_NUM        8
#endif

#define CHANNEL_1    0
#define CHANNEL_2    1
#define CHANNEL_3    2
#define CHANNEL_4    3
#define CHANNEL_5    4
#define CHANNEL_6    5
#define CHANNEL_7    6
#define CHANNEL_8    7
#define CHANNEL_9    8
#define CHANNEL_10   9

#define CONTROL_STATE_OFF           0
#define CONTROL_STATE_COLLATEN      1
#define CONTROL_STATE_UF            2
#define CONTROL_STATE_MAX           3
#define CONTROL_STATE_PAUSED        4
#define CONTROL_STATE_VENT          5

extern CPU_INT08U control_channels[CHANNELS_NUM];

extern void InitControls(void);
extern void control_1ms_callback(void);
extern void SetControl(CPU_INT08U ch, CPU_INT08U state);
extern CPU_INT08U GetControlState(CPU_INT08U ch);
extern void LoadControlChannels(void);

#endif //#ifndef _CONTROL_H_
