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

linuxÏ´®¿Ú±à³Ì

Linux ´®¿Ú±à³ÌµÄһЩÎÊÌâ½â¾ö
LinuxÏ´®¿Ú±à³ÌµÄÎÄÕÂÍøÉÏÊÇÂúÌì·É£¬µ«´ó¶¼Êdzö×ÔһƪÎÄÕ£¬¶øÇÒдµÄ¶¼ÊÇЩ»ù±¾µÄ²Ù×÷£¬Ïñ¿ØÖÆRTS/CTSµÈ´®¿ÚÒý½Å״̬£¬½ÓÊÕ·¢ËͶþ½øÖÆÊý¾ÝµÈ£¬¶¼Ã»ÓкܺõÄ˵Ã÷£¬ÎÒÔÚʹÓÃÖÐÓöµ½ÁËЩÎÊÌ⣬д³öÀ´£¬Ï£ÍûÄܶԴó¼ÒÓÐËù°ïÖú£¬ÉÙ×ßÍä·£¬ºÇºÇ£¡
ÎÒʹÓõIJÙ×÷ϵͳÊÇRedhat9£¬gcc°æ±¾ÊÇ3.2.2
ÆäʵÔÚlinux϶Դ®¿ÚµÄÉèÖÃÖ÷ÒªÊÇͨ¹ýtermiosÕâ¸ö½á¹¹ÌåʵÏֵģ¬µ«ÊÇÕâ¸ö½á¹¹ÌåȴûÓÐÌṩ¿ØÖÆRTS»ò»ñµÃCTSµÈ´®¿ÚÒý½Å״̬µÄ½Ó¿Ú£¬¿ÉÒÔͨ¹ýioctlϵͳµ÷ÓÃÀ´»ñµÃ/¿ØÖÆ¡£
»ñµÃ£º
ioctl(fd, TIOCMGET, &controlbits);
if (controlbits & TIOCM_CTS)
printf(“ÓÐÐźÅ\n”);
else
printf(“ÎÞÐźÅ\n”);
ÉèÖãº
ioctl(fd, TIOCMGET, &ctrlbits)£»
if (flag)
ctrlbits |= TIOCM_RTS;
else
ctrlbits &= ~TIOCM_RTS;
ioctl(fd, TIOCMSET, &ctrlbits);
ÆäʵTIOCM_RTSÓÐЧºóÊÇ°Ñ´®¿ÚµÄRTSÉèÖÃΪÓÐÐźţ¬µ«´®¿ÚµÄµçƽΪµÍʱÊÇÓÐÐźţ¬Îª¸ßʱΪÎÞÐźţ¬ºÍÓÃTIOCMGET»ñµÃµÄ״̬ÕýºÃÏà·´£¬Ò²¾ÍÊÇ˵TIOCMGET/TIOCMSETÖ»ÊÇ»ñµÃ/¿ØÖÆ´®¿ÚµÄÏàÓ¦Òý½ÅÊÇ·ñÓÐÐźţ¬²¢²»·´Ó¦µ±Ç°´®¿ÚµÄÕæʵµçƽ¸ßµÍ¡£
ÍøÉÏÐí¶àÁ÷ÐеÄlinux´®¿Ú±à³ÌµÄ°æ±¾Öж¼Ã»¶Ôc_iflag£¨termios³ÉÔ±±äÁ¿£©Õâ¸ö±äÁ¿½øÐÐÓÐЧµÄÉèÖã¬ÕâÑù´«ËÍASCIIÂëʱûʲôÎÊÌ⣬µ«´«ËͶþ½øÖÆÊý¾ÝʱÓöµ½0x0d,0x11ºÍ0x13È´»á±»¶ªµô¡£²»ÓÃ˵Ҳ֪µÀ£¬Õ⼸¸ö¿Ï¶¨ÊÇÌØÊâ×Ö·û£¬±»ÓÃ×÷ÌØÊâ¿ØÖÆÁË¡£¹ØµôICRNLºÍIXONÑ¡Ïî¼´¿É½â¾ö¡£
       c_iflag &= ~(ICRNL | IXON);
0x0d »Ø³µ·ûCR
0x11 ^Q VSTART×Ö·û
0x13 ^S VSTOP×Ö·û
ICRNL ½«ÊäÈëµÄCRת»»ÎªNL  
IXON ʹÆð¶¯/Í£Ö¹Êä³ö¿ØÖÆÁ÷Æð×÷ÓÃ
ÔÚ¡¶UNIX»·¾³¸ß¼¶±à³Ì µÚ¶þ°æ¡·µÚ18ÕµÚ11С½Ú¿´µ½°ÑÖÕ¶ËI/OÉèÖÃΪԭʼģʽ£¨´®¿ÚͨѶ¾ÍÊÇÖÕ¶ËI/OµÄԭʼģʽ£©Ê±ÊäÈëÊôÐÔÉèÖÃΪ
term.c_iflag &= ~(BRKINT | ICRNL | INPCK | ISTRIP | IXON);
ÆÁ±ÎÁËÐí¶àÊôÐÔ£¬¹Ö²»µÃÓÐÈË˵Èç¹ûÊÇʹÓô®¿ÚͨѶc_iflagºÍc_oflag¶¼ÉèÖÃΪ0¾ÍÐÐÁË£¡
ÒÔÏÂÊÇÎÒµÄÉèÖõÄһЩÖØÒªµÄ´®¿ÚÊôÐÔ
term.c_cflag |= CLOCAL | CREAD;
term.c_lflag &= ~(ICANON | ECHO | ECHOE | ISIG);
term.c_oflag &= ~OPOST;
term.c_iflag &= ~(BRKINT | ICRNL | INPCK | ISTRIP | IXON);
static void request_send(void)
{
   


Ïà¹ØÎĵµ£º

ʵսLinux Bluetooth±à³Ì (Æß) SDPЭÒé

Service Discovery Protocol(SDP)ÌṩһÖÖÄÜÁ¦£¬ÈÃÓ¦ÓóÌÐòÓз½·¨·¢ÏÖÄÄÖÖ·þÎñ¿ÉÓÃÒÔ¼°ÕâÖÖ·þÎñµÄÌØÐÔ¡£
·þÎñ·¢ÏÖЭÒé(SDP»òBluetooth SDP)ÔÚÀ¶ÑÀЭÒéÕ»ÖжÔÀ¶ÑÀ»·¾³ÖеÄÓ¦ÓóÌÐòÓÐÌØÊâµÄº¬Ò⣬·¢ÏÖÄĸö·þÎñÊÇ¿ÉÓõĺÍÈ·¶¨ÕâЩ¿ÉÓ÷þÎñµÄÌØÕ÷¡£SDP¶¨ÒåÁËbluetooth client·¢ÏÖ¿ÉÓÃbluetooth server·þÎñºÍËüÃǵÄÌØÕ÷µÄ·½·¨¡£ ......

ÏÈ×°linux(ubuntu)ºó×°xpÐÞ¸´grub

×îºÃÊÇÏÈ×°XP£¬ºó×°LINUX£¬ÕâÊdz£Ê¶¡£Èç¹ûÒѾ­ÕâÑùÁË£¬×°ÍêXPºó¿Ï¶¨²»ÄÜÆô¶¯LINUX¡£
ÕâÐèÒªÓÃLINUX°²×°ÅÌÖØÐÂÐÞ¸´Æô¶¯ÏÖØдMBR£©¼°ÊÖ¹¤±à¼­LINUXµÄÆô¶¯²Ëµ¥
ϵͳÒýµ¼²»ÁËlinuxÁË£¬Ö»ÄܽøÈëxp;
²»ÊÇ°É£¬ÓÖÒªÖØ×°linux?
»Ø´ðÊÇ£º²»ÐèÒª;
ÏÂÃæ¾ÍÊǽâ¾ö·½°¸:
1.½øÈëxpϵͳ£»
2.°²×°wingrupÕâ¸öÈí¼þ;
3.ÖØÐÂÆô¶¯£¬Ñ¡Ô ......

LinuxϵͳʡÂÔÊäÈëÓû§ÃûÃÜÂë(×Ö·û½çÃæÏ£©

 
LinuxϵͳʡÂÔÊäÈëÓû§ÃûÃÜÂë(×Ö·û½çÃæÏ£©
1¡¢Ê¡ÂÔÃÜÂëÑéÖ¤
ºÜ¼òµ¥£¬Ö»Ðè°Ñ/etc/passwdÖеÄroot:x:0:0:root:/root:/bin/bash£¬¸ÄΪroot::0:0:root:/root:/bin/bash£¬¾Í¿ÉÒÔÁË£¬¾ÍÊÇÈ¥µôÁËÀïÃæµÄx£¬ÕâÑùrootÓû§¾Í²»ÓÃÃÜÂëÁË¡£ÆäËûÓû§Ò²Ò»Ñù¡£
2¡¢Ê¡ÂÔÊäÈëÓû§Ãû
(1)ÐÞ¸Ä/etc/inittab
ÔÚinittabÖУ¬ÓÐÈçÏÂÅä ......

LinuxÏÂHTTP·þÎñÆ÷µÄ´î½¨

 LinuxÏÂHTTP·þÎñÆ÷µÄ´î½¨
Linux Ï°²×°Tomcat 6µÄ²½ÖèÈçÏ¡£
£¨1£©µ½apacheÍøÕ¾ÏÂÔØTomcatÎļþ apache-tomcat-6.0.18.tar.gz¡£
£¨2£©ÔÚ/usrĿ¼Ï½¨Á¢TomcatĿ¼¡£
£¨3£©½âѹapache-tomcat-6.0.18.tar.gz Îļþ¡£
#tar -xvzf apache-tomcat-6.0.18.tar.gz
£¨4£©ÐÞ¸Äetc/profile Îļþ£¬ÔÚ×îºó¼ÓÈëÈçÏ´úÂë¡£
exp ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ