3namespace havells_solar {
 
    5static const float TWO_DEC_UNIT = 0.01;
 
    6static const float ONE_DEC_UNIT = 0.1;
 
    7static const float NO_DEC_UNIT = 1;
 
    8static const float MULTIPLY_TEN_UNIT = 10;
 
   11static const uint16_t HAVELLS_PV_1_VOLTAGE = 0x0006;
 
   12static const uint16_t HAVELLS_PV_1_CURRENT = 0x0007;
 
   13static const uint16_t HAVELLS_PV_2_VOLTAGE = 0x0008;
 
   14static const uint16_t HAVELLS_PV_2_CURRENT = 0x0009;
 
   15static const uint16_t HAVELLS_PV_1_POWER = 0x000A;
 
   16static const uint16_t HAVELLS_PV_2_POWER = 0x000B;
 
   19static const uint16_t HAVELLS_SYSTEM_ACTIVE_POWER = 0x000C;
 
   20static const uint16_t HAVELLS_SYSTEM_REACTIVE_POWER = 0x000D;
 
   21static const uint16_t HAVELLS_GRID_FREQUENCY = 0x000E;
 
   22static const uint16_t HAVELLS_PHASE_1_VOLTAGE = 0x000F;
 
   23static const uint16_t HAVELLS_PHASE_1_CURRENT = 0x0010;
 
   24static const uint16_t HAVELLS_PHASE_2_VOLTAGE = 0x0011;
 
   25static const uint16_t HAVELLS_PHASE_2_CURRENT = 0x0012;
 
   26static const uint16_t HAVELLS_PHASE_3_VOLTAGE = 0x0013;
 
   27static const uint16_t HAVELLS_PHASE_3_CURRENT = 0x0014;
 
   30static const uint16_t HAVELLS_TOTAL_ENERGY_PRODUCTION = 0x0015;
 
   31static const uint16_t HAVELLS_TOTAL_GENERATION_TIME = 0x0017;
 
   32static const uint16_t HAVELLS_TODAY_PRODUCTION = 0x0019;
 
   33static const uint16_t HAVELLS_TODAY_GENERATION_TIME = 0x001A;
 
   36static const uint16_t HAVELLS_INVERTER_MODULE_TEMP = 0x001B;
 
   37static const uint16_t HAVELLS_INVERTER_INNER_TEMP = 0x001C;
 
   38static const uint16_t HAVELLS_INVERTER_BUS_VOLTAGE = 0x001D;
 
   39static const uint16_t HAVELLS_PV1_VOLTAGE_SAMPLED_BY_SECONDARY_CPU = 0x001E;
 
   40static const uint16_t HAVELLS_PV2_VOLTAGE_SAMPLED_BY_SECONDARY_CPU = 0x001F;
 
   41static const uint16_t HAVELLS_PV1_INSULATION_OF_P_TO_GROUND = 0x0024;
 
   42static const uint16_t HAVELLS_PV2_INSULATION_OF_P_TO_GROUND = 0x0025;
 
   43static const uint16_t HAVELLS_INSULATION_OF_PV_N_TO_GROUND = 0x0026;
 
   44static const uint16_t HAVELLS_GFCI_VALUE = 0x002A;
 
   45static const uint16_t HAVELLS_DCI_OF_R = 0x002B;
 
   46static const uint16_t HAVELLS_DCI_OF_S = 0x002C;
 
   47static const uint16_t HAVELLS_DCI_OF_T = 0x002D;
 
Providing packet encoding functions for exchanging data with a remote host.