#ifndef __BLV_485_DEV_SHANGJINGTIANIRSENDFUN_H__
#define __BLV_485_DEV_SHANGJINGTIANIRSENDFUN_H__

#include "stdint.h"
#include "BLV_485_Protocol.h"
#include "BLV_All_Dev_Init.h"
#include "BLV_485_Dev_IrSendFun.h"


#define SJTTEM_MIN_SET   		0x10   //最低温度
#define SJTTEM_MAX_SET   		0x20   //最高温度



#define SJT_IRCtrlSendMax       0x03        //控制发送次数

/*对接设备为定制设备，一个网关接一个空调内机*/
#define RECVDATA_LEN_MAX        17          //接收数据最大长度
#define RECVDATA_LEN_MIN        8           //最小长度
#define TEMPREG_START           0x07D0      //空调温控状态，实际地址减一,起始地址为32001,则查询地址为02000 == 0x07D0
#define TEMPCONNECTREG_START    0x0000      //空调内机的连接状态，起始地址为30001,寄存器30001的地址为00000 == 0x0000

#define CTRLTEMPREG             0x03        //控制温控器状态，一台空调存3个寄存器。控制最多只能控制三个寄存器
#define ONLYTEMPREG             0x06        //查询一个空调内机的温控状态占用6个寄存器

#define READREGCMD              0x04    //读寄存器
#define WRITEONLYREGCMD         0x06    //写单个寄存器
#define WRITEMULTREGCMD         0x10    //写多个寄存器
#define WRITETEMPTYPE           0X05    //查询/设置空调型号



void RS485_SJTIrSend_Polling_Init(Device_Public_Information_G *BUS_Public, RS485_IR_INFO *RS485IRInfo);
void RS485_SJTIrSend_Active_Init(Device_Public_Information_G *BUS_Public, RS485_IR_INFO *RS485IRInfo);


#endif



