thank you that was so helpfull,but one more thing i wannd do a program that deal with all the contents of the MAC frame like,,the destenation address, lenght of PDU,source address, SFD...so how can i implement those things in a C++ program?????????
1) please try to ask more a more precize question next time
2) MAC address and MAC Frames are two different things. The Media Access Control protocol (IEEE 802.x) defines a way for defining, delimiting and adressing logical frames for other protocols (Ethernet, wifi, token ring, etc...) . It is not directly related with IP.
3) If you want to dissect MAC (or other prototocols) network packets, you may have a look at the norm, or find a library that parses network stream.