What is the Difference Between RAM And ROM? There is major 5 difference between RAM and ROM listed below: There is one major distinction between a ROM and a RAM chip as per the name.
seen from Türkiye
seen from Germany
seen from Malaysia
seen from United States

seen from United States
seen from Canada
seen from China

seen from Australia
seen from China

seen from Germany

seen from Australia

seen from Canada

seen from Germany

seen from Canada
seen from Italy

seen from Australia
seen from Estonia
seen from Germany

seen from United States
seen from Spain
What is the Difference Between RAM And ROM? There is major 5 difference between RAM and ROM listed below: There is one major distinction between a ROM and a RAM chip as per the name.
ROM, PROM, EPROM, EEPROM
So in my unending quest to learn about microcontrollers and such, you inevitably have to deal with memory, and how the microcontroller knows what program to run. So from a lovely conversation with the folks in the IRC, a simple but easy-to-understand summary:
ROM: Read Only Memory
ROM is only programmable once. For example, it could be programmed at the factory where they make the chip. And indeed, it's usually used in firmly hardcoded chips made by the company.
Clarification from a reader: "ROM is not "programmed at the factory" in the same sense that you imply or even "programmed once". It is programmed never. The data is hard-coded into the chip itself. Once the chip wafer is manufactured, that is it, it can never be changed, only tested before it goes out. The ones and zeros are hard-coded connections to +V and ground."
PROM: Programmable Read Only Memory
This is similar to ROM except that you, the consumer, can program it. You can buy a blank chip and have a PROM programmer program it with your stuff. But, once you program it, you can never change it.
This is an example of a PROM programmer and you can just plug it into a port on your computer as a peripheral. (I think this one's oldschool though)
EPROM: Erasable Programmable Read Only Memory
So the cool this about this one is that you can rewrite this type of memory. To erase a previous program though, you need to set it under some form of UV light for a specified amount of time before being able to rewrite it.
You can see the window there that allows the UV light to get through and erase the memory for you to rewrite! This can be used by hobbyists if they want to make a limited run of a product as it is cheap.
So I asked why a company would rather use this over a ROM and got the following response from @izerth:
A company may use EPROM over ROM anytime they need something different for each device, like a serial number.
They're also used for configuration and calibration for measuring devices. For instance, say your manufacturing process for scales isn't 100% accurate. Before it leaves the facility, you measure some test weights, see how it skews, and then program a PROM with correction data.
With this set up, you can recalibrate after a year of wear and tear. In fact, there are still scales where a guy will come out, test it, pop the chip out, program it, and then pop it back in.
If it was an EEPROM, you wouldn't need to pop it out, but if it was a ROM, you'd need to replace the entire chip.
EEPROM: Electrically Erasable Programmable Read Only Memory
So this one is the one that most people these days probably use (especially those working with microcontrollers on a hobby level). Essentially, it can be written, erased, rewritten electronically. No need for a fancy UV light thing.
From some of the conversations, it seems that this is done often through flash memory - a feature of quantum tunneling. And while I won't go into the specifics of that, the essential idea is that as "programming" occurs, electrons jump from one side of a barrier to the other and the action of holding that configuration becomes memory.
I think of it like this:
There's a barrier that normally cannot be surpassed (air vs metal) unless some form of force is put on it (current? programming mojo?). But once that is in motion, you end up with memory of whatever you put there.
Lol. Quantum tunneling made easy enough for an Atdiy to understand it :p
@atdiy/@tymkrs