Robofun 機器人論壇

 找回密碼
 申請會員
搜索
熱搜: 活動 交友 discuz
查看: 7247|回復: 9
打印 上一主題 下一主題

HIGH和LOW的問題...

[複製鏈接]
跳轉到指定樓層
1#
發表於 2010-8-5 15:20:53 | 只看該作者 回帖獎勵 |倒序瀏覽 |閱讀模式
Arduino輸入腳位怎麼判定1(High) or 0(Low)
是看輸入時的電壓高於多少嗎@@?
因為正在學習控制板...但不知道這個地方要怎麼判定...
aroboto 該用戶已被刪除
2#
發表於 2010-8-5 16:20:59 | 只看該作者
對的~
如果控制器是5V控制環境   HIGH-->5V
如果控制器是3.3V控制環境   HIGH-->3.3V
3#
 樓主| 發表於 2010-8-5 16:57:08 | 只看該作者
0.0...控制器是指Arduino的整塊板子嗎?
剛剛是做了一些試驗...Arduino控制板(應該都是5V吧?)輸入腳位的是由反相器IC(4.5V供電)的輸出進入...
他對於我寫的程式有HIGH的反應...所以挺疑惑的是範圍值多少都能代表HIGH...表達不好請見諒= =""
4#
發表於 2010-8-5 22:05:00 | 只看該作者
以5V系統來說,看是CMOS的IO還是TTL的IO。
CMOS的HIGH在0.7VCC左右,TTL則在2.5以上就為HIGH。
到底是那種,看規格書就知。
5#
 樓主| 發表於 2010-8-5 22:21:31 | 只看該作者
Arduino Duemilanove ATMEGA 328
買來就整塊Arduino控制板...沒有規格書(炸....
6#
發表於 2010-8-5 22:27:34 | 只看該作者
Dr.J 大大...
你是指買來沒有附送紙張資料嗎? 很環保阿..
全部的資料包含範例,電路圖,所有的資料都在網站 www.arduino.cc,
多到看不完 @@
7#
 樓主| 發表於 2010-8-5 22:55:28 | 只看該作者
抱歉我英文不好...用翻譯軟體...內容太奇怪...所以只能找你們幫忙...謝謝QQ
aroboto 該用戶已被刪除
8#
發表於 2010-8-6 17:49:49 | 只看該作者
http://www.atmel.com/dyn/resources/prod_documents/doc8025.pdf
規格書這裡有~~~@@

一般產品資訊裡都有@@
aroboto 該用戶已被刪除
9#
發表於 2010-8-6 18:24:04 | 只看該作者
http://arduino.cc/en/Reference/Constants

HIGH


The meaning of HIGH (in reference to a pin) is somewhat different depending on whether a pin is set to an INPUT or OUTPUT. When a pin is configured as an INPUT with pinMode, and read with digitalRead, the microcontroller will report HIGH if a voltage of 3 volts or more is present at the pin.


A pin may also be configured as an INPUT with pinMode, and subsequently made HIGH with digitalWrite, this will set the internal 20K pullup resistors, which will steer the input pin to a HIGH reading unless it is pulled LOW by external circuitry.


When a pin is configured to OUTPUT with pinMode, and set to HIGH with digitalWrite, the pin is at 5 volts. In this state it can source current, e.g. light an LED that is connected through a series resistor to ground, or to another pin configured as an output, and set to LOW.


數位輸入腳位: 輸入時3V以上 就會認定為 HIGH
數位輸出腳位: HIGH時 輸出5V
10#
 樓主| 發表於 2010-8-12 23:31:35 | 只看該作者
謝謝aroboto大大^^幫忙~
您需要登錄後才可以回帖 登錄 | 申請會員

本版積分規則

小黑屋|手機版|Archiver|機器人論壇 from 2005.07

GMT+8, 2024-5-15 14:42 , Processed in 0.217640 second(s), 9 queries , Apc On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回復 返回頂部 返回列表