Understanding I2C readings on Arduino MEGA 2560 with Honeywell air flow sensor

If anyone else would come here in search for the code for this sensor I have made it and posting some methods below.

The sensor will respond to the first two requests after being powered with its serial number so keep that in mind. The sensor expects 3v (not 3.3v) on the i2c bus but it can be exceeded if the max sink current wont exceed 3 mA. If you use 5v on the i2c bus the internal protection diodes will not protect the device so make sure you wire it correctly.

#include <Wire.h>
byte X0, X1;
const int flowRange = 50;


float getChecksum(){  //Verify the EEPROM checksum against factory configuration. 
   Wire.beginTransmission(0x49);
   Wire.write(0x03);
   delay(1);
   Wire.requestFrom(0x49,0x02); // Request the transmitted two bytes from the two registers
   delay(1);
     if(Wire.available()<=2) {  // 
     X0 = Wire.read(); // Reads the data from the register
     X1 = Wire.read();   
   }
   Wire.endTransmission();
   float checksum = word(X0, X1); //Combine two bytes recieved.
   if (checksum == 52389){ //##From datasheet
       Serial.println("EEPROM Checksum match!");
       }
    else if (checksum == 52368){ //##From datasheet
        Serial.println("EEPROM Checksum error");
   }
 }

 float getFlowReading(){
   Wire.beginTransmission(0x49);
   Wire.requestFrom(0x49,0x02); // Request the transmitted two bytes from the two registers
   delay(1);
     if(Wire.available()<=2) {  // 
     X0 = Wire.read(); // Reads the data from the register
     X1 = Wire.read();   
   }
   Wire.endTransmission();
   float output = word(X0, X1); //Combine two bytes recieved.
   float flow=flowRange * ((output/16384) - 0.1)/0.8; // From datasheet
   float conversionFactor = ( (273.15/293.15)*(14.696/14.504) ); //Converting SLPM to NLPM;
   flow= flow*conversionFactor;
   return flow;
}


float getError(float flow){ //#Calculate error for readings lower and higher than 12.5% of flowrange. (Datasheet spec)
       float TEB;
       if (flow < flowRange*0.125){ 
           TEB=flowRange*0.005;
           }
       else  {
           TEB=0.04*flow;
       }
     return TEB;
}

void printSensorData(){
 float flow = getFlowReading();
 float error = getError(flow);
 Serial.print(flow);
 Serial.print(" ± ");
 Serial.println(error);
}