Make ROM for Omron Sysmac C40K, have some files...

e5frog

Member
Join Date
May 2011
Location
Alvangen
Posts
16
We've got the Omron Sysmac C40K in a few of our machines at work, one of them started to behave bad and gave up. Power LED on and input LEDs work but not "RUN" or any outputs (surprise). So I suspected a dead battery and after opening it I understand it hasn't been checked or swapped for over 15 years or so.

Oxidation on solder joints on nearby components, inside of display lid all rusty and the battery so badly oxidized that there was a pile beneath it with oxidation-debris and connector completely loose. One of the hookup pins to the battery connector had also rusted completely off.



Anyway, don't know if we're going to try and repair this (anyone that answer here will probably say "swap it for a new one, reprogram and be done with it" but it's not my decision to make) or replace it with another one just like it. We have another one just like it that runs fine and has a very fresh battery. Also had a 3.5" diskette with the code on it...

Easiest solution as I see it is to get the original program, place it on a 2764 EPROM and shove that into the machine and not worry about the battery anymore.
However, I don't really have a binary file to put there and I guess I would need to hookup the RAMs of the working machine and read them to be able to get that?

The diskette seeems to contain information about the build of the entire unit, there's a DWG file I could open with some schematics and then there are files (from 1995) called:
94A912&.PRG 796 bytes
94A912.$AH 212 bytes
94A912.$AS 1.12 kB
94A912.$PR 7.62 kB
94A912.AHD 212 bytes
94A912.ASF 1.12 kB
94A912.MAP 290 bytes
94A912.PRG 7.62 kB
94A912.SWN 7.62 kB
312-039&.PRG 1.96 kB
312-039.AHD 1012 byte
312-039.ASF 7.33 kB
312-039.MAP 21 byte
312-039.PRG 11.7 kB
312-039.SWN 549 byte
312_039&.PRG 547 byte
312_039.AHD 1.01 kB
312_039.ASF 7.43 kB
312_039.MAP 290 byte
312_039.PRG 9.02 kB
312_039.SWN 491 byte

Judging by the suffix SWN I decided it might be so easy as being SysWin files - and I opened some up just fine, seems to be version 1.x files.

The latest files are (dated 25th April 1995) :
94A192.PRG
94A192.AHD
94A192.ASF
94A192&.PRG

It seems I can't make a binary for an EPROM (or EP-ROM as it says in the manuals) directly from SysWin, is that right? Are there any other ways of turning the file/s into a binary file that I can burn with a plain eprom burner? I wouldn't know exactly which files to use either. Looking at the SWN file in a hex editor it looks like it's referring to other files so I'm guessing that's what to use

If not I guess I'll have to blast out the cash for a Hostlink, download the program from the working one and upload it to the blank one after hooking up a new battery... I think we have at least four C40K in use, all running from RAM and probably with the original battery still in.
 
Not a solution to your problem, but rather a suggestion.

Wire an indication lamp to a spare output which shows the PLC is running. Use a clock pulse in conjunction with the PLC battery Low flag, so that the output flashes when the battery needs to be changed. Operators notice these things and inform maintenance, especially when the light has been on for as long as he can remember.
 
Might not help but here's a link to the manual.
Link:
http://www.google.com/url?sa=t&source=web&cd=2&ved=0CEcQFjAB&url=http%3A%2F%2Fwww.ramcodeals.com%2Fpdf%2Fc28kcara.pdf&ei=fLTSTaH8I5G6tgex_vn5CQ&usg=AFQjCNHJVJEL2h1R6hiqAMDwkAz_eWfXdQ

Link to an old thread on mrplc.com with some info on programming cable, etc.
Link:
http://forums.mrplc.com/index.php?showtopic=5242

Zip and post the files, maybe someone can help with them.

I'm a little curious about the need to burn a 2764 EPROM. I would think that just the operating system would be stored on it. The Application Program would likely be stored in the batery backed RAM, not the EPROM. Originally, using the Hand-Held Programmer, the Application Program was stored and saved on a cassette recorder tape as I recall. Using the Syswin Software, I would think that it saves it to files like you have.
 
Last edited:
Don't think we have any free outputs on the PLC but it's a good suggestion.


I had found those files already but thanks anyway. The reason for using an EPROM is so that you won't loose the program if the battery dies while there's a power outage. From what I have read the last 24 hours that's how it seems to work (Program Memory in EPROM is mentioned). I understand that it's a lot easier to have in in RAM if you want to change things, and especially if you need another module just to be able to program an EPROM (PROM Writer), but an EPROM seems like the safer choice.

It would be quite handy if I could simply put an eprom in the eprom programmer and then plug it in instead of trying to find a Hostlink for an affordable price. (Last one on eBay went for $515, there's one for $999 and one new for $1600 currently).
I wouldn't need to get a battery either as far as I understand - or is there still something that needs to be programmed with the Hostlink - is there no way to be completely safe?


It seems that on this particular machine having problems all power is cut when it's turned off and the other two units I checked yesterday (that are still fresh and has over 3.6V on the battery) the PLC is still powered when unit is shut down, could be an explanation perhaps.

I'm also considering reading out the RAM from a working machine and then write it to the non-working. Don't know what type of RAM it has though, need to check. Perhaps something to do when I brush away the rust before re-assembly.
 
I found the manual for the eprom programmer (a module that can be hooked to the C40K and others just like the Hostlink) on http://www.myomron.com in this I can read this:
"To write HR, TC and DM area contents, set this switch to 9. Set to 8 to write CM data" it refers to the CHIP NO Selector and I think those data is written to a separate slot in the eprom.
Further on however it reads that you can't store HR, TC, DM nor CM data in eprom on the K-series, so can it start with a blank memory there or is there no use at all making an eprom for these?
 
Found a spare C20K in the storage space, disassembled the front, checked the pinouts of the internal connector. There seems to be a ROM as well connected in parallel with the SRAM which is a Sharp LH5168H in this one, power is backed up from a capacitor of 0.047F - yes that's 47 milliFarad - when it's detached from the main unit where the 3,6V Lithium battery otherwise holds the voltage up if there's no 5V.

I figured it would be possible to detach the front, hook 5V to the needed points in the connector, unscrew and remove metal shield, unscrew PCB and then hook up an eprom programmer to the RAM and read it. Then do the opposite on the empty machine.

Need to practice some first but it feels like a fun challenge while waiting to find a Hostlink.
 
I took some pictures and checked the insides:

The C20K is the same inside as the C40K, just a few missing parts.




I dumped that rom seen in the plain socket, it's a 128kbit rom/prom I imagine there's one for each model. The rom dump says C20K-CDR-A near the end.

Processing power comes from a HitachiHD63B03X MPU and I've also marked the interesting parts, the SRAM and powersupply to this: the large capacity 5.5V capacitor and the pins where the backup and normal power comes in for the SRAM.


So has anyone here attempted a similar dump and programming method - going straight to the RAM?

Another idea is to write a RAM dumper program, place that in an eprom and replace the "BIOS ROM" then let the Hitachi MPU dump the RAM somewhere handy, maybe the SCI or possibly via the ROM-H socket. That requires a lot of work though.

Don't know what the Omron circuits are, 64H151 and 64H152A, possibly the main interface circuitry one for the external connector and one for the internal. The connectors are the same type BTW in case you'd like to attempt to build your own Hostlink you could use the internal connector from a broken unit.
 
Last edited:
Just thought I should update.

I tried hooking up the battery backed up RAM of an inactive unit to my eprom programmer but I got nothing out nor into it. I guess the other circuits were interfering too much.

Reading and writing to this type of RAM directly in the programmer is no problem however.

So a Hostlink was ordered, but I am still going to try another approach as well. I bought an IC clamp and I'm going to attach a RAM just like it in parallel with the /WE hooked to the /OE. Which means that every time the original RAM is read the data is written to the parallel-ly hooked RAM...

When the entire programming has been run through, unit has been started, turned off etc there should at least be a copy of that code so I might be able to get something running while waiting for the Hostlink.

Will try tomorrow...
 

Similar Topics

Hi, I have taken over maintaining some HVAC units that are run by the Sysmac C20 PLC. To keep a stock of PLCs handy we have had to buy used PLCs...
Replies
10
Views
2,257
Hi everybody, I can't transfer data from laptop to omron sysmac cj1m cpu11. I use cable "omron cs1w-cn118" and Uport 1150 (RS232),I sure software...
Replies
0
Views
3,882
Our machines plc's are obsoleted. I cant get the programming cable to backup my plc. Pls help ,if any alternative cable or circuit available for...
Replies
2
Views
2,622
I have Omron Sysmac C40k programmable controller... I want to program it but i dont have programed eprom and Host link unit.. But I have Syswin...
Replies
6
Views
6,632
Is there a way in CX-Programmer to call Ladder Instructions from a structured text program? I can see several functions in the autocomplete...
Replies
3
Views
1,850
Back
Top Bottom