Introduction - If you have any usage issues, please Google them yourself
McS-51 fixed point operation operator library, fixed operation operator library file name DQ51. ASM, for ease of use, the relevant provisions are stated as follows:
1. Multi-byte fixed-point operands: use [R0] or [R1] to represent the number of consecutive units stored in R0 or R1 instructions
According to. A high byte of data in a small unit. For example, [R0]= 123456H, if (R0)= 30H, then (30H)= 12H,
H (31) = 34 h, h (32) = 56 h.
2. Operational accuracy: single point precision is the lowest value of the result.
3. Workspace: data workspace is fixed in PSW, A, B, R2 ~ R7. The program has good transparency if the user does not store irrelevant or non-expendable information in the workspace.
(1) label: BCDA function: multi-byte BCD code addition
Entry conditions: the number of bytes in R7 is added to [R0] and the number is in [R1].
Export information: and in [R0], the highest entry is in CY.
Impact resources: PSW, A, R2 stack requirements: 2 bytes