port.h

来自「CODE for embedded C ,hand coding version」· C头文件 代码 · 共 37 行

H
37
字号
/*---------------------------------------------------------------*-
  Port.H (v1.00)
  Author:06_Digital_Media 
  All Right Reserved
  ----------------------------------------------------------------
  'Port Header'(See Chap 5) for project DATA_ACQ(see Chap 9)
  -*---------------------------------------------------------------*/
  #ifndef _PORT_H
  #define _PORT_H

  #include "Main.H"

  //---------Menu_A.c---------------------------------------------
  //Uses Whole of Port 1 and Port 2 for data acquisition
  #define Data_Port1 P1
  #define Data_Port2 P2
   
  //-------------LED_FLASH.C------------------------------------------
  //Connect LED to this pin,via appropriate resistor
  sbit LED_pin = P1^5 ;
 
  //-----------Switch_Wait.C----------------------------------------
  //Connect switch to this pin
  sbit Switch_pin = P1^0;
  
  //--------------Display_count.C---------------------------------
  //Display count (binary) on this port
  #define Count_port P3

  //--------PC_IO.C-----------------------------------------------
  //Pins 3.0 and 3.1 used for RS-232 interface 
  #endif
  /*------------------------------------------------------------*-
  -------END OF FILE ---------------------------------------------
  -*------------------------------------------------------------*/

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?