ROM is either mask programmed at manufacture or field-programmable.
An addressed row causes the column wires to become one or zero according to whether the diodes are installed (or connected) at the crosspoints.
FLASH is a common type of ROM used in USB-sticks and SD cards. The 'switches' in FLASH are transistors with floating gates that are charged and discharged using electron tunnelling when ten or more volts are applied, but which retain their static charge for many years under normal conditions.
|7: (C) 2008-13, DJ Greaves, University of Cambridge, Computer Laboratory.|