On Fri, 27 Mar 1998 13:27:34 -0500, you wrote: >On Fri, 27 Mar 1998 17:52:18 GMT TORRENS SR >writes: >>I need to find out whether the difference between two 3 digit BCD >>numbers is less that 30. My project involves positioning using a GPS >>reciever. This problem involves basic subtraction, but I've tried it >>and it's not that basic. Would anyone have a bit of code just lying >>about >>there somewhere or could you point me in some direction which might >>help. Cheers, Ross. > >I'd convert the numbers to binary first. Then it is much simpler to >process them. The conversion won't take very long either so it may be >faster than trying to optimize BCD processing. Ever wondered what the digit-carry flag is for? ____ ____ _/ L_/ Mike Harrison / White Wing Logic / wwl@netcomuk.co.uk _/ L_/ _/ W_/ Hardware & Software design / PCB Design / Consultancy _/ W_/ /_W_/ Industrial / Computer Peripherals / Hazardous Area /_W_/