Omron C200HS Program Download: Preserving DM and HR Memory Areas
The Omron C200HS CPU distinguishes between the user program (ladder logic stored in the UM/Program Memory region) and the data memory regions (D, H, IR, SR, AR, LR, TC, EM). A program download through CX-Programmer targets the Program Memory area only and does not overwrite data memory values, provided the CPU retains its backup battery and the PLC is in the correct operating mode. This technical reference documents the exact behavior of each memory area during a program transfer, the proper backup procedure for the .mem file, DIP switch configuration for Memory Cassettes, and verification steps using CX-Programmer 7.2 / CX-One 4.x.
C200HS Memory Architecture Overview
The C200HS CPU organizes its address space into several discrete regions, each with its own retention characteristics and access rules. The official C200HS Operation Manual (W235-E1-05) defines the complete map and the boundaries between program and data storage. The regions relevant to a routine program download are summarized below.
| Region | Symbol Prefix | Word Range | Retention | Affected by Program Download? |
|---|---|---|---|---|
| Internal Relay / I/O | IR | IR000–IR235 (word) | Battery / non-retentive bits | No (bit values preserved) |
| Special Relay | SR | SR228–SR255 (word) | System controlled | No (recomputed by firmware) |
| Holding Relay | HR (referred to as "H" in CX-Programmer) | HR00–HR99 (word) | Battery-backed, retentive on power cycle | No |
| Auxiliary Relay | AR | AR00–AR27 (word) | Mixed; AR07 and AR09 are retentive | No (system-controlled) |
| Link Relay | LR | LR00–LR63 (word) | Battery-backed | No |
| Timer / Counter PV | TC | TC000–TC511 (PVs) | PV retentive on power cycle | No |
| Data Memory | DM (referred to as "D") | D0000–D6655 (word) | Battery-backed, retentive | No |
| Extended Data Memory | EM (with bank) | E0000–E9999 per bank | Battery-backed, retentive | No |
| User Program (UM) | — | Ladder area | FLASH/EPROM/RAM with battery | YES — replaced on download |
| Expansion Instruction Slots | — | Function block definitions | FLASH | Replaced if downloaded as program |
The C200HS CPU uses a memory architecture in which the ladder program occupies the UM (User Memory) region while data regions such as DM (D), HR (H), IR, LR, TC PV, and EM are mapped into a separate SRAM area protected by the lithium backup battery. Because of this physical separation, the standard CX-Programmer Transfer to PLC → Programs command writes only the UM region. The data regions remain untouched.
What CX-Programmer Actually Transfers on a Program Download
When CX-Programmer performs a Transfer to PLC operation with Programs selected, it sends the ladder diagram, expansion instructions, and task structure to the C200HS Program Memory area. The Host Link protocol (C-mode or FINS) handles this as a discrete write to the program area.
According to the operation manual, the program area is independent of the data memory area, and the host link command set includes dedicated function codes for each:
| C-mode Command | Function | Code (Hex) | Target Region |
|---|---|---|---|
| Program Read | RR / RG | 0x09 / 0x0C | UM (Program) |
| Program Write | WR / WG | 0x0B / 0x0D | UM (Program) |
| DM Read | RD | 0x02 | D0000–D6655 |
| DM Write | WD | 0x03 | D0000–D6655 |
| HR Read | RH | 0x32 | HR00–HR99 |
| HR Write | WH | 0x33 | HR00–HR99 |
| AR Read | RJ | 0x34 | AR00–AR27 |
| IR/SR/LR/TC Read | RC / RL / RG / RR | — | IR/SR/LR/TC PV |
| EM Read/Write | RE / WE | 0x50 / 0x51 | EM bank words |
Because each region uses a separate command code, the standard program transfer (WR/WG) cannot accidentally overwrite DM, HR, AR, LR, IR, or EM. The KEPServerEX driver documentation for the Omron Host Link driver confirms the same partitioning: C200H Addressing defines DM, HR, AR, IR, and LR as independent I/O tags that are read and written through dedicated channels, never bundled into the program memory image.
Memory Areas Surviving a Standard Program Download
For a typical CX-Programmer transfer to a powered C200HS with healthy battery voltage, the following data regions retain their values intact:
- DM (Data Memory, D0000–D6655) — All 6,656 words remain unchanged. CX-Programmer treats DM as a separate "memory component" and requires an explicit Transfer operation.
- HR (Holding Relay, H000–H9915 / HR00–HR99) — All 1,600 retentive bits retain state. The HR area is preserved across power cycles and across program downloads.
- AR (Auxiliary Relay) — System diagnostic flags retain their values; flags driven by firmware may refresh at next scan.
- LR (Link Relay) — All 1,024 link relay bits remain intact.
- TC PV (Timer/Counter Present Values) — Retentive timers and counters (designated by retention attribute in the program) keep their PV. Non-retentive timers reset to SV on the next scan cycle.
- EM (Extended Memory) — When present, EM banks retain contents unless the EM bank itself is being re-initialized by the new program.
- IR/SR — I/O bits refresh on next I/O refresh; special relays are recomputed by firmware.
Pre-Download Backup Procedure
Although a routine program download is non-destructive, the C200HS has several operations that do erase data, and any of these can be triggered accidentally from the CX-Programmer menu or by a Memory Cassette mount operation. Back up the program and all data areas as separate files before every download.
Prerequisites
- CX-Programmer 7.2 or later (the recommended upgrade path from version 3.0). CX-One 4.x or later bundles CX-Programmer with the Sysmac Studio back-compatibility components.
- C-series (C200HS) Host Link cable, USB-Serial adapter approved by Omron, or the later CP1W-CIF01 / CS1W-CN226 over Ethernet (with FINS gateway).
- CPU in PROGRAM mode if any HR/TC/LR/EM transfer is required. The D area can be transferred in RUN or MONITOR mode.
- A known-good lithium backup battery (CR14250SE or equivalent) with voltage ≥ 2.8 VDC. Low-battery detection (AR0804 = ON) must be clear before backup.
Step-by-Step Backup in CX-Programmer
- Connect CX-Programmer to the C200HS via Host Link (default settings: 9,600 baud, unit number 00, C-mode protocol).
- Place the PLC in PROGRAM mode using the mode switch on the CPU faceplate or via PLC → Operating Mode → Program in CX-Programmer.
- Right-click the PLC node and choose Transfer From PLC → Programs. Save the resulting file as
project_backup.cxp. - Open Memory Component from the project tree. This is the "Memory" view that displays D, H, W, A, T/C, and EM areas as discrete data tables.
- Open the D area tab. Select the full range (D0000–D6655). Right-click and choose Transfer From PLC → D. Save the file with extension
.mem(e.g.,D_area_backup.mem). - Open the H area tab. Select HR00–HR99. Right-click and choose Transfer From PLC → H. Save the H-area contents to a separate
.memfile. Note that transferring the H area requires the CPU to be in PROGRAM mode. - Repeat for the A (AR) area, W (LR) area, T/C PV area, and any EM banks present. Each region produces its own
.memfile. - Close all open transfers. Verify file sizes: a full D-area .mem file for the C200HS is approximately 16 KB (D0000–D6655 = 6,656 words × 2 bytes + CX-Programmer header). A full H-area .mem file is approximately 200 bytes (HR00–HR99 = 100 words).
- Archive the program file and all
.memfiles into a project-named folder. Label the folder with the date, CPU serial number, and program revision.
Performing the Program Download
With backups verified, the program transfer proceeds normally.
- Open the new project file in CX-Programmer 7.2 (or the version used to author the program).
- Confirm the target PLC type in the project properties: Device Type = C200HS and CPU model match (e.g., CPU21, CPU23, CPU31).
- Go online: PLC → Work Online (or Ctrl+W). Verify the connection reports the correct CPU model.
- Select PLC → Transfer → To PLC. The Transfer to PLC dialog appears with check boxes for Programs, Memory, Expansion Instructions, and I/O Comments.
- Select Programs only. Deselect Memory, Expansion Instructions (unless intentionally upgrading), and I/O Comments. Click OK.
- CX-Programmer prompts: "The CPU will be placed in PROGRAM mode. Continue?" Click Yes.
- The transfer writes the program memory. A progress bar shows the percentage completion. Typical transfer time for a 16 K-step C200HS program over 9,600 baud Host Link is 30–90 seconds.
- When transfer completes, the PLC remains in PROGRAM mode. Switch back to MONITOR or RUN using the mode switch to begin execution.
Restoring Data Memory After Download
If for any reason the D or H area values are cleared during the procedure (typically due to an explicit Memory Component transfer, a clear-all operation, or a battery-failure-induced reset), restore from the saved .mem files.
- Ensure CPU is in PROGRAM mode. The H area (and most AR/LR areas) require PROGRAM mode for write access via Host Link.
- Open the Memory Component view and select the D area tab.
- Right-click and choose Transfer To PLC → D. Navigate to
D_area_backup.memand confirm. - Repeat for the H area: Transfer To PLC → H with
H_area_backup.mem. - Repeat for A, W, T/C, and EM banks as needed.
- Verify each restored area by spot-checking values against the original archive.
- Switch to MONITOR/RUN mode.
DIP Switch and Memory Cassette Considerations
When the program is stored on an EPROM Memory Cassette (e.g., C200HS-ME16K), the DIP switch on the CPU faceplate controls whether the cassette is read-only or read/write, and whether the program is loaded from the cassette to internal RAM at power-up.
| Pin 1 (PROTECT) | Pin 2 (AUTO-LOAD) | Behavior |
|---|---|---|
| OFF | OFF | Cassette write-protected, no auto-load |
| OFF | ON | Cassette write-protected, auto-load at power-up |
| ON | OFF | Cassette writable, no auto-load |
| ON | ON | Cassette writable, auto-load at power-up |
If the new program is stored on a Memory Cassette, mount the cassette on the CPU, set the DIP switches appropriately, and power-cycle to load the new program. The auto-load operation writes the program area only — DM, HR, and EM values in internal SRAM remain intact as long as the battery holds voltage during the power cycle.
CX-Programmer Version Compatibility
CX-Programmer 3.0 (released with the original C-series support package) communicates correctly with the C200HS using the standard C-mode Host Link protocol, but lacks support for later C200HS firmware features, the FINS communications protocol, and the structured text editor improvements. The recommended upgrade is CX-Programmer 7.2 (the last version with full C200HS support as a primary target) bundled within CX-One 4.x.
Newer CX-Programmer versions (9.x and later) maintain backward compatibility with C200HS project files, although some advanced features may be silently ignored when uploaded from the older PLC. The .cxp project file format has remained compatible across these versions for the C200HS device type.
Memory area file extension handling:
-
.cxp— full CX-Programmer project including ladder, I/O comments, and Memory Component data tables -
.mem— Memory Component transfer file (D, H, A, W, T/C, EM, or combined) -
.exp— Expansion Instructions file (function block libraries) -
.txtor.csv— human-readable export of Memory Component tables
Verification Procedure After Download
After the program download and any required data restore, validate the system before returning to production.
- Verify CPU mode is set to the intended operating state (RUN or MONITOR).
- Check error indicators: AR0800 (cycle time over), AR0801 (I/O verify error), AR0804 (battery error). All should be OFF.
- Read back a sample of D, H, A, and W areas using the Memory Component view. Confirm the values match the pre-download backup.
- Spot-check any retentive timers (TCxxx with retentive attribute): the PV should equal its pre-download value.
- Force a single scan in MONITOR mode by toggling the AR0900 step flag. Observe the program execution for any faults.
- Monitor the cycle time in SR237/SR238 (scan time high/low words). A significant change from baseline indicates the new program has different scan behavior.
- Verify I/O: scan IR000–IR015 input words and confirm field devices register correctly. Verify output words IR100–IR115 drive the expected loads.
Troubleshooting Matrix
| Symptom | Probable Cause | Resolution |
|---|---|---|
| D area cleared after program download | Memory Component transfer unintentionally included D area; or battery failed during download | Verify battery voltage (AR0804). Restore D from .mem backup in PROGRAM mode. |
| H area cleared after program download | PLC not in PROGRAM mode during H-area transfer | Place CPU in PROGRAM mode and re-transfer H area from .mem backup. |
| Communication timeout during transfer | Wrong baud rate, wrong unit number, or Host Link cable fault | Verify default Host Link settings (9,600, 7E2, unit 0). Test cable against known-good PLC. |
| Transfer rejected with "Memory Cassette Write Protected" | DIP switch pin 1 (PROTECT) is OFF on a write target cassette | Set pin 1 = ON to enable write, or remove cassette if the program should go to internal RAM only. |
| AR0804 battery error after power cycle | Battery below 2.8 VDC; SRAM contents lost | Replace battery with power applied (battery hot-swap supported on C200HS). Re-load program and restore data from .mem files. |
| DM read returns 0000 for all addresses | Wrong memory area selected in Memory Component view (e.g., H area displayed when DM expected) | Select D area explicitly. Confirm device type is C200HS, not C200H or CQM1. |
| Program downloads but new logic does not execute | Old program retained in RAM; auto-load not triggered | Verify DIP switch pin 2 setting. Issue explicit Transfer To PLC → Programs from CX-Programmer. |
| EM area contents erased | New program changed EM bank allocation or EM file format | Verify EM bank assignments in the new program. Re-transfer EM from .mem backup if allocation unchanged. |
| PLC reports "I/O Verify Error" (AR0801) | I/O rack configuration changed by the new program but hardware unchanged | Run I/O Table Registration via CX-Programmer: PLC → I/O Table → Create/Register. |
Field-Engineer Checklist for Safe Program Updates
- Confirm CPU type, model, and firmware revision match the target project.
- Check battery voltage (AR0804 OFF) and record the date.
- Upload the existing program and all data area .mem files. Save with timestamped filenames.
- Compute checksum or spot-check a few critical D/H values; record them on the work order.
- Place the PLC in PROGRAM mode.
- Transfer the new program only (not Memory, not Expansion Instructions, unless intentional).
- Verify program transfer completed without errors.
- Restore any data memory that the new program explicitly requires, if data map changed.
- Switch to MONITOR mode and perform a controlled test scan.
- Switch to RUN mode for production. Archive all backup files with the work order.
Related Omron C-Series Documentation
For engineers maintaining C200HS systems alongside newer CP1E, CP1L, or CJ2 CPUs, note that the same memory partition philosophy applies. The DM, HR, AR, LR, and EM regions exist in all C-series PLCs and are always preserved across standard program downloads. The CX-Programmer Memory Component interface exposes identical backup and restore operations for all of these platforms.
The complete C200HS operation procedures, error codes, and DIP switch definitions are documented in the official C200HS Operation Manual (W235-E1-05). Host Link addressing conventions and the C200H memory model are summarized in the KEPServerEX driver documentation: C200H Addressing in Omron Host Link Driver.
Which memory areas are erased when downloading a new program to an Omron C200HS?
A standard CX-Programmer program download writes only the User Memory (UM) region of the C200HS. The DM (D0000–D6655), HR (H000–H9915), AR, LR, IR/SR, TC PV, and EM areas remain unchanged, provided the lithium backup battery holds voltage above approximately 2.8 VDC and the new program does not trigger a memory-clear operation.
How do I back up DM and H memory before a C200HS program download?
Place the CPU in PROGRAM mode, open the Memory Component view in CX-Programmer, select the full D area (D0000–D6655), and use Transfer From PLC → D to save a .mem file. Repeat the procedure for the H area (HR00–HR99) using Transfer From PLC → H. The H area transfer also requires PROGRAM mode.
What CX-Programmer version is recommended for the C200HS?
CX-Programmer 7.2, bundled with CX-One 4.x, is the recommended stable version for C200HS support. Older versions such as 3.0 still communicate with the C200HS but lack support for later FINS protocol features and the CX-One integrated toolset. Newer CX-Programmer 9.x versions maintain backward compatibility for C200HS project files.
Why are my D or H area values cleared after a download?
The most common causes are: (1) the Memory Component Transfer To PLC operation was inadvertently included with the program transfer, (2) the lithium backup battery failed during a power cycle, triggering AR0804, (3) the new program executes an explicit data initialization routine on first scan, or (4) a Memory Cassette write operation with the DIP switch in an unexpected position. Verify battery health, then restore from the saved .mem files.
What is the file extension for an Omron C200HS memory backup?
Memory Component transfers in CX-Programmer produce files with the .mem extension. Each memory region (D, H, A, W, T/C, EM) is saved as a separate .mem file. The full project file uses the .cxp extension and contains both the ladder program and the Memory Component tables in a single archive.