Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÔÚlinuxÏ »ñÈ¡±¾»úMACµØÖ·µÄº¯Êý

//»ñÈ¡±¾»úMACµØÖ·º¯ÊýQString GetLocalMac()
{
int sock_mac;

struct ifreq ifr_mac;
char mac_addr[30];

sock_mac = socket( AF_INET, SOCK_STREAM, 0 );
if( sock_mac == -1)
{
perror("create socket falise...mac\n");
return "";
}

memset(&ifr_mac,0,sizeof(ifr_mac));
strncpy(ifr_mac.ifr_name, "eth0", sizeof(ifr_mac.ifr_name)-1);
if( (ioctl( sock_mac, SIOCGIFHWADDR, &ifr_mac)) < 0)
{
printf("mac ioctl error\n");
return "";
}

sprintf(mac_addr,"%02x%02x%02x%02x%02x%02x",
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[0],
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[1],
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[2],
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[3],
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[4],
(unsigned char)ifr_mac.ifr_hwaddr.sa_data[5]);
printf("local mac:%s \n",mac_addr);

close( sock_mac );
return QString( mac_addr );
}


Ïà¹ØÎĵµ£º

ʵսLinux Bluetooth±à³Ì£¨ËÄ£© L2CAP²ã±à³Ì

£¨L2CAPЭÒé¼ò½é£¬L2CAPÔÚBlueZÖеÄʵÏÖÒÔ¼°L2CAP±à³Ì½Ó¿Ú£©
Ò»£ºL2CAPЭÒé¼ò½é£º
Logical Link Control and Adaptation Protocol(L2CAP)
Âß¼­Á¬½Ó¿ØÖƺÍÊÊÅäЭÒé (L2CAP) ΪÉϲãЭÒéÌṩÃæÏòÁ¬½ÓºÍÎÞÁ¬½ÓµÄÊý¾Ý·þÎñ£¬²¢Ìṩ¶àЭÒ鹦ÄܺͷָîÖØ×é²Ù×÷¡£L2CAP ³äÐíÉϲãЭÒéºÍÓ¦ÓÃÈí¼þ´«ÊäºÍ½ÓÊÕ×î´ó³¤¶ÈΪ 64K µÄ L2CAP Ê ......

LinuxÉϹÒÔØWindows¹²ÏíĿ¼

------------LinuxÉϹÒÔØWindows¹²ÏíĿ¼£¨ÖØÆôºóʧЧ£©--------------------
µÚÒ»²½£ºÏÈÔÚWindowsÉÏ´´½¨Ò»¸ö¹²ÏíĿ¼
µÚ¶þ²½£ºÔÚlinuxÖÐÔËÐÐÈçÏÂÃüÁ
mount.cifs //192.168.10.43/shared /root/shared -o user=name,pass=123456
×¢£º/root/sharedÊÇlinuxÉϵÄĿ¼¡£userÊÇWindowsϵͳµÄÓû§Ãû  passÊÇWindo ......

Linux Platform Device and Driver

    
´Ó
Linux 2.6
ÆðÒýÈëÁËÒ»Ì×еÄÇý¶¯¹ÜÀíºÍ×¢²á»úÖÆ :Platform_device
ºÍ Platform_driver
¡£
     Linux
Öд󲿷ֵÄÉ豸Çý¶¯£¬¶¼¿ÉÒÔʹÓÃÕâÌ×»úÖÆ ,
É豸ÓÃ
Platform_device
±íʾ£¬Çý¶¯ÓÃ
Platform_driver
½øÐÐ×¢²á¡£

     Linu ......

LinuxϵĶ¨Ê±Æ÷£ºalarm()Óësetitimer()


LinuxϵĶ¨Ê±Æ÷ÓÐÁ½ÖÖ£¬ÒÔÏ·ֱð½éÉÜ£º
1¡¢alarm
Èç¹û²»ÒªÇóºÜ¾«È·µÄ»°£¬ÓÃalarm()ºÍsignal()¾Í¹»ÁË
unsigned int alarm(unsigned int seconds)
º¯Êý˵Ã÷: alarm()ÓÃÀ´ÉèÖÃÐźÅSIGALRMÔÚ¾­¹ý²ÎÊýsecondsÖ¸¶¨µÄÃëÊýºó´«Ë͸øÄ¿Ç°µÄ½ø³Ì¡£Èç¹û²ÎÊýsecondsΪ0£¬Ôò֮ǰÉèÖõÄÄÖÖӻᱻȡÏû£¬²¢½«Ê£ÏµÄʱ¼ä·µ»Ø¡£
·µ»ØÖµ: ......

·ÖÏí LinuxÑݱäµÄ15¸öÖØ´óÀï³Ì±®

¾Ý¹úÍâýÌ屨µÀ£¬½üÈÕ£¬×ÊѶÍøÕ¾TechradarÁоÙÁ˽üÊ®ÄêÀ´LinuxϵͳÑݱäÀú³ÌÖеÄÖØҪʱ¿Ì£¬ÏÂÃæÈÃÎÒÃÇÀ´ä¯ÀÀÕâ15¸ö¾ßÓÐÀï³Ì±®ÒâÒåµÄ¸Ä½ø£º
1¡¢2001Äê1Ô£ºLinux Kernel 2.4
Linux 2.4°æÊÇÒ»¸öÖØÒªµÄ·ÖË®Á룬¸Ã°æ±¾ÏµÍ³ÌṩÁËÐí¶àÖØÒªµÄ½Ó¿Ú£¬ÖîÈçUSBÆô¶¯¡¢À¶ÑÀÖÕ¶ËÉ豸¡¢ÄÚǶRAIDºÍext3¸ñʽµÄÎļþϵͳ¡£Linux³öÉ«µÄÇý¶¯³ÌÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ