i received bytes data from some other function to myfunction(const void *data) where pointer data stores the values like {0,0,0,0,0,0,0,40,20,0,0,0,0,0,0}.
I created an array data1 to store the values {40,20,0,0,0,0,0,0} from the above values considering endianess issue i also reversed data1 and used memcpy to copy data1 but having problem when i call myfunction then it has argument data not data1. So anyone know how can i call data1 by calling myfunction.
I want to access just values from {40,20,0,0,0,0,0,0} and convert into a double type value that should give 8.0 .