|
发表于 2018-9-7 09:39:38
|
显示全部楼层
OneWire 是否有固定的 baud rate 的?
Baudrate of DS18B20 : https://electronics.stackexchang ... baudrate-of-ds18b20
"Are you trying to interface it to a UART? The 1-wire protocol is significantly different and while I believe you can fudge it with a UART it's not the usual way you'd interface to one. – PeterJ Dec 30 "
OneWire 是怎样知道何时有回传
Refer to datasheet: "Communication to the DS18B20 is via a 1-Wire port. With the 1-Wire port, the memory and control
functions will not be available before the ROM function protocol has been established. The master must
first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4)
Skip ROM, or 5) Alarm Search.
.........
NOTES:
1. Temperature conversion takes up to 750 ms. After receiving the Convert T protocol, if the part does
not receive power from the VDD pin, the DQ line for the DS18B20 must be held high for at least a
period greater than tconv to provide power during the conversion process. As such, no other activity
may take place on the 1-Wire bus for at least this period after a Convert T command has been issued.
2. After receiving the Copy Scratchpad protocol, if the part does not receive power from the VDD pin, the
DQ line for the DS18B20 must be held high for at least 10 ms to provide power during the copy
process. As such, no other activity may take place on the 1-Wire bus for at least this period after a
Copy Scratchpad command has been issued.
3. All 3 bytes must be written before a reset is issued." |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?注册
x
|