| ??? 12/04/02 10:59 Read: times |
#33741 - RE: Problem with reading timers |
Check the assmbler. The compiler SHOULD generate the MUL A, B instruction to do this, from this code.
But you don't really need it. All you actually want is to concatenate the two registers. You could do: unsigned char a[2]; int * ip; res[0] = TH0; res[1] = TL0; ip = (int *)a; That might be more efficient. But need to check if the bytes are the right way around - that could be compiler dependent? |



