Digital Electronics - The 8051 Microcontroller - Discussion
Discussion Forum : The 8051 Microcontroller - General Questions (Q.No. 8)
8.
This statement will set the address of the bit to 1 (8051 Micro-controller):
SETB 01H
SETB 01H
Discussion:
26 comments Page 2 of 3.
Chirag Desai said:
1 decade ago
We can use SETB instuction on the specify PORTS only, e.g. SETB P0.0 or SETB P1.0.
Srinivas said:
1 decade ago
01h is byte address but setb is bit addressable instruction.
If you want to change the 01h data then you will use byte addressable instruction not use bit addressable instruction.
20h to 2fh have bit address so we will use this address.
If you want to change the 01h data then you will use byte addressable instruction not use bit addressable instruction.
20h to 2fh have bit address so we will use this address.
Vinoth said:
1 decade ago
SETB sets the data in the given address & not set address.
Sde said:
1 decade ago
Port B nothing but parity flag.
Anji said:
1 decade ago
SETB performs operation on flag bits not on address.
Raja said:
1 decade ago
Now a days many companies write the program for development of embedded product in c language there are some micros available to write and read the bit.
Write=Set_Bit (Px, bit no) ; /* x=either 0 or 1 or 2or 3*/.
Read=Is_Bit_Set (Px, bitno) ;.
Write=Set_Bit (Px, bit no) ; /* x=either 0 or 1 or 2or 3*/.
Read=Is_Bit_Set (Px, bitno) ;.
Surya said:
1 decade ago
Yes this answer is absolutly correct because we can set the data not a address.
RUDRASENAREDDY said:
1 decade ago
In order to access the 128 bits of RAM location and other bit addressable space of 8051 individually, we can use single bit instruction such as SETB.
Rocky said:
1 decade ago
Then, What is the correct answer???
Shruti said:
1 decade ago
SETB works only to set/reset(0 to 1 or 1 to 0) bit addresable
and flag registers..it cannot be used for set/reset of address
and flag registers..it cannot be used for set/reset of address
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers