comparison src/isr.inc @ 0:11d4fc797f74

init
author heinrichsweikamp
date Wed, 24 Apr 2013 19:22:45 +0200
parents
children ca4556fb60b9
comparison
equal deleted inserted replaced
-1:000000000000 0:11d4fc797f74
1 ;=============================================================================
2 ;
3 ; File isr.inc
4 ;
5 ;
6 ; Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved.
7 ;=============================================================================
8 ; HISTORY
9 ; 2011-08-06 : [mH] moving from OSTC code
10
11 SAFE_2BYTE_COPY MACRO from, to
12 local retry
13 retry:
14 movff from+1,WREG ; High byte in W.
15 movff WREG,to+1 ; and destination.
16 movff from+0,to+0 ; Copy low byte.
17 movff from+1,TABLAT ; another bank-safe read.
18 xorwf TABLAT,W ; High byte changed ?
19 bnz retry
20 ENDM