/*
 * master_slave.h
 *
 *  Created on: 30 нояб. 2020 г.
 *      Author: stud
 */

#ifndef SRC_MASTER_SLAVE_H_
#define SRC_MASTER_SLAVE_H_


enum
{
MODE_DONTKNOW = 1,
MODE_MASTER,
MODE_SLAVE
};


//////////////////////////////////////////////////////////
#define MAX_COUNT_TRY_MASTER_BS1    200//40 //15  //5
#define MAX_COUNT_TRY_MASTER_BS2    100//40 //15 //40  //20
#define MAX_COUNT_WAIT_ANSWER_CONFIRM_MODE    20

#define MAX_COUNT_WAIT_SLAVE_TRY_MASTER 100


#define SIZE_LOG_MASTER_SLAVE_STATUS   50

void auto_select_master_slave(void);
void clear_errors_master_slave(void);


#endif /* SRC_MASTER_SLAVE_H_ */
