view src/isr.inc @ 472:4fdf6886004b

CHANGE: Show warnings either in Customview (If active) _or_ next to warning sign NEW: Show battery type in information menu (T0:1.5V AA, T1:3.6V AA, T2:3.6V/0.8A LiIon, T3:Internal 18650, T4:Internal 16650)
author heinrichsweikamp
date Sun, 18 Dec 2016 18:20:39 +0100
parents 11d4fc797f74
children ca4556fb60b9
line wrap: on
line source

;=============================================================================
;
;   File isr.inc
;
;
;   Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved.
;=============================================================================
; HISTORY
;  2011-08-06 : [mH] moving from OSTC code

SAFE_2BYTE_COPY MACRO  from, to
        local   retry
retry:
        movff   from+1,WREG             ; High byte in W.
        movff   WREG,to+1               ; and destination.
        movff   from+0,to+0             ; Copy low byte.
        movff   from+1,TABLAT           ; another bank-safe read.
        xorwf   TABLAT,W                ; High byte changed ?
        bnz     retry
        ENDM