Rev. 1.20 64 January 23, 2015 Rev. 1.20 65 January 23, 2015
BS82B12A-3/BS82C16A-3/BS82D20A-3
Touch Key 8-Bit Flash MCU with LED/LCD Driver
BS82B12A-3/BS82C16A-3/BS82D20A-3
Touch Key 8-Bit Flash MCU with LED/LCD Driver
Input/Output Ports
HoltekmicrocontrollersofferconsiderableexibilityontheirI/Oports.Withtheinputoroutput
designationofeverypinfullyunderuserprogramcontrol,pull-highselectionsforallportsand
wake-upselectionsoncertainpins,theuserisprovidedwithanI/Ostructuretomeettheneedsofa
widerangeofapplicationpossibilities.
Thedevicesprovidebidirectionalinput/outputlineslabeledwithportnamesPA~PD.TheseI/O
portsaremappedtotheRAMDataMemorywithspecicaddressesasshownintheSpecialPurpose
DataMemorytable.AlloftheseI/Oportscanbeusedforinputandoutputoperations.Forinput
operation,theseportsarenon-latching,whichmeanstheinputsmustbereadyattheT2risingedge
ofinstruction"MOVA,[m]",wheremdenotestheportaddress.Foroutputoperation,allthedatais
latchedandremainsunchangeduntiltheoutputlatchisrewritten.
I/O Register List
Device
Register
Name
Bit
7 6 5 4 3 2 1 0
BS82B12A-3
BS82C16A-3
BS82D20A-3
PAWU PAWU7 — — PAWU4 PAWU3 PAWU2 PAWU1 PAWU0
PAPU PAPU7 — — PAPU4 PAPU
3 PAPU2 PAPU1 PAPU0
PA PA7 — — PA4 PA
3 PA2 PA1 PA0
PAC PAC7 — — PAC4 PAC
3 PAC2 PAC1 PAC0
PBPU PBPU7 PBPU6 PBPU
5 PBPU4 PBPU3 PBPU2 PBPU1 PBPU0
PB PB7 PB6 PB
5 PB4 PB3 PB2 PB1 PB0
PBC PBC7 PBC6 PBC
5 PBC4 PBC3 PBC2 PBC1 PBC0
PCPU PCPU7 PCPU6
PCPU5 PCPU4 PCPU3 PCPU2 PCPU1 PCPU0
PC PC7 PC6
PC5 PC4 PC3 PC2 PC1 PC0
PCC PCC7 PCC6
PCC5 PCC4 PCC3 PCC2 PCC1 PCC0
BS82C16A-3
BS82D20A-3
PDPU — — — — PDPU3 PDPU2 PDPU1 PDPU0
PD — — — —
PD3 PD2 PD1 PD0
PDC — — — —
PDC3 PDC2 PDC1 PDC0
PAWUn:PAwake-upfunctioncontrol
0:Disable
1:Enable
PAn/PBn/PCn/PDn:I/ODatabit
0:Data0
1:Data1
PACn/PBCn/PCCn/PDCn:I/OTypeselection
0:Output
1:Input
PAPUn/PBPUn/PCPUn/PDPUn:I/OPull-highfunctioncontrol
0:Disable
1:Enable