fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. float freq_rang_L=1;
  5. float freq_rang_H=2;
  6. char a[13]={0x00, 0x00, 0x94, 0x01, 0x00, 0x00, 0x75, 0x30, 0x00, 0x04, 0x93, 0xe0, 0x00};
  7.  
  8.  
  9. freq_rang_L = (float)(ntohl(*((unsigned int*)&a[4]))) / 999;
  10. freq_rang_H = (float)(ntohl(*((unsigned int*)&a[8]))) / 999;
  11.  
  12. printf("%f %f\n", freq_rang_L, freq_rang_H);
  13.  
  14. return 0;
  15. }
  16.  
Success #stdin #stdout 0s 5284KB
stdin
Standard input is empty
stdout
30.030029 300.300293