mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-20 05:21:59 -04:00
Add code for near memory model.
This commit is contained in:
parent
035abe8707
commit
2d77a49535
|
@ -72,7 +72,11 @@ vRegTest1:
|
||||||
MOVW DE, #0x5566
|
MOVW DE, #0x5566
|
||||||
MOVW HL, #0x7788
|
MOVW HL, #0x7788
|
||||||
MOV CS, #0x01
|
MOV CS, #0x01
|
||||||
|
#if configMEMORY_MODE == 1
|
||||||
|
; ES is not saved or restored when using the near memory model so only
|
||||||
|
; test it when using the far model.
|
||||||
MOV ES, #0x02
|
MOV ES, #0x02
|
||||||
|
#endif
|
||||||
|
|
||||||
loop1:
|
loop1:
|
||||||
; Continuously check that the register values remain at their expected
|
; Continuously check that the register values remain at their expected
|
||||||
|
@ -104,10 +108,14 @@ loop1:
|
||||||
CMP A, #0x01
|
CMP A, #0x01
|
||||||
BZ +5
|
BZ +5
|
||||||
BR vRegTestError
|
BR vRegTestError
|
||||||
|
#if configMEMORY_MODE == 1
|
||||||
|
; ES is not saved or restored when using the near memory model so only
|
||||||
|
; test it when using the far model.
|
||||||
MOV A, ES
|
MOV A, ES
|
||||||
CMP A, #0x02
|
CMP A, #0x02
|
||||||
BZ +5
|
BZ +5
|
||||||
BR vRegTestError
|
BR vRegTestError
|
||||||
|
#endif
|
||||||
MOVW AX, #0x1122
|
MOVW AX, #0x1122
|
||||||
BR loop1
|
BR loop1
|
||||||
|
|
||||||
|
@ -132,7 +140,9 @@ vRegTest2:
|
||||||
MOVW DE, #0xddee
|
MOVW DE, #0xddee
|
||||||
MOVW HL, #0xff12
|
MOVW HL, #0xff12
|
||||||
MOV CS, #0x03
|
MOV CS, #0x03
|
||||||
|
#if configMEMORY_MODE == 1
|
||||||
MOV ES, #0x04
|
MOV ES, #0x04
|
||||||
|
#endif
|
||||||
|
|
||||||
loop2:
|
loop2:
|
||||||
CMPW AX, #0x99aa
|
CMPW AX, #0x99aa
|
||||||
|
@ -154,10 +164,12 @@ loop2:
|
||||||
CMP A, #0x03
|
CMP A, #0x03
|
||||||
BZ +5
|
BZ +5
|
||||||
BR vRegTestError
|
BR vRegTestError
|
||||||
|
#if configMEMORY_MODE == 1
|
||||||
MOV A, ES
|
MOV A, ES
|
||||||
CMP A, #0x04
|
CMP A, #0x04
|
||||||
BZ +5
|
BZ +5
|
||||||
BR vRegTestError
|
BR vRegTestError
|
||||||
|
#endif
|
||||||
MOVW AX, #0x99aa
|
MOVW AX, #0x99aa
|
||||||
BR loop2
|
BR loop2
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue