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

S3C24XXÌåϵµÄLinux GPIO¿ØÖÆÏà¹ØAPIʵÏÖ

GPIO£¨General Purpose Input/OutputµÄËõд£©¾ÍÊÇоƬµÄÒý½Å£¬Òý½ÅÊǿɱà³ÌµÄ¿É¶ÔÒý½ÅµÄ¹¤×÷ģʽ½øÐÐÉèÖãºÊäÈëģʽ(¼ì²âÊäÈëÐźÅ)£¬Êä³öģʽ(Êä³ö0»ò1)£¬¸ß×è״̬(³£ÓÃÓÚADת»»)£¬»¹ÓнûÖ¹»òÔÊÐíÉÏÄÚ²¿ÏÂÀ­µç×è(ÉÏÀ­£º¹Ü½Åͨ¹ýµç×è½Ó¸ßµçƽ£¬ÏÂÀ­£º¹Ü½Åͨ¹ýµç×è½ÓµØ£¬Ò²¿ÉÒÔÍⲿ½ÓÉÏÀ­»òÏÂÀ­µç×è)£¬»¹ÓйܽŸ´Óõȹ¦ÄÜ£¬¼´Í¨¹ý¶ÔÄÚ²¿¼Ä´æÆ÷µÄÉèÖÃʹÒý½Å¼È¿ÉÒÔ¹¤×÷ÔÚÒ»°ãģʽ£¬×÷ΪÆÕͨµÄGPIO¿ÚʹÓã¬Ò²¿ÉÒÔ¹¤×÷ÔÚÌØÊâģʽ£¬±ÈÈç×÷ΪÍⲿÖжÏÐźÅÊäÈëÒý½ÅµÈµÈ¡£Èç¹û²»ÉèÖÃGPIOÒý½Å£¬CPU¹¤×÷ʱÓÐÒ»¸ö³õʼ»¯Ä£Ê½£¬¿ÉÒÔ´Ódatasheet£¨Ð¾Æ¬ÊֲᣩÉÏÁ˽⡣¶ÔGPIOµÄ¿ØÖÆÊDZàдÇý¶¯³ÌÐò×î³£¼ûºÍÖØÒªµÄÒ»Ï×÷ÄÚÈÝ¡£
ÔÚLinux2.6.25Äں˴úÂëÖУ¬ÒѾ­ÌṩÁËÕë¶ÔÈýÐÇS3C2410/S3C2440µÈоƬGPIOµÄ¿ØÖÆ£¬ÏÂÃæÀ´·Ö±ð½éÉÜÒ»°ãÈçºÎÅäÖᢹÜÀíGPIO¡£
       ÏÂÃæµÄº¯ÊýÊÇÓÃÀ´¸ù¾ÝÐµĹ¦ÄÜÐèÇóÅäÖÃÒ»¸öGPIOÒý½Å£¨¶¨ÒåÔÚarch/arm/plat-s3c24xx/gpio.c£©£º
     1    void s3c2410_gpio_cfgpin(unsigned int pin, unsigned int function)
     2    {
     3           void __iomem *base = S3C24XX_GPIO_BASE(pin);
     4           unsigned long mask;
     5           unsigned long con;
     6           unsigned long flags;
     7   
     8           if (pin < S3C2410_GPIO_BANKB) {
     9                  mask = 1 << S3C2410_GPIO_OFFSET(pin);
    10           } else {
    11                  mask = 3 <&


Ïà¹ØÎĵµ£º

LinuxÏÂÈ÷ÇrootÓû§ÆôÓÃСÓÚ1024ºÅµÄ¶Ë¿Ú


ÒÔÏÂÊÇÕÒµ½µÄLinuxµÄ×ÊÁÏ£¬Solairs¡¢AIXµÈÓ¦µ±ÓÐËù²»Í¬£¬Çë¸ú½ø
·½·¨Ò»£º¶Ë¿ÚÓ³Éä
1¡¢iptablesÃüÁî:iptables -t nat -A PREROUTING -p tcp --dport <µÍ¶Ë¿Ú> -i eth0 -j REDIRECT --to-port <Ô­ÏȼàÌýµÄ¸ß¶Ë¿Ú>
2¡¢rinetd³ÌÐò
3¡¢ipchansÃüÁî:ipchans -I input --proto TCP --dport <µÍ¶Ë¿Ú> - ......

Linux makefile ½Ì³Ì ·Ç³£Ïêϸ£¬ÇÒÒ׶®


³Âð© (CSDN)
¸ÅÊö
——
ʲôÊÇ
makefile£¿»òÐíºÜ¶àWinodwsµÄ³ÌÐòÔ±¶¼²»ÖªµÀÕâ¸ö¶«Î÷£¬ÒòΪÄÇЩWindowsµÄIDE¶¼ÎªÄã×öÁËÕâ¸ö¹¤×÷£¬µ«ÎÒ¾õµÃÒª×÷Ò»¸öºÃµÄºÍ
professionalµÄ³ÌÐòÔ±£¬makefile»¹ÊÇÒª¶®¡£Õâ¾ÍºÃÏñÏÖÔÚÓÐÕâô¶àµÄHTMLµÄ±à¼­Æ÷£¬µ«Èç¹ûÄãÏë³ÉΪһ¸öרҵÈËÊ¿£¬Ä㻹ÊÇÒªÁ˽â
HTMLµÄ±êʶµÄº¬Òå¡£Ìرð ......

Linux ±¸·ÝÓë»Ö¸´ËÙ³ÉÖ¸ÄÏ

 
 
È·¶¨Òª±¸·ÝµÄÄÚÈÝ
ÔÚ±¸·ÝºÍ»¹Ô­ÏµÍ³Ê±£¬Linux »ùÓÚÎļþµÄÐÔÖʳÉÁËÒ»¸ö¼«´óµÄÓŵ㡣ÔÚ Windows ϵͳÖУ¬×¢²á±íÓëϵͳÊǷdz£Ïà¹ØµÄ¡£ÅäÖúÍÈí¼þ°²×°²»½ö½öÊǽ«Îļþ·Åµ½ÏµÍ³ÉÏ¡£Òò´Ë£¬»¹Ô­ÏµÍ³¾ÍÐèÒªÓÐÄܹ»´¦Àí Windows ÕâÖÖÌØÐÔµÄÈí¼þ¡£ÔÚ Linux ÖУ¬Çé¿ö¾Í²»Ò»ÑùÁË¡£ÅäÖÃÎļþÊÇ»ùÓÚÎı¾µÄ£¬²¢ÇÒ³ýÁËÖ±½Ó´¦À ......

linuxĿ¼ºÍÎļþϵͳ

Linux ºÍ Unix Îļþϵͳ±»×éÖ¯³ÉÒ»¸öÓвã´ÎµÄÊ÷Ðνṹ¡£ÎļþϵͳµÄ×îÉϲãÊÇ /£¬»ò³ÆΪ ¸ùĿ¼¡£ÔÚ Unix ºÍ Linux µÄÉè¼ÆÀíÄîÖУ¬Ò»ÇнÔΪÎļþ——°üÀ¨Ó²ÅÌ¡¢·ÖÇøºÍ¿É²å°Î½éÖÊ¡£Õâ¾ÍÒâζ×ÅËùÓÐÆäËüÎļþºÍĿ¼£¨°üÀ¨ÆäËüÓ²Å̺ͷÖÇø£©¶¼Î»ÓÚ¸ùĿ¼ÖС£ ÀýÈ磺/home/jebediah/cheeses.odt ¸ø³öÁËÕýÈ·µÄÍêÕû·¾¶£¬ËüÖ¸ ......

Linux½ø³Ì¼äͨѶ֮ÏûÏ¢¶ÓÁÐ


1. »ù±¾¸ÅÄî
ÏûÏ¢¶ÓÁеÄ×î¼Ñ¶¨ÒåÊÇ£ºÄں˵ØÖ·¿Õ¼äÖеÄÄÚ²¿Á´±í¡£ÏûÏ¢¿ÉÒÔ˳ÐòµØ·¢Ë͵½¶ÓÁÐÖУ¬
²¢ÒÔ¼¸ÖÖ²»Í¬µÄ·½Ê½´Ó¶ÓÁÐÖлñÈ¡¡£µ±È»£¬Ã¿¸öÏûÏ¢¶ÓÁж¼ÊÇÓÉ IPC±êʶ·ûËùΨһ±êʶµÄ¡£
2. ÄÚ²¿ºÍÓû§Êý¾Ý½á¹¹
ÒªÍê³ÉÀí½âÏóϵͳ V IPCÕâÑù¸´ÔÓµÄÎÊÌ⣬¹Ø¼üÊÇÒª³¹µ×ÊìϤÄں˵ļ¸¸öÄÚ²¿Êý¾Ý½á¹¹¡£
ÉõÖÁ¶ÔÄÇЩ×î»ù±¾µÄ²Ù×÷ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ