45205 Parallax Inc, 45205 Datasheet - Page 161

SX TECH BOARD

45205

Manufacturer Part Number
45205
Description
SX TECH BOARD
Manufacturer
Parallax Inc
Type
MCUr
Datasheet

Specifications of 45205

Contents
Board
For Use With/related Products
SX MCUs
For Use With
28825 - MINI SOUND PLAYER SOUNDPAL130-28029 - KIT PARTS SMART SENSORS
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
This example for the SX20/28 will clear every General Purpose RAM register on every bank using
indirect addressing.
15.2.12 The Bank Instruction
Often it is desirable to set the bank select bits of the FSR with one instruction cycle (the MOV FSR,
#literal commands above take two cycles). The SX instruction set offers such an instruction called Bank.
The Bank instruction sets the upper bits of the FSR to point to the RAM bank required. Note: On the
SX48/52, the BANK instruction only selects one of 8 banks in either the lower 8 or upper 8 banks. FSR.7 selects
the lower or upper group of 8 banks. To select a bank, use MOV FSR, #literal or add an SETB FSR.7 instruction
after the BANK instruction. Here’s an example of how to use the Bank instruction on the SX20/28:
Init
Loop
$00-
$01-
$02-
$0F-
4
fr (5-bit address in instruction)
mov FSR, #$10
clr
inc
setb FSR.4
cjne FSR, #$10, Loop ; Repeat until all registers
Global
RTCC
IND
$0F
PC
3
Figure 29 - SX48/52 Indirect register addressing
Must be = $00
IND
FSR
2
7
$10-
$11-
$12-
$1F-
Bank Selection Bits
1
6
Bank 0
$0
$1
$2
$F
; FSR = addr of 1
; Clear register
; Point to next register
; Keep us on G.P. RAM area
; have been cleared
SX-Key/Blitz Development System Manual 2.0 Parallax, Inc. Page 161
0
5
Bank 1
$0
$1
$2
$F
15 Appendix E: SX Data Sheet
FSR ($04)
4
Bank 2
$F
$0
$1
$2
st
3
$00
RAM Reg.
$01 - $FF
Register Address
———
2
Bank 15
1
$0
$1
$2
$F
0

Related parts for 45205