General information
Category:
Coding, syntax & commands
Could someone convert the following lines to foxpro code:
short tsht;
float tmp,cr,cpc;
uchar rbuf[10];
/* calculate the temperature */
tsht = rbuf[0];
if (rbuf[1] & 0x01)
tsht |= -256;
tmp = (float)(tsht/2);
cr = rbuf[6];
cpc = rbuf[7];
if (rbuf[7] == 0)
return 0;
else
tmp = tmp - (float)0.25 + (cpc - cr)/cpc;
Thanks in advance
Werner Vesteraas
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only