亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

蟲蟲首頁| 資源下載| 資源專輯| 精品軟件
登錄| 注冊

INPUT-events

  • 溫濕度傳感器 sht11 仿真程序下載

    溫濕度傳感器 sht11 仿真程序 sbit out =P3^0; //加熱口  //sbit input =P1^1;//檢測口  //sbit speek =P2^0;//報警  sbit clo =P3^7;//時鐘  sbit ST =P3^5;//開始  sbit EOC =P3^6;//成功信號  sbit gwei =P3^4;//個位  sbit swei =P3^3;//十位 sbit bwei =P3^2;//百位 sbit qwei =P3^1;//千位 sbit speak =P0^0;//報警音 sbit bjled =P0^1;//報警燈 sbit zcled =P0^2;//正常LED  int count;  uchar xianzhi;//取轉換結果 uchar seth;//高時間 uchar setl;//低時間 uchar seth_mi;//高時間 uchar setl_mi;//低時間  bit  hlbz;//高低標志  bit  clbz;  bit  spbz;       ///定時中斷程序/// void t0 (void) interrupt 1 using 0 {     TH0=(65536-200)/256;//5ms*200=1000ms=1s   TL0=(65536-200)%256;  clo=!clo;//產生時鐘      if(count>5000)   {     if(hlbz)            {       if(seth_mi==0){seth_mi=seth;hlbz=0;out=0;}    else seth_mi--;       }     if(!hlbz)            {       if(setl_mi==0){setl_mi=setl;hlbz=1;out=1;}    else setl_mi--;       }   count=0;   }      else count++;         } ///////////// ///////延時/////// delay(int i) {    while(--i);          }     ///////顯示處理/////// xianshi() {      int   abcd=0;     int i;     for (i=0;i<5;i++) {   abcd=xianzhi;  gwei=1;  swei=1;  bwei=1;  qwei=1;  P1=dispcode[abcd/1000];   qwei=0;  delay(70);   qwei=1;  abcd=abcd%1000;  P1=dispcode[abcd/100];  bwei=0;  delay(70);  bwei=1;   abcd=abcd%100;  P1=dispcode[abcd/10];  swei=0;  delay(70);  swei=1;  abcd=abcd%10;  P1=dispcode[abcd];  gwei=0;  delay(70);  gwei=1;  } }   doing()   {     if(xianzhi>100)     {bjled=0;speak=1;zcled=1;}  else {bjled=1;speak=0;zcled=0;}   }   void main(void)  {  seth=60;//h60秒  setl=90;//l90秒  seth_mi=60;//h60秒  setl_mi=90;//l90秒  TMOD=0X01;//定時0 16位工作模式   TH0=(65536-200)/256;   TL0=(65536-200)%256;    TR0=1; //開始計時  ET0=1;   //開定時0中斷  EA=1;    //開全中斷  while(1)  {      ST=0;    _nop_();     ST=1;    _nop_();     ST=0;  //   EOC=0;          xianshi();       while(!EOC)   {         xianshi();    }        xianzhi=P2;             xianshi();     doing();  }  }

    標簽: sht 11 溫濕度傳感器 仿真程序

    上傳時間: 2013-10-16

    上傳用戶:黃蛋的蛋黃

  • Arduino應用_Arduino連接超聲波傳感器測距

    超聲波傳感器適用于對大幅的平面進行靜止測距。普通的超聲波傳感器測距范圍大概是 2cm~450cm,分辨率3mm(淘寶賣家說的,筆者測試環境沒那么好,個人實測比較穩定的 距離10cm~2m 左右,超過此距離就經常有偶然不準確的情況發生了,當然不排除筆者技術 問題。) 測試對象是淘寶上面最便宜的SRF-04 超聲波傳感器,有四個腳:5v 電源腳(Vcc),觸發控制端(Trig),接收端(Echo),地端(GND) 附:SRF 系列超聲波傳感器參數比較   模塊工作原理: 采用IO 觸發測距,給至少10us 的高電平信號; 模塊自動發送8個40KHz 的方波,自動檢測是否有信號返回; 有信號返回,通過IO 輸出一高電平,高電平持續的時間就是超聲波從發射到返回的時間.測試距離=(高電平時間*聲速(340m/s))/2; 電路連接方法   Arduino 程序例子: constintTrigPin = 2; constintEchoPin = 3; floatcm; voidsetup() { Serial.begin(9600); pinMode(TrigPin, OUTPUT); pinMode(EchoPin, INPUT); } voidloop() { digitalWrite(TrigPin, LOW); //低高低電平發一個短時間脈沖去TrigPin delayMicroseconds(2); digitalWrite(TrigPin, HIGH); delayMicroseconds(10); digitalWrite(TrigPin, LOW); cm = pulseIn(EchoPin, HIGH) / 58.0; //將回波時間換算成cm cm = (int(cm * 100.0)) / 100.0; //保留兩位小數 Serial.print(cm); Serial.print("cm"); Serial.println(); delay(1000); }

    標簽: Arduino 連接 超聲波傳感器

    上傳時間: 2013-11-01

    上傳用戶:xiaoyuer

  • Full support for extended regular expressions (those with intersection and complement); Support for

    Full support for extended regular expressions (those with intersection and complement); Support for some kinds of cycles in grammar; DFA-based operation; Unicode support; C++ only, requires a modern compiler; Lexical analyzers can be configured to get symbols from any input class (built-in support for std::istream, std::wistream and FILE *); Designed to work with Whale, but can work standalone or interface to other parsers.

    標簽: intersection expressions complement for

    上傳時間: 2013-12-11

    上傳用戶:zhanditian

  • (其中已經包含5個源碼)所附源程序C或C++代碼文件及其可執行文件 Scs.cpp 基本分類算法源程序

    (其中已經包含5個源碼)所附源程序C或C++代碼文件及其可執行文件 Scs.cpp 基本分類算法源程序, 輸入數據文件cfile.txt,efile.txt,gfile.txt,pfile.txt ,rfile.txt,tfile.txt Sga.c 基本遺傳算法源程序, 輸入數據文件input,輸出文件output A_life.c 基于遺傳算法的人工生命模擬源程序, 輸入數據文件world GA_nn.c 基于遺傳算法優化神經網絡結構源程序,輸入數據文件sample Patmat.c 基于遺傳算法提取基元圖形源程序

    標簽: Scs cpp 源程序 源碼

    上傳時間: 2014-01-11

    上傳用戶:13215175592

  • Tug of War(A tug of war is to be arranged at the local office picnic. For the tug of war, the picnic

    Tug of War(A tug of war is to be arranged at the local office picnic. For the tug of war, the picnickers must be divided into two teams. Each person must be on one team or the other the number of people on the two teams must not differ by more than 1 the total weight of the people on each team should be as nearly equal as possible. The first line of input contains n the number of people at the picnic. n lines follow. The first line gives the weight of person 1 the second the weight of person 2 and so on. Each weight is an integer between 1 and 450. There are at most 100 people at the picnic. Your output will be a single line containing 2 numbers: the total weight of the people on one team, and the total weight of the people on the other team. If these numbers differ, give the lesser first. )

    標簽: picnic the tug war

    上傳時間: 2014-01-07

    上傳用戶:離殤

  • The book presents the entire Java programming language and essential parts of the class libraries: t

    The book presents the entire Java programming language and essential parts of the class libraries: the collection classes and the input-output classes.

    標簽: programming essential libraries the

    上傳時間: 2015-03-02

    上傳用戶:yulg

  • pdnMesh is an automatic mesh generator and solver for Finite Element problems. It will also do post-

    pdnMesh is an automatic mesh generator and solver for Finite Element problems. It will also do post-processing to generate contour plots and Postscript printouts. GUI support using GTK or MFC (Win32) is available. The problem definition can be done in any form and given to pdnMesh as an input data file. Drawing Exchange Format (DXF) files can be directly imported to pdnmesh. The quality and the coarseness of the mesh can be controlled by giving input parameters.

    標簽: automatic generator problems pdnMesh

    上傳時間: 2013-12-19

    上傳用戶:cuibaigao

  • This directory contains code implementing the K-means algorithm. Source codemay be found in KMEANS.C

    This directory contains code implementing the K-means algorithm. Source codemay be found in KMEANS.CPP. Sample data isfound in KM2.DAT. The KMEANSprogram accepts input consisting of vectors and calculates the givennumber of cluster centers using the K-means algorithm. Output isdirected to the screen.

    標簽: implementing directory algorithm contains

    上傳時間: 2014-01-27

    上傳用戶:maizezhen

  • 程序存儲問題:設有n 個程序{1,2,…, n }要存放在長度為L的磁帶上。程序i存放在磁帶上的長度是Li

    程序存儲問題:設有n 個程序{1,2,…, n }要存放在長度為L的磁帶上。程序i存放在磁帶上的長度是Li ,1≤i≤n 程序存儲問題要求確定這n 個程序在磁帶上的一個存儲方案,使得能夠在磁帶上存儲盡可能多的程序。 編程任務: 對于給定的n個程序存放在磁帶上的長度,編程計算磁帶上最多可以存儲的程序數。 數據輸入:由文件input.txt給出輸入數據。第一行是正整數n,表示文件個數。接下來的1 行中,有n 個正整數,表示程序存放在磁帶上的長度。 結果輸出: input.txt output.txt 6 50 5 2 3 13 8 80 20

    標簽: 程序 磁帶 長度 程序存儲

    上傳時間: 2013-12-20

    上傳用戶:dongqiangqiang

  • 求解tsp問題的模擬退火源碼

    求解tsp問題的模擬退火源碼,數據文件請仿照文件中的input.txt自行創建

    標簽: tsp 模擬退火 源碼

    上傳時間: 2015-03-17

    上傳用戶:talenthn

主站蜘蛛池模板: 宣武区| 合水县| 铜梁县| 庆元县| 黔西县| 黎平县| 枣强县| 九寨沟县| 颍上县| 海宁市| 太和县| 景东| 安西县| 闽侯县| 泰州市| 夏邑县| 宜章县| 胶南市| 瑞丽市| 观塘区| 彰化市| 乌苏市| 贺州市| 许昌市| 北海市| 陕西省| 多伦县| 慈溪市| 若羌县| 乳源| 乌审旗| 江孜县| 额济纳旗| 崇阳县| 西乌| 新余市| 云浮市| 辽阳市| 军事| 佛山市| 会泽县|