#ifndef Oslo_Demo_h
#define Oslo_Demo_h

#include <Arduino.h>
#include <Wire.h>
#include <TM1637Display.h>
#include <Grove_LED_Bar.h>
#include <PCF8574.h>
#include <Adafruit_PWMServoDriver.h>
#include <Adafruit_NeoPixel.h>

//CONSTANTS
#define ValveDelay 1000 
#define pwmON 2500
#define pwmOFF 0
#define numberLED 8

//ARDUINO DIGITAL PINS
#define fan 2
#define mixer 3
#define bg1_clk 4
#define bg1_data 5
#define bg2_clk 6
#define bg2_data 7
#define bg3_clk 8
#define bg3_data 9
#define bg4_clk 39
#define bg4_data 38
#define seg_clk 12
#define seg_data 13

#define bg5_clk 10
#define bg5_data 11
#define bg6_clk 41
#define bg6_data 40
#define bg7_clk 43
#define bg7_data 42
#define bg8_clk 45
#define bg8_data 44
#define btn1 46
#define btn2 47
#define buzzer 48
#define buzzerGND 49
#define RGB_panel 50

//ARDUINO ANALOG PINS
#define V1 A4
#define V5 A5
#define V2 A6
#define V6 A7
#define Counter_clock A8
#define Counter_up_down A9
#define Counter_reset A10
#define Alarm_1 A11
#define Alarm_3 A12
#define Alarm_5 A13
#define Alarm_7 A14
#define Heater_on_pin A15

//PWM1 PINS
#define RGB3_g 0
#define RGB3_r 1
#define RGB4_g 2
#define RGB4_r 3
#define RGB1_g 4
#define RGB1_r 5
#define RGB2_g 6
#define RGB2_r 7

//PWM2 PINS
#define RGB8_g 0
#define RGB8_r 1
#define RGB9_g 2
#define RGB9_r 3
#define RGB5_g 4
#define RGB5_r 5
#define RGB6_g 6
#define RGB6_r 7
#define RGB7_g 8
#define RGB7_r 9

//PWM3 PINS
#define PWM1 0
#define PWM2 1
#define PWM3 2
#define PWM4 3
#define PWM5 4
#define PWM6 5
#define PWM7 6
#define RGB10_g 12
#define RGB10_r 13
#define RGB11_g 14
#define RGB11_r 15


//valve colors
#define Valve_opened_g 900
#define Valve_opened_r 400
#define Valve_closed_g 0
#define Valve_closed_r 1500
#define RGB_on_g 1500
#define RGB_on_r 1000


//#define Task 50
//#define Tank 200
//#define Temperature_valves 20
#define TemperaturePT 50
#define Mixer_min_current 20
//#define Leakage 30

//#define Max_flow 30
//#define Max_temperature 180
#define Max_current 50
#define Max_speed 9200 //rpm
#define Current_peak 10
#define Max_TTD 10000 //temperature time delay [ms]
#define TD_speed 3

#endif
