SONiX TECHNOLOGY CO. SN8F2271B User Manual

Sn8f2270b series, 8-bit
Table of Contents

Advertisement

Quick Links

SN8F2270B Series
USER'S MANUAL
SN8F2271B
SN8F22711B
SN8F22721B
S
O
N
i
X
S
O
N
i
X
SONIX reserves the right to make change without further notice to any products herein to improve reliability, function or design. SONIX does not
assume any liability arising out of the application or use of any product or circuit described herein; neither does it convey any license under its patent
rights nor the rights of others. SONIX products are not designed, intended, or authorized for us as components in systems intended, for surgical
implant into the body, or other applications intended to support or sustain life, or for any other application in which the failure of the SONIX product
could create a situation where personal injury or death may occur. Should Buyer purchase or use SONIX products for any such unintended or
unauthorized application. Buyer shall indemnify and hold SONIX and its officers, employees, subsidiaries, affiliates and distributors harmless against
all claims, cost, damages, and expenses, and reasonable attorney fees arising out of, directly or indirectly, any claim of personal injury or death
associated with such unintended or unauthorized use even if such claim alleges that SONIX was negligent regarding the design or manufacture of
the part.
SONiX TECHNOLOGY CO., LTD
8
-
B
i
t
M
i
8
-
B
i
t
M
i
c
r
o
-
C
o
n
c
r
o
-
C
o
n
Page 1
SN8F2270B Series
USB 2.0 Low-Speed 8-Bit Micro-Controller
t
r
o
l
l
e
r
t
r
o
l
l
e
r
Version 1.3

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the SN8F2271B and is the answer not in the manual?

Questions and answers

Summary of Contents for SONiX TECHNOLOGY CO. SN8F2271B

  • Page 1 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller SN8F2270B Series USER’S MANUAL SN8F2271B SN8F22711B SN8F22721B SONIX reserves the right to make change without further notice to any products herein to improve reliability, function or design. SONIX does not assume any liability arising out of the application or use of any product or circuit described herein; neither does it convey any license under its patent rights nor the rights of others.
  • Page 2: Amendment History

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller AMENDMENT HISTORY Version Date Description VER1.0 2009/3/23 version 1.0 VER1.1 2009/6/17 Modify SN8F22721S/X/K to SN8F22721S/X/P VER1.2 2009/7/9 Modify PWM output pin to p5.3. VER1.3 2010/3/3 1. Add UE1D at UE1R 2. Add UE2D at UE2R 3.
  • Page 3: Table Of Contents

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Table of Content AMENDMENT HISTORY.......................... 2 PRODUCT OVERVIEW......................... 8 1.1 FEATURES .............................. 8 1.2 SYSTEM BLOCK DIAGRAM ........................ 9 1.3 PIN ASSIGNMENT ..........................10 1.4 PIN DESCRIPTIONS ..........................11 1.5 PIN CIRCUIT DIAGRAMS ........................12 CENTRAL PROCESSOR UNIT (CPU) ....................
  • Page 4 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.1 OVERVIEW ............................38 3.2 POWER ON RESET..........................40 3.3 WATCHDOG RESET ..........................40 3.4 BROWN OUT RESET ........................... 41 3.4.1 BROWN OUT DESCRIPTION ......................41 3.4.2 THE SYSTEM OPERATING VOLTAGE DECSRIPTION............... 42 3.4.3 BROWN OUT RESET IMPROVEMENT..................
  • Page 5 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.10 WAKEUP INTERRUPT OPERATION ....................64 6.11 SIO INTERRUPT OPERATION......................65 6.12 MULTI-INTERRUPT OPERATION ....................66 I/O PORT ..............................67 7.1 I/O PORT MODE ........................... 67 7.2 I/O PULL UP REGISTER ........................68 7.3 I/O PORT DATA REGISTER ........................
  • Page 6 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 9.5.6 USB endpoint’s NAK handshaking flag REGISTER ............... 90 9.5.7 USB ENDPOINT 0 ENABLE REGISTER ..................90 9.5.8 USB ENDPOINT 1 ENABLE REGISTER ..................91 9.5.9 USB ENDPOINT 2 ENABLE REGISTER ..................92 9.5.10 USB DATA POINTER REGISTER ....................
  • Page 7 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 17.1 INTRODUCTION .......................... 118 17.2 MARKING INDETIFICATION SYSTEM..................118 17.3 MARKING EXAMPLE ......................... 119 17.4 DATECODE SYSTEM ......................... 119 Version 1.3 SONiX TECHNOLOGY CO., LTD Page 7...
  • Page 8: Product Overview

    All ROM area CALL address instruction. All ROM area lookup table function (MOVC) Features Selection Table TIMER WAKE-UP CHIP I/O pin ROM RAM STACK PACKAGE PIN NO. SN8F2271B 5K*16 192*8 SN8F22711B 5K*16 192*8 SN8F22721B 5K*16 192*8 DIP/SOP/SSOP Version 1.3 SONiX TECHNOLOGY CO., LTD Page 8...
  • Page 9: System Block Diagram

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 1.2 SYSTEM BLOCK DIAGRAM Flash Internal Internal memory WATCHDOG TIMER High RC Low RC FLAGS VREG33 3.3v REGULATOR TIMING GENERATOR VREG25 2.5v REGULATOR Low speed USB SIE SYSTEM REGISTERS INTERRUPT CONTROL TIMER & COUNTER BUZZER Version 1.3 SONiX TECHNOLOGY CO., LTD...
  • Page 10: Pin Assignment

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 1.3 PIN ASSIGNMENT SN8F22711BS (SOP 14 pins) 14 DP VREG33 13 VSS 12 VREG25 P0.1/INT1 11 P1.4 P5.3/PWM0 10 P1.6/RST P1.0 P1.3 P1.1 P1.2 SN8F22711BS SN8F2271BJ (QFN 16 pins) 16 15 14 13 VDD 1 ●...
  • Page 11: Pin Descriptions

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 1.4 PIN DESCRIPTIONS PIN NAME TYPE DESCRIPTION VDD, VSS Power supply input pins for digital circuit. P0.0: Port 0.0 bi-direction pin. Schmitt trigger structure and built-in pull-up resisters as input mode. P0.0/INT0 Built wakeup function. INT0: External interrupt 0 input pin.
  • Page 12: Pin Circuit Diagrams

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 1.5 PIN CIRCUIT DIAGRAMS Port 0, 1, 5 structures: Pull-Up PnUR Input Bus Output Output Bus Latch Pin RST structure: Ext. Reset Code Option Int. Bus Int. Rst Version 1.3 SONiX TECHNOLOGY CO., LTD Page 12...
  • Page 13: Central Processor Unit (Cpu)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller CENTRAL PROCESSOR UNIT (CPU) 2.1 MEMORY MAP 2.1.1 PROGRAM MEMORY (ROM) 5K words ROM User reset vector 0000H Reset vector Jump to user start address 0001H General purpose area 0007H 0008H Interrupt vector User interrupt vector 0009H User program...
  • Page 14: Reset Vector (0000H)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.1.1 RESET VECTOR (0000H) A one-word vector address area is used to execute system reset. Power On Reset (NT0=1, NPD=0). Watchdog Reset (NT0=0, NPD=0). External Reset (NT0=1, NPD=1). After power on reset, external reset or watchdog timer overflow reset, then the chip will restart the program from address 0000h and all system registers will be set as default values.
  • Page 15: Interrupt Vector (0008H)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.1.2 INTERRUPT VECTOR (0008H) A 1-word vector address area is used to execute interrupt request. If any interrupt service executes, the program counter (PC) value is stored in stack buffer and jump to 0008h of program memory to execute the vectored interrupt. Users have to define the interrupt vector.
  • Page 16 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: Defining Interrupt Vector. The interrupt service routine is following user program. .CODE ; 0000H START ; Jump to user program address. … ; Interrupt vector. MY_IRQ ; 0008H, Jump to interrupt service routine address. START: ;...
  • Page 17: Look-Up Table Description

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.1.3 LOOK-UP TABLE DESCRIPTION In the ROM’s data lookup function, Y register is pointed to middle byte address (bit 8~bit 15) and Z register is pointed to low byte address (bit 0~bit 7) of ROM. After MOVC instruction executed, the low-byte data will be stored in ACC and high-byte data stored in R register.
  • Page 18 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: Modify above example by “INC_YZ” macro. B0MOV Y, #TABLE1$M ; To set lookup table1’s middle address B0MOV Z, #TABLE1$L ; To set lookup table1’s low address. MOVC ; To lookup data, R = 00H, ACC = 35H INC_YZ ;...
  • Page 19: Jump Table Description

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.1.4 JUMP TABLE DESCRIPTION The jump table operation is one of multi-address jumping function. Add low-byte program counter (PCL) and ACC value to get one new PCL. If PCL is overflow after PCL+ACC, PCH adds one automatically. The new program counter (PC) points to a series jump instructions as a listing table.
  • Page 20 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: “@JMP_A” application in SONIX macro file called “MACRO3.H”. B0MOV A, BUF0 ; “BUF0” is from 0 to 4. @JMP_A ; The number of the jump table listing is five. A0POINT ; ACC = 0, jump to A0POINT A1POINT ;...
  • Page 21: Checksum Calculation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.1.5 CHECKSUM CALCULATION The last ROM addresses are reserved area. User should avoid these addresses (last address) when calculate the Checksum value. Example: The demo program shows how to calculated Checksum from 00H to the end of user’s code. A,#END_USER_CODE$L B0MOV END_ADDR1, A...
  • Page 22: Code Option Table

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.2 CODE OPTION TABLE Code Option Content Function Description Watchdog timer is always on enable even in power down and green Always_On mode. Watch_Dog Enable watchdog timer. Watchdog timer stops in power down mode and Enable green mode.
  • Page 23: Data Memory (Ram)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.3 DATA MEMORY (RAM) 192 X 8-bit RAM RAM location Address 000h BANK 0 “ “ General purpose area “ “ “ 07Fh BANK 0 080h 80h~FFh of Bank 0 store system registers (128 “...
  • Page 24: System Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4 SYSTEM REGISTER 2.1.4.1 SYSTEM REGISTER TABLE PFLAG RBANK TC0M TC0C TC0R USTAT USB_IN EP0OUT UE0R UE1R UE2R T_EN _ACK _NAK _CNT UDP0_ UDR0_ UDR0_ EP1OU EP2OU UDP0_L UPID UToggle T_CNT T_CNT PEROM PEROM PERAM PERAM...
  • Page 25: Bit Definition Of System Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.3 BIT DEFINITION of SYSTEM REGISTER Address Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0 Remarks 082H RBIT7 RBIT6 RBIT5 RBIT4 RBIT3 RBIT2 RBIT1 RBIT0 083H ZBIT7 ZBIT6 ZBIT5 ZBIT4 ZBIT3 ZBIT2 ZBIT1 ZBIT0 084H YBIT7...
  • Page 26 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 0C9H USBIEN TC0IEN T0IEN SIOIEN WAKEIEN P01IEN P00IEN INTEN 0CAH CPUM1 CPUM0 CLKMD STPHX OSCM 0CCH WDTR7 WDTR6 WDTR5 WDTR4 WDTR3 WDTR2 WDTR1 WDTR0 WDTR 0CEH 0CFH PC12 PC11 PC10 0D0H 0D1H 0D5H 0D8H T0ENB T0rate2...
  • Page 27: Accumulator

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.4 ACCUMULATOR The ACC is an 8-bit data register responsible for transferring or manipulating data between ALU and data memory. If the result of operating is zero (Z) or there is carry (C or DC) occurrence, then these flags will be set to PFLAG register. ACC is not in data memory (RAM), so ACC can’t be access by “B0MOV”...
  • Page 28: Program Flag

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.5 PROGRAM FLAG The PFLAG register contains the arithmetic status of ALU operation, system reset status and LVD detecting status. NT0, NPD bits indicate system reset status including power on reset, LVD reset, reset by external pin active and watchdog reset.
  • Page 29: Program Counter

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.6 PROGRAM COUNTER The program counter (PC) is a 13-bit binary counter separated into the high-byte 5 and the low-byte 8 bits. This counter is responsible for pointing a location in order to fetch an instruction for kernel circuit. Normally, the program counter is automatically incremented with each instruction during program execution.
  • Page 30 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller If the destination increased by 1, which results overflow of 0xFF to 0x00, the PC will add 2 steps to skip next instruction. INCS instruction: BUF0 INCS C0STEP ; Jump to C0STEP if ACC is not zero. …...
  • Page 31 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller MULTI-ADDRESS JUMPING Users can jump around the multi-address by either JMP instruction or ADD M, A instruction (M = PCL) to activate multi-address jumping function. Program Counter supports “ADD M,A”, ”ADC M,A” and “B0ADD M,A” instructions for carry to PCH when PCL overflow automatically.
  • Page 32: Y, Z Registers

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.7 Y, Z REGISTERS The Y and Z registers are the 8-bit buffers. There are three major functions of these registers. can be used as general working registers can be used as RAM data pointers with @YZ register can be used as ROM data pointer with the MOVC instruction for look-up table 084H Bit 7...
  • Page 33: R Registers

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.1.4.8 R REGISTERS R register is an 8-bit buffer. There are two major functions of the register. Can be used as working register For store high-byte data of look-up table (MOVC instruction executed, the high-byte data of specified ROM address will be stored in R register and the low-byte data will be stored in ACC).
  • Page 34: Addressing Mode

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.2 ADDRESSING MODE 2.2.1 IMMEDIATE ADDRESSING MODE The immediate addressing mode uses an immediate data to set up the location in ACC or specific RAM. Example: Move the immediate data 12H to ACC. A, #12H ;...
  • Page 35: Stack Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.3 STACK OPERATION 2.3.1 OVERVIEW The stack buffer has 8-level. These buffers are designed to push and pop up program counter’s (PC) data when interrupt service routine and “CALL” instruction are executed. The STKP register is a pointer designed to point active level in order to push or pop up data from stack buffer.
  • Page 36: Stack Registers

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.3.2 STACK REGISTERS The stack pointer (STKP) is a 3-bit register to store the address used to access the stack buffer, 13-bit data memory (STKnH and STKnL) set aside for temporary storage of stack addresses. The two stack operations are writing to the top of the stack (push) and reading from the top of stack (pop).
  • Page 37: Stack Operation Example

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 2.3.3 STACK OPERATION EXAMPLE The two kinds of Stack-Save operations refer to the stack pointer (STKP) and write the content of program counter (PC) to the stack buffer are CALL instruction and interrupt service. Under each condition, the STKP decreases and points to the next available stack location.
  • Page 38: Reset

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller RESET 3.1 OVERVIEW The system would be reset in three conditions as following. Power on reset Watchdog reset Brown out reset External reset (only supports external reset pin enable situation) When any reset condition occurs, all system registers keep initial status, program stops and program counter is cleared. After reset status released, the system boots up and program starts to execute from ORG 0.
  • Page 39 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Finishing any reset sequence needs some time. The system provides complete procedures to make the power on reset successful. For different oscillator types, the reset time is different. That causes the VDD rise rate and start-up time of different oscillator is not fixed.
  • Page 40: Power On Reset

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.2 POWER ON RESET The power on reset depend no LVD operation for most power-up situations. The power supplying to system is a rising curve and needs some time to achieve the normal voltage. Power on reset sequence is as following. Power-up: System detects the power voltage up and waits for power stable.
  • Page 41: Brown Out Reset

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.4 BROWN OUT RESET 3.4.1 BROWN OUT DESCRIPTION The brown out reset is a power dropping condition. The power drops from normal voltage to low voltage by external factors (e.g. EFT interference or external loading changed). The brown out reset would make the system not work well or executing program error.
  • Page 42: The System Operating Voltage Decsription

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.4.2 THE SYSTEM OPERATING VOLTAGE DECSRIPTION To improve the brown out reset needs to know the system minimum operating voltage which is depend on the system executing rate and power level. Different system executing rates have different system minimum operating voltage. The electrical characteristic section shows the system voltage to executing rate relationship.
  • Page 43: Brown Out Reset Improvement

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.4.3 BROWN OUT RESET IMPROVEMENT How to improve the brown reset condition? There are some methods to improve brown out reset as following. LVD reset Watchdog reset Reduce the system executing rate External reset circuit. (Zener diode reset circuit, Voltage bias reset circuit, External reset IC) Note: The “...
  • Page 44: External Reset

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.5 EXTERNAL RESET External reset function is controlled by “Reset_Pin” code option. Set the code option as “Reset” option to enable external reset function. External reset pin is Schmitt Trigger structure and low level active. The system is running when reset pin is high level voltage input.
  • Page 45: Diode & Rc Reset Circuit

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.6.2 Diode & RC Reset Circuit DIODE 47K ohm 100 ohm 0.1uF This is the better reset circuit. The R1 and C1 circuit operation is like the simply reset circuit to make a power on signal. The reset circuit has a simply protection against unusual power.
  • Page 46: Voltage Bias Reset Circuit

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 3.6.4 Voltage Bias Reset Circuit 47K ohm 10K ohm 2K ohm The voltage bias reset circuit is a low cost voltage detector and can improve brown out reset condition completely. The operating voltage is not accurate as zener diode reset circuit. Use R1, R2 bias voltage to be the active level. When VDD voltage level is above or equal to “0.7V x (R1 + R2) / R1”, the C terminal of the PNP transistor outputs high voltage and MCU operates normally.
  • Page 47: System Clock

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller SYSTEM CLOCK 4.1 OVERVIEW The micro-controller is a dual clock system. There are high-speed clock and low-speed clock. The high-speed clock is generated from the external oscillator & on-chip PLL circuit. The low-speed clock is generated from on-chip low-speed RC oscillator circuit (ILRC 24 KHz).
  • Page 48: Oscm Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 4.3 OSCM REGISTER The OSCM register is an oscillator control register. It controls oscillator status, system mode. 0CAH Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 CPUM1 CPUM0 CLKMD...
  • Page 49: System High Clock

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 4.4 SYSTEM HIGH CLOCK The system high clock is from internal 6MHz oscillator. 4.4.1 INTERNAL HIGH RC The chip is built-in RC type internal high clock (6MHz). The system clock is from internal 6MHz RC type oscillator. IHRC: High clock is internal 6MHz oscillator RC type.
  • Page 50: System Clock Measurement

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 4.5.1 SYSTEM CLOCK MEASUREMENT Under design period, the users can measure system clock speed by software instruction cycle (Fcpu). This way is useful in RC mode. Example: Fcpu instruction cycle of external oscillator. B0BSET P0M.0 ;...
  • Page 51: System Operation Mode

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller SYSTEM OPERATION MODE 5.1 OVERVIEW The chip is featured with low power consumption by switching around four different modes as following. High-speed mode Low-speed mode Power-down mode (Sleep mode) Green mode Power Down Mode (Sleep Mode) P0, P1 Wake-up Function Active.
  • Page 52: System Mode Switching Example

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 5.2 SYSTEM MODE SWITCHING EXAMPLE Example: Switch normal/slow mode to power down (sleep) mode. B0BSET FCPUM0 ; Set CPUM0 = 1. Note: During the sleep, only the wakeup pin and reset can wakeup the system back to the normal mode. Example: Switch normal mode to slow mode.
  • Page 53 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: Switch normal/slow mode to green mode and enable T0 wake-up function. ; Set T0 timer wakeup function. B0BCLR FT0IEN ; To disable T0 interrupt service B0BCLR FT0ENB ; To disable T0 timer A,#20H B0MOV T0M,A...
  • Page 54: Wakeup

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 5.3 WAKEUP 5.3.1 OVERVIEW Under power down mode (sleep mode) or green mode, program doesn’t execute. The wakeup trigger can wake the system up to normal mode or slow mode. The wakeup trigger sources are external trigger (P0, P1 level change), internal trigger (T0 timer overflow) and USB bus toggle.
  • Page 55: Interrupt

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller INTERRUPT 6.1 OVERVIEW This MCU provides 7 interrupt sources, including 4 internal interrupt (T0/TC0/USB/SIO) and two external interrupt (INT0/INT1). The external interrupt can wakeup the chip while the system is switched from power down mode to high-speed normal mode.
  • Page 56: Inten Interrupt Enable Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.2 INTEN INTERRUPT ENABLE REGISTER INTEN is the interrupt request control register including one internal interrupts, one external interrupts enable control bits. One of the register to be set “1” is to enable the interrupt request function. Once of the interrupt occur, the stack is incremented and program jump to ORG 8 to execute interrupt service routines.
  • Page 57: Gie Global Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Bit 1 P01IRQ: External P0.1 interrupt (INT1) request flag. 0 = None INT0 interrupt request. 1 = INT0 interrupt request. Bit 2 WAKEIRQ: I/O PORT0 & PORT1 WAKEUP interrupt request flag. 0 = None WAKEUP interrupt request. 1 = WAKEUP interrupt request.
  • Page 58 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: Store ACC and PAFLG data by PUSH, POP instructions when interrupt service routine executed. START INT_SERVICE START: … INT_SERVICE: PUSH ; Save ACC and PFLAG to buffers. … … ; Load ACC and PFLAG from buffers. RETI ;...
  • Page 59: Int0 (P0.0) & Int1 (P0.1) Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.6 INT0 (P0.0) & INT1 (P0.1) INTERRUPT OPERATION When the INT0/INT1 trigger occurs, the P00IRQ/P01IRQ will be set to “1” no matter the P00IEN/P01IEN is enable or disable. If the P00IEN/P01IEN = 1 and the trigger event P00IRQ/P01IRQ is also set to be “1”. As the result, the system will execute the interrupt vector (ORG 8).
  • Page 60 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: INT0 interrupt service routine. ; Interrupt vector INT_SERVICE INT_SERVICE: … ; Push routine to save ACC and PFLAG to buffers. B0BTS1 FP00IRQ ; Check P00IRQ EXIT_INT ; P00IRQ = 0, exit interrupt vector B0BCLR FP00IRQ ;...
  • Page 61: T0 Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.7 T0 INTERRUPT OPERATION When the T0C counter occurs overflow, the T0IRQ will be set to “1” however the T0IEN is enable or disable. If the T0IEN = 1, the trigger event will make the T0IRQ to be “1” and the system enter interrupt vector. If the T0IEN = 0, the trigger event will make the T0IRQ to be “1”...
  • Page 62: Tc0 Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.8 TC0 INTERRUPT OPERATION When the TC0C counter overflows, the TC0IRQ will be set to “1” no matter the TC0IEN is enable or disable. If the TC0IEN and the trigger event TC0IRQ is set to be “1”. As the result, the system will execute the interrupt vector. If the TC0IEN = 0, the trigger event TC0IRQ is still set to be “1”.
  • Page 63: Usb Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.9 USB INTERRUPT OPERATION When the USB process finished, the USBIRQ will be set to “1” no matter the USBIEN is enable or disable. If the USBIEN and the trigger event USBIRQ is set to be “1”. As the result, the system will execute the interrupt vector. If the USBIEN = 0, the trigger event USBIRQ is still set to be “1”.
  • Page 64: Wakeup Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.10 WAKEUP INTERRUPT OPERATION When the I/O port 1 or I/O port 0 wakeup the MCU from the sleep mode, the WAKEIRQ will be set to “1” no matter the WAKEIEN is enable or disable. If the WAKEIEN and the trigger event WAKEIRQ is set to be “1”. As the result, the system will execute the interrupt vector.
  • Page 65: Sio Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.11 SIO INTERRUPT OPERATION When the SIO converting successfully, the SIOIRQ will be set to “1” no matter the SIOIEN is enable or disable. If the SIOIEN and the trigger event SIOIRQ is set to be “1”. As the result, the system will execute the interrupt vector. If the SIOIEN = 0, the trigger event SIOIRQ is still set to be “1”.
  • Page 66: Multi-Interrupt Operation

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 6.12 MULTI-INTERRUPT OPERATION Under certain condition, the software designer uses more than one interrupt requests. Processing multi-interrupt request requires setting the priority of the interrupt requests. The IRQ flags of interrupts are controlled by the interrupt event.
  • Page 67: I/O Port

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller I/O PORT 7.1 I/O PORT MODE The port direction is programmed by PnM register. All I/O ports can select input or output direction. 0B8H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0...
  • Page 68: I/O Pull Up Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 7.2 I/O PULL UP REGISTER 0E0H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 P02R P01R P00R P0UR Read/Write After reset 0E1H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3...
  • Page 69: I/O Port Data Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 7.3 I/O PORT DATA REGISTER 0D0H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Read/Write After reset 0D1H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1...
  • Page 70: I/O Port1 Wakeup Control Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 7.4 I/O PORT1 WAKEUP CONTROL REGISTER 0C0H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 P16W P15W P14W P13W P12W P11W P10W Read/Write After reset Bit [7:0] P1nW: Port 1 wakeup function control bit.
  • Page 71: Timers

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller TIMERS 8.1 WATCHDOG TIMER The watchdog timer (WDT) is a binary up counter designed for monitoring program execution. If the program goes into the unknown status by noise interference, WDT overflow signal raises and resets MCU. Watchdog clock controlled by code option and the clock source is internal low-speed oscillator (24KHz).
  • Page 72 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Watchdog timer application note is as following. Before clearing watchdog timer, check I/O status and check RAM contents can improve system error. Don’t clear watchdog timer in interrupt vector and interrupt service routine. That can improve main routine fail. Clearing watchdog timer program is only at one part of the program.
  • Page 73: Timer 0 (T0)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.2 TIMER 0 (T0) 8.2.1 OVERVIEW The T0 is an 8-bit binary up timer and event counter. If T0 timer occurs an overflow (from FFH to 00H), it will continue counting and issue a time-out signal to trigger T0 interrupt to request interrupt service. The main purpose of the T0 timer is as following.
  • Page 74: T0C Counting Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.2.3 T0C COUNTING REGISTER T0C is an 8-bit counter register for T0 interval time control. 0D9H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 T0C7 T0C6 T0C5 T0C4...
  • Page 75: T0 Timer Operation Sequence

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.2.4 T0 TIMER OPERATION SEQUENCE T0 timer operation sequence of setup T0 timer is as following. Stop T0 timer counting, disable T0 interrupt function and clear T0 interrupt request flag. B0BCLR FT0ENB ; T0 timer. B0BCLR FT0IEN ;...
  • Page 76: Timer/Counter 0 (Tc0)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3 TIMER/COUNTER 0 (TC0) 8.3.1 OVERVIEW The TC0 is an 8-bit binary up counting timer with double buffers. TC0 has two clock sources including internal clock and external clock for counting a precision time. The internal clock source is from Fcpu. The external clock is INT0 from P0.0 pin (Falling edge trigger).
  • Page 77: Tc0M Mode Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3.2 TC0M MODE REGISTER 088H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 TC0ENB TC0rate2 TC0rate1 TC0rate0 TC0CKS ALOAD0 TC0OUT PWM0OUT TC0M Read/Write After reset Bit 0 PWM0OUT: PWM output control bit.
  • Page 78: Tc0C Counting Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3.3 TC0C COUNTING REGISTER TC0C is an 8-bit counter register for TC0 interval time control. 089H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 TC0C7 TC0C6 TC0C5 TC0C4...
  • Page 79: Tc0R Auto-Load Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3.4 TC0R AUTO-LOAD REGISTER TC0 timer is with auto-load function controlled by ALOAD0 bit of TC0M. When TC0C overflow occurring, TC0R value will load to TC0C by system. It is easy to generate an accurate time, and users don’t reset TC0C during interrupt service routine.
  • Page 80: Tc0 Clock Frequency Output (Buzzer)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3.5 TC0 CLOCK FREQUENCY OUTPUT (BUZZER) Buzzer output (TC0OUT) is from TC0 timer/counter frequency output function. By setting the TC0 clock frequency, the clock signal is output to P5.3 and the P5.3 general purpose I/O function is auto-disable. The TC0OUT frequency is divided by 2 from TC0 interval time.
  • Page 81: Tc0 Timer Operation Sequence

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.3.6 TC0 TIMER OPERATION SEQUENCE TC0 timer operation includes timer interrupt, event counter, TC0OUT and PWM. The sequence of setup TC0 timer is as following. Stop TC0 timer counting, disable TC0 interrupt function and clear TC0 interrupt request flag. B0BCLR FTC0ENB ;...
  • Page 82: Pwm0 Mode

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.4 PWM0 MODE 8.4.1 OVERVIEW PWM function is generated by TC0 timer counter and output the PWM signal to PWM0OUT pin (P5.3). The 8-bit counter counts modulus 256, 64, 32, 16 controlled by ALOAD0, TC0OUT bits. The value of the 8-bit counter (TC0C) is compared to the contents of the reference register (TC0R).
  • Page 83: Tcxirq And Pwm Duty

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.4.2 TCxIRQ and PWM Duty In PWM mode, the frequency of TC0IRQ is depended on PWM duty range. From following diagram, the TC0IRQ frequency is related with PWM duty. TC0 Overflow, TC0IRQ = 1 0xFF TC0C Value 0x00...
  • Page 84: Pwm Duty With Tcxr Changing

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.4.3 PWM Duty with TCxR Changing In PWM mode, the system will compare TC0C and TC0R all the time. When TC0C<TC0R, the PWM will output logic “High”, when TC0C≧ TC0R, the PWM will output logic “Low”. If TC0C is changed in certain period, the PWM duty will change in next PWM period.
  • Page 85: Pwm Program Example

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 8.4.4 PWM PROGRAM EXAMPLE Example: Setup PWM0 output from TC0 to PWM0OUT (P5.3). The clock source is internal 6MHz. Fcpu = Fosc/1. The duty of PWM is 30/256. The PWM frequency is about 6KHz. The PWM clock source is from external oscillator clock.
  • Page 86: Universal Serial Bus (Usb)

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller UNIVERSAL SERIAL BUS (USB) 9.1 OVERVIEW The USB is the answer to connectivity for the PC architecture. A fast, bi-directional interrupt pipe, low-cost, dynamically attachable serial interface is consistent with the requirements of the PC platform of today and tomorrow. The SONIX USB microcontrollers are optimized for human-interface computer peripherals such as a mouse, joystick, game pad.
  • Page 87: Usb Interrupt

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 9.3 USB INTERRUPT The USB function will accept the USB host command and generate the relative interrupts, and the program counter will go to 0x08 vector. Firmware is required to check the USB status bit to realize what request comes from the USB host. The USB function interrupt is generated when: ‧...
  • Page 88: Usb Registers

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 9.5 USB REGISTERS 9.5.1 USB DEVICE ADDRESS REGISTER The USB Device Address Register (UDA) contains a 7-bit USB device address and one bit to enable the USB function. This register is cleared during a reset, setting the USB device address to zero and disable the USB function. 090H Bit 7 Bit 6...
  • Page 89: Usb Data Count Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 0 = Non-suspend status. When MCU wakeup from sleep mode by USB resume wakeup request, the bit will changes from 1 to 0 automatically. 1 = Set to 1 by hardware when USB suspend request. Bit 4 BUS_RST: USB bus reset.
  • Page 90: Usb Endpoint's Ack Handshaking Flag Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 9.5.5 USB endpoint’s ACK handshaking flag REGISTER The status of endpoint’s ACK transaction. 094H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 EP2_ACK EP1_ACK EP_ACK Read/Write After reset Bit [1:0]...
  • Page 91: Usb Endpoint 1 Enable Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Table, The USB SIE will send NAK handshakes in response to any IN/OUT token set to the endpoint 0.The bit 5 UE0M0 will auto reset to zero when the ACK transaction complete. USB endpoint 0’s mode table UE0M1 UE0M0 IN/OUT Token Handshake...
  • Page 92: Usb Endpoint 2 Enable Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 0 = disable USB endpoint 1 function. 1 = enable USB endpoint 1 function. 9.5.9 USB ENDPOINT 2 ENABLE REGISTER The communication with the USB host using endpoint 2, endpoint 2’s FIFO is implemented as 16 bytes of dedicated RAM.
  • Page 93: Usb Data Read/Write Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 0A3H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 UDP0 UDP07 UDP06 UDP05 UDP04 UDP03 UDP02 UDP01 UDP00 Read/Write After reset Address [07]~address [00]: data buffer for endpoint 0. Address [17]~address [10]: data buffer for endpoint 1.
  • Page 94: Upid Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller EP2OUT_CNT UEP2OC3 UEP2OC2 UEP2OC1 UEP2OC0 Read/Write After reset Bit [4:0] UEP2Cn: Bytes counter of EP2 token data. Reset by firmware. 9.5.13 UPID REGISTER Forcing bits allow firmware to directly drive the D+ and D– pins. 0ABH Bit 7 Bit 6...
  • Page 95 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 0 = Clear the endpoint 1~2’s toggle bit to DATA0. 1 = hardware set toggle bit automatically. 9.5.15 ENDPOINT CONTROL REGISTER 0B0H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 IHRCU...
  • Page 96: Serial Input/Output Transceiver

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller SERIAL INPUT/OUTPUT TRANSCEIVER 10.1 OVERVIEW The SIO (serial input/output) transceiver allows high-speed synchronous data transfer between the SN8F2270B series MCU and peripheral devices or between several SN8F2270B devices. These peripheral devices may be Serial EEPROMs, shift registers, display drivers, etc.
  • Page 97 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller The system is single-buffered in the transmit direction and double-buffered in the receive direction. This means that bytes to be transmitted cannot be written to the SIOB Data Register before the entire shift cycle is completed. When receiving data, however, a received byte must be read from the SIOB Data Register before the next byte has been completely shifted in.
  • Page 98 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller The SIO data transfer timing as following figure: Idle Diagrams Status High High High High SIO Data Transfer Timing Version 1.3 SONiX TECHNOLOGY CO., LTD Page 98...
  • Page 99: Siom Mode Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 10.2 SI M M ODE REGISTER 0B4H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 SENB START SRATE1 SRATE0 MLSB SCKMD CPOL CPHA SIOM Read/Write After reset Bit 7 SENB: SIO function control bit.
  • Page 100: Siob Data Buffer

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 10.3 SIOB DATA BUFFER 0B6H Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 SIOB7 SIOB6 SIOB5 SIOB4 SIOB3 SIOB2 SIOB1 SIOB0 SIOB Read/Write After reset SIOB is the SIO data buffer register.
  • Page 101 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Example: Master, duplex transfer and transmit data on rising edge A,TXDATA ; Load transmitted data into SIOB register. B0MOV SIOB,A 0FEH Set S IO cloc B0MOV SIOR 100000 ; Setup SIOM and enable SIO function. B0MOV IOM,A B0BSET...
  • Page 102: Flash

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Flash 1.1 OVE RVIE The SN8F2 B series USB MC U integrated device feature in-system programmable (ISP) FLASH memory or convenient, upgra deable cod e storage. T he FLAS memory may be programmed via the SONiX 8 bit CU programm ing inte rface or...
  • Page 103: Flash Programming/Erase Control Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 11.2 FLA SH PROGRAMMING/ERASE CONTROL REGISTER 0BAH Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 PECMD7 PECMD6 PECMD5 PECMD4 PECMD3 PECMD2 PECMD1 PECMD0 PECMD Read/Write After reset Bit [7:0] PECMD[7:0]: 0x5A: Page Program (32 words/page), 0xC3: Page Erase (128 words/page)
  • Page 104 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 5Kx16 FLASH User reset vector 0000H Reset vector Jump to user start address 0001H Genera 0007H 0008H Interrupt vector User interrupt vector 0009H User program 000FH 0010H 0011H General purpose area 1380H 13FBH End of user program SECURITY0 protect &...
  • Page 105: Programming/Erase Data Register

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 11.4 PROGRAMMING/ERASE DATA REGISTER 0BDH Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 PERAML7 ERAML6 PE RAML5 PERAML4 PE RAML3 PERAML2 PERAML1 PERAML0 PERAML Read/Write After reset 0BEH Bit 7...
  • Page 106: Instruction Table

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller INSTRUCTION TABLE Field Mnemon escription Cycle A ← √ ← A A ← M (bank 0) √ B0MOV M (bank 0) ← A B0MOV A ← I M ← I, “M” only supports 0x80~0x87 registers (e.g. PFLAG,R,Y,Z…) B0MOV A ←→...
  • Page 107: Development Tool

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller DEVELOPMENT TOOL X pr ovides ICE (in circuit emulation), IDE (Integ rated Devel opment Environment), EV-kit and r fi mw re brary f B applica tion devel opmen t. ICE and EV-kit are external hardware device and IDE is a friend ly se nterface rmw re dev elop...
  • Page 108: Sn8F2270B Ev- Kit

    VREG 3.3V power supply. The outline of SN8F2270B EV-kit is as following. CON2 : ICE Interface: Interface connected to SN8ICE2K_FSUSB_V2.1 J2: Jumper to connect between the 5V VDD from SN8ICE2K Plus and VDD_IC on SN8F2271B/ 721B package form socket. J1: USB Mini-B connector.
  • Page 109: Sn8F2270B Transition Board

    USB 2.0 Low-Speed 8-Bit Micro-Controller 13.3 SN8F2270B Transition Board SN8F2270B Transition Boards includes total 2 models. The following shows the transition board outline for SN8F2271B and SN8F22721B. Among the board , both C1 and C2 MUST be welded by 1uF capacitor. Version 1.3 SONiX TECHNOLOGY CO., LTD...
  • Page 110: Electrical Characteristic

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller ELECTRICAL CHARACTERISTIC 14.1 ABSOLUTE MAXIMUM RATING Supply voltage (Vdd)…………………………………………………………………………………………………………………….……………… - 0.3V ~ 6.0V Input in voltage (Vin)…………………………………………………………………………………………………………………….… Vss – 0.2V ~ Vdd + 0.2V Operating ambient temperature (Topr) SN8F22711BS, SN8F2271BJ, SN8F22721BS, SN8F22721BX, SN8F22721BP …………………..……………. ………………… 0°C ~ + 70°C Storage ambient temperature (Tstor) ………………………………………………………………….…………………………………………...
  • Page 111 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller IVREG ≦ 25 mA with 10uF to GND normal Mode Idd1 (No loading, Vdd= 5V, 6Mhz Fcpu = Fosc/1) Slow Mode Idd2 Vdd= 5V, 24Khz (Internal low RC) Supply Current Idd3 Sleep Mode Vdd= 5V Green Mode (No loading,...
  • Page 112: Flash Rom Programming Pin

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Flash ROM PROGRAMMING PIN Programming Informatio n of SN8F2270B Series Chip Name SN8F2271BJ SN8F22721BS/X/P SN8F22711BS EZ Writer / MP Writer Flash IC / JP3 Pin Assigment Connector Numbe Numbe Name Num er Number Number P1.2 P1.2...
  • Page 113: Package Information

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller PACKAGE INFORMATION 16.1 SOP 1 SYMBOLS (inch) (mm) 0.058 0.064 0.068 1.4732 1.6256 1.7272 0.004 0.010 0.1016 0.254 0.013 0.016 0.020 0.3302 0.4064 0.508 0.0075 0.008 0.0098 0.1905 0.2032 0.2490 0.336 0.341 0.344 8.5344 8.6614 8.7376...
  • Page 114: Sop 20 Pin

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 16.2 SOP 20 PIN SYMBOLS (inch) (mm) 0.093 0.099 0.104 2.362 2.502 2.642 0.004 0.008 0.012 0.102 0.203 0.305 0.496 0.502 0.508 12.598 12.751 12.903 0.291 0.295 0.299 7.391 7.493 7.595 0.394 0.407 0.419 10.008 10.325...
  • Page 115: Ssop 20 Pin

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 16.3 SSOP 20 PIN SYMBOLS (inch) (mm) 0.053 0.063 0.069 1.350 1.600 1.750 0.004 0.006 0.010 0.100 0.150 0.250 0.059 1.500 0.008 0.010 0.012 0.200 0.254 0.300 0.007 0.008 0.010 0.180 0.203 0.250 0.337 0.341 0.344...
  • Page 116: P-Dip 20 Pin

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 16.4 P-DIP 20 PIN SYMBOLS (inch) (mm) 0.210 5.334 0.015 0.381 0.125 0.130 0.135 3.175 3.302 3.429 0.980 1.030 1.060 24.892 26.162 26.924 0.300 7.620 0.245 0.250 0.255 6.223 6.350 6.477 0.115 0.130 0.150 2.921 3.302...
  • Page 117: Qfn 16 Pin

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 16.5 QFN 16 PIN Version 1.3 SONiX TECHNOLOGY CO., LTD Page 117...
  • Page 118: Marking Definition

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller Marking Definition 17.1 INTRODUCTION There are many different types in Sonix 8-bit MCU production line. This note listed the production definition of all 8-bit MCU for order or obtain information. 17.2 MARKING INDETIFICATION SYSTEM SN8 X Part No.
  • Page 119: Marking Example

    SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller 17.3 MARKING EXAMPLE Name ROM Type Device Package Temperature Material SN8F22721BPB Flash memory 22721B SK-DIP 0 ~70 PB-Free Package ℃ ℃ SN8F22721BSB Flash memory 22721B 0 ~70 PB-Free Package ℃ ℃ SN8F22721BXB Flash memory 22721B SSOP 0 ~70...
  • Page 120 SN8F2270B Series USB 2.0 Low-Speed 8-Bit Micro-Controller SONIX reserves the right to make change without further notice to any products herein to improve reliability, function or design. SONIX does not assume any liability arising out of the application or use of any product or circuit described herein; neither does it convey any license under its patent rights nor the rights of others.

This manual is also suitable for:

Sn8f22711bSn8f22721b

Table of Contents