Loading…

方法名称: met_encode

方法ID: 0x40CE

方法标签: Method encode

方法描述: Encode big numbers into the internal sensor representation


  • {
  • unsigned short exponent;
  • unsigned short result;
  • exponent = 0;
  • if (input_value > 1600000)
  • {
  • exponent = 3;
  • result = input_value / 1000;
  • }
  • else
  • if (input_value > 160000)
  • {
  • exponent = 2;
  • result = input_value / 100. + 0.5;
  • }


请登录以获得完整内容