unsigned int humi_val,temp_val;
unsigned int rh_lin,rh_true;
unsigned char error,checksum;
unsigned int i;
SCK_OUT;
PwmInit();
s_connectionreset();
for(;;)
{ error=0;
s_transstart(); //transmission start
error+=s_write_byte(STATUS_REG_W);//send command to sensor
error+=s_write_byte(STATUS_REG_D); //send value of status register