what is difference between rom address, ram address and I/o address?

Discussion in 'General Electronics Chat' started by vead, Apr 23, 2014.

  1. vead

    Thread Starter Active Member

    Nov 24, 2011
    621
    8
    Rom has address
    Ram has address
    I/o device address
    can anyone explain with example what is difference between rom address, ram address and I/o address?
     
  2. alfacliff

    Well-Known Member

    Dec 13, 2013
    2,449
    428
    that is determined by your address decoder. some computers use ram addresses for i/o, some dont. mostly, the rom addresses can only be read, the ram addresses can read and write, and i/0 is usually addressed by bits.
     
  3. vead

    Thread Starter Active Member

    Nov 24, 2011
    621
    8
    I am asking for 8051 controller
     
  4. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    It would be better if you could relate the question to a specific microprocessor. I am quite puzzled you ask about this. As I know your are student with an assignment to write VHDL code to emulate a microcontroller or processor. This is quite basic microprocessor architecture knowledge
     
  5. alfacliff

    Well-Known Member

    Dec 13, 2013
    2,449
    428
    it is still determined by the software and hardware. other than that, it is treated the same, other than not being able to write to rom.
     
  6. bertus

    Administrator

    Apr 5, 2008
    15,649
    2,348
    Last edited: Apr 23, 2014
  7. vead

    Thread Starter Active Member

    Nov 24, 2011
    621
    8
    I have done little work please check out

    Instruction - mov , add
    Register - A ,R1
    address- ROM Address, RAM address
    data - 02,03 and 05

    ADD- 0001
    MOV -0010

    A register= 01
    R1 register=06

    A register at rom address=8001
    R1 register at rom address=8002


    Instruction + register +address +data
    mov + A + # +02
    0010 +01 +8001 +02

    we can say that mov A, #2

    0010 06 8002 03

    we can say mov R1,#3

    and 0001 01 06
    add A, R1

    now this result will be store somewhere in ram address like 7001
     
  8. ian field

    Distinguished Member

    Oct 27, 2012
    4,415
    784
    AFAICR - any CPU who's number starts with 8, I/O is treated as ports rather than mapped into the memory address space.

    Within the memory space; ROM is "read only memory" - not quite so obvious in the naming; RAM, "random access memory" is the sort you can write data to as well as read it back.

    There's also flash ROM, typically the BIOS in a PC might be flash - you might perhaps "flash" an updated BIOS a couple of times during the life of the MOBO.

    In addition there's EEPROM, the most common type uses a serial interface and is typically used for storing user parameters for a microcontroller - they have limited number of write cycles, so using it as CPU RAM would wear it out in literally minutes.
     
Loading...