Page 1
S6E1C1/C3 Series 32-Bit Microcontroller FM0+ Family FLASH PROGRAMMING MANUAL For the information for microcontroller supports, see the following web site. http://www.spansion.com/support/microcontrollers/ Publication Number S6E1Cx_MN710-00016-1v0-E Revision 1.0 Issue Date August 31, 2015 CONFIDENTIAL...
Page 2
P E R I P H E R A L M A N U A L S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
Page 3
Note that the sample programs are subject to change without notice. Since they are offered as a way to demonstrate standard operations and usage, evaluate them sufficiently before running them on your system. Cypress assumes no responsibility for any damage that may occur as a result of using a sample program. August 31, 2015, S6E1Cx_MN710-00016-1v0-E...
Page 4
P E R I P H E R A L M A N U A L How to Use This Manual Searching for a function The following methods can be used to search for the explanation of a desired function in this manual: ...
Page 5
P E R I P H E R A L M A N U A L Table 1 Applicable Products (FM0+ TYPE3-M0+ product list) Flash memory size Type name* 64Kbyte 128Kbyte S6E1C11B0A S6E1C12B0A S6E1C11C0A S6E1C12C0A S6E1C11D0A S6E1C12D0A TYPE3-M0+ S6E1C31B0A S6E1C32B0A S6E1C31C0A S6E1C32C0A S6E1C31D0A...
P E R I P H E R A L M A N U A L Table of Contents CHAPTER1: Flash Memory ........................... 7 Overview ............................8 Configuration ..........................9 Operations ............................ 13 Automatic Algorithm ......................14 3.1.1 Command Sequences ..................15 3.1.2 Command Operations ..................
CHAPTER1: Flash Memory This chapter explains the overview, configuration, operation, and registers of the Flash memory. This series is equipped with the Flash Memory of up to 128Kbyte for which Flash erase (simultaneous data erase of all sectors), data erase of each sector, and data write with CPU can be implemented. 1.
CHAPTER1: Flash Memory P E R I P H E R A L M A N U A L 1. Overview This series is equipped with up to 128Kbyte Flash Memory. The built-in Flash Memory could erase data by-sector, or erase flash (erase data by-all-sector collectively), and write programmed data by byte (8 bits) or by half-word (16 bits) with the Cortex-M0+ CPU.
CHAPTER1: Flash Memory 2. Configuration P E R I P H E R A L M A N U A L 2. Configuration This series has maximum 128Kbyte of Flash memory area including a security code area, and a CR trimming data area.
Page 10
CHAPTER1: Flash Memory 2. Configuration P E R I P H E R A L M A N U A L Figure 2-1 Address and Sector Structure of 64Kbyte Flash Memory S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
Page 11
CHAPTER1: Flash Memory 2. Configuration P E R I P H E R A L M A N U A L Figure 2-2 Address and Sector Structure of 128Kbyte Flash Memory Figure 2-3 Address of Security/CR Trimming Data August 31, 2015, S6E1Cx_MN710-00016-1v0-E CONFIDENTIAL...
Page 12
CHAPTER1: Flash Memory 2. Configuration P E R I P H E R A L M A N U A L Figure 2-4 Bit Configuration of CR Trimming Area S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3. Operations This section explains the Flash memory operation. 3.1 Automatic Algorithm 3.2 Flash Memory Operation 3.3 Cautions When Using Flash Memory August 31, 2015, S6E1Cx_MN710-00016-1v0-E CONFIDENTIAL...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Automatic Algorithm Writing to and erasing Flash memory is performed by activating the automatic algorithm. This section explains the automatic algorithm. 3.1.1 Command Sequences 3.1.2 Command Operations 3.1.3 Automatic Algorithm Run States...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.1.1 Command Sequences The automatic algorithm is activated by writing data to the Flash memory in the specified method. This is called a command.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.1.2 Command Operations This section explains the command operations. To execute the command operation program, store the program in RAM. Read/Reset Command The flash memory can be read and reset by sending the read/reset command.
Page 17
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Sector Erase Suspended Command By issuing the sector erase suspended command during sector erase, sector erase can be suspended. In the sector erase suspended state, the read and write operations of memory cells of the sector not to erase is possible.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.1.3 Automatic Algorithm Run States Writing and erasing of flash memory is performed by the automatic algorithm. Whether or not the automatic algorithm is currently executing can be checked by using the Flash Status Register (FSTR).
Page 19
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Bit descriptions [bit7:6] Reserved bits [bit5] PGMS: Program Write Operation Status flag bit After issuing the Program Write Operation command, RDY bit becomes "0" and this bit is set to "1". This bit of "1"...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Flash Memory Operation The operation of the Flash memory is explained for each command. 3.2.1 Read/Reset Operation 3.2.2 Write Operation 3.2.3 Flash Erase Operation 3.2.4 Sector Erase Operation 3.2.5 Sector Erase Suspended Operation...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.1 Read/Reset Operation This section explains the read/reset operation. To place the flash memory in the read/reset state, send read/reset commands to an arbitrary address within the address range of the flash memory.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.2 Write Operation This section explains the write operation. Writes are performed according to the following procedure. The program (write) command is issued sequentially. The automatic algorithm activates and the data is written to the flash memory.
Page 23
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Notes: − See Section "3.1 Automatic Algorithm" for details on the write command. − Because the value of the flash memory might not read correctly immediately after the command issued, ignore the first read value of Flash Status Register (FSTR) after the command issued.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.3 Flash Erase Operation This section explains the flash erase operation. All sectors in flash memory can be erased in one batch. Erasing all of the sectors in one batch is called flash erase.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.4 Sector Erase Operation This section explains the sector erase operation. Sectors in the flash memory can be selected and the data of only the selected sectors can be erased. Multiple sectors can be specified at the same time.
Page 26
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Figure 3-3 Example of Sector Erase Procedure Start of sector erase Sector erase command sequence 1.Addr:0000_0A98 Data:00AA 2.Addr:0000_0544 Data:0055 3.Addr:0000_0A98 Data:0080 4.Addr:0000_0A98...
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.5 Sector Erase Suspended Operation This section explains the sector erase suspended operation. When the sector erase suspended command is sent during sector erase, the flash memory makes a transition to the sector erase suspended state and temporarily suspends the erase operation.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L 3.2.6 Sector Erase Restart Operation This section explains the operation for restarting sector erase during sector erase suspended. When the sector erase restart command is issued to any address of even number in the address range of the flash memory while sector erase is suspended, sector erase can be restarted.
CHAPTER1: Flash Memory 3. Operations P E R I P H E R A L M A N U A L Cautions When Using Flash Memory This section explains the cautions when using the Flash memory. − If this device is reset during the write, the data that is written cannot be guaranteed. Moreover, It is necessary to prevent an unexpected reset like Watchdog Timer from occurring during the writing and erasing.
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L 4. Registers This section describes the registers of the flash memory. List of Registers of Flash Memory Table 4-1 List of Registers of Flash Memory Abbreviation Register Name Reference...
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Read Wait Register (FRWTR) The Flash Read Wait Register (FRWTR) specifies the wait cycle for the flash memory. Register Configuration Field Reserved...
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Status Register (FSTR) The Flash Status Register (FSTR) is a status register of the flash memory. Register Configurations Field Reserved PGMS...
Page 33
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L [bit1] HNG: Flash Hang Status Indicates whether the flash memory is in the HANG state. The flash memory enters the HANG state if the timing is exceeded.
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Interrupt Control Register (FICR) The Flash Interrupt Control Register (FICR) specifies the interrupt enable setting of the flash memory. Register Configuration Field Reserved...
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Interrupt Status Register (FISR) The Flash Interrupt Status Register (FISR) indicates the interrupt status of the FLASH memory. Register Configuration Field Reserved...
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Interrupt Clear Register (FICLR) The Flash Interrupt Clear Register (FICLR) clears the interrupt flag of flash memory. Register Configuration Field Reserved HANGC...
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L CR Trimming Data Mirror Register (CRTRMM) The CR Trimming Data Mirror Register (CRTRMM) is the mirror register of the CR trimming data. A value of this register can be used in the user mode and the serial writer mode.
CHAPTER1: Flash Memory 4. Registers P E R I P H E R A L M A N U A L Flash Sync Down Register (FSYNDN) The wait cycle is inserted in the read access to the flash memory. Current consumption can be reduced by decreasing the access clock frequency of the flash memory.
CHAPTER2: Flash Security The flash security function protects contents of the flash memory. This chapter explains the overview and operations of the flash security. 1. Overview 2. Operation Explanation August 31, 2015, S6E1Cx_MN710-00016-1v0-E CONFIDENTIAL...
CHAPTER2: Flash Security 1. Overview P E R I P H E R A L M A N U A L 1. Overview This section explains the overview of the flash security. If the protection code of 0x0001 is written in the security code area of the flash memory, access to the flash memory is restricted.
CHAPTER2: Flash Security 2. Operation Explanation P E R I P H E R A L M A N U A L 2. Operation Explanation This section explains the operation of the flash security. Setting Security Write the protection code 0x0001 in address of the security code. The security is enabled and set after all the reset factors are generated or after turning on the power again.
Page 42
CHAPTER2: Flash Security 2. Operation Explanation P E R I P H E R A L M A N U A L S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
CHAPTER3: Serial Programming Connection This series supports serial onboard write (Cypress standard) to flash memory. This chapter explains the basic configuration for serial write to flash memory by using the Cypress Serial Programmer. 1. Serial Programmer August 31, 2015, S6E1Cx_MN710-00016-1v0-E...
M A N U A L 1. Serial Programmer Cypress Serial Programmer (software) is an onboard programming tool for all microcontrollers with built-in flash memory. Two types of Serial Programmer are available according to the PC interface (RS-232C or USB) used.
In these series, serial programming (UART communication mode) is possible by any clock, crystal oscillator or built-in High-speed CR oscillator. Figure 1-1 shows the basic configuration of Cypress MCU Programmer, and Table 1-1 lists the system configuration. Figure 1-1 Basic Configuration of Cypress MCU Programmer...
Page 46
When Crystal oscillator is used as the source oscillation clock Figure 1-2 shows a connection example of Cypress MCU Programmer when a crystal oscillator is used as a source oscillation clock and Table 1-2 available frequencies and communication baud rates.
Page 47
When built-in high-speed CR oscillator is used as a source oscillation clock Figure 1-3 shows a connection example of Cypress MCU Programmer when a built-in high-speed CR oscillator is used as a source oscillation clock. When neither crystal oscillator nor external clock is connected to X0/X1 pins, the built-in high-speed CR oscillator is connected for communication.
Page 48
PC and the user system are connected through a USB cable. Figure 1-4 shows the basic configuration of Cypress USB DIRECT Programmer, and Table 1-1 lists the system configuration. Figure 1-4 Basic Configuration of Cypress USB DIRECT Programmer...
Page 49
1. Serial Programmer P E R I P H E R A L M A N U A L Figure 1-5 Connection Example Using Cypress USB DIRECT Programmer (Own Power Supply is Used, for 64pin and 48pin Products) User system...
Page 50
1. Serial Programmer P E R I P H E R A L M A N U A L Figure 1-6 Connection Example Using Cypress USB DIRECT Programmer (Own Power Supply is Used, for 32pin and 26pin Products) User system...
Page 51
1. Serial Programmer P E R I P H E R A L M A N U A L Figure 1-7 Connection Example Using Cypress USB DIRECT Programmer (Bus Power Supply is Used, for 64pin and 48pin Products) User system ...
Page 52
1. Serial Programmer P E R I P H E R A L M A N U A L Figure 1-8 Connection Example Using Cypress USB DIRECT Programmer (Bus Power Supply is Used, for 32pin and 26pin Products) User system ...
CHAPTER3: Serial Programming Connection 1. Serial Programmer P E R I P H E R A L M A N U A L 1.2. Pins Used This section explains the used pins. Table 1-2 Pins Used for Serial Write Pins Function Supplement MD0, MD1...
Page 54
CHAPTER3: Serial Programming Connection 1. Serial Programmer P E R I P H E R A L M A N U A L S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
P E R I P H E R A L M A N U A L Major Changes Page Section Changes Revision 1.0 Initial release August 31, 2015, S6E1Cx_MN710-00016-1v0-E CONFIDENTIAL...
Page 56
P E R I P H E R A L M A N U A L S6E1Cx_MN710-00016-1v0-E, August 31, 2015 CONFIDENTIAL...
Page 57
P E R I P H E R A L M A N U A L MN710-00016-1v0-E Cypress・Controller Manual FM0+ Family 32-Bit Microcontroller FLASH PROGRAMMING MANUAL August 2015 Rev. 1.0 Published:Cypress Edited: Communications August 31, 2015, S6E1Cx_MN710-00016-1v0-E CONFIDENTIAL...
Page 58
Cypress assumes no liability for any damages of any kind arising out of the use of the information in this document.
Need help?
Do you have a question about the S6E1C1 Series and is the answer not in the manual?
Questions and answers