Examples 6.14.2 16-bit comparator The program in this example compares the contents of two 16-bit markers. The result (greater, smaller, or equal) is evaluated by conditional jumps (see jump operations). In this case, O00.00 is set if reference value 1 is greater than reference value 2. HB LB V1: reference value 1 BM00.01 BM00.00 HB: high byte V2: reference value 2 BM00.03 BM00.02 LB: low byte CO: comparator output O00.00 HB LB V1 BM00.03 BM00.02 V2 CO O00.0 8 bit comparator Program LD BM00.00 ;compare V1 CMPD BM00.02 ;with V2 JP MARK3 ;jump if V1 smaller than V2 L PL00.00 ;log. 0 JP MARK4 ;to CO MARK3 L PL00.01 ;logical 1 MARK4 = O00.00 ;CO 129