I have two numbers represented in a hexadecimal format:
uint16_t NUM = 0xEEEE; // Numerator
uint16_t DENUM = 0XFFFF; // Denominator
I want to have the numeric value of the division. Let us declare a double here:
double divisonResult = (double)(NUM / DENUM); // Shall be 0.9333333333333333
When I debug, the value of divisonResult is always 0.
In my case, is casting allowed or not?
Is there another way to get the wanted result?