l I have micro controller 89c51 ,LED,switch,compiler(keil),programmer (flesh magic)
SWITCH is input device connected port pin P0.1
LED is output device connected port pin P1.1
I have written assembly code in keil software for example
Code:
ORG OH
ON:
SETB P1.1 ; LED IS ON
OFF:
CLRB P1.1 ; LED IS OFF
LOOP:
JB P0.1 ; SWITCH ON
JNB P0.1 ; SWITCH OFF
SJMP LOOP
END
assembler convert this code into machine code
for example
Code:
:10000000743811221142740F112211427406112208
:100010001142748411221142744E112F1142744FF7
:10002000112FF590C2A0C2A1D2A21142C2A222F504
:1000300090D2A0C2A1D2A21142C2A222741811224F
:0B00400080FA7B647CFFDCFEDBFA2210
:00000001FF
this hexa code burn into the memory of controller
1) I don't know where this hexa code burn into the RAM memory or ROM memory ?
2)I don't know this hexa code contain the data or address of data or both data and address?
3)software side ROM memory is use to write code but what is the work of rom memory on hardware
4)software side RAM memory is used to store address of data but what is work of RAM memory on hardware ?
5)micro controller take input from switch how the signal goes in internal circuit of micro controller throw the ALU , CONTROL unit, RAM, ROM , switch , LED, data register, address register, instruction register
simple controller take input and processor perform the task and LED will blink
how this process done ?
I have searched lot of about microcontroller and waste most of time to find out internal circuitry how they work but still I did not get correct logic please anyone help me to working of microcontroller with internal circuit.