Skip to content

Commit ce1a949

Browse files
committed
doc: add absolute url to be able to generate cargo doc
1 parent cee62d0 commit ce1a949

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ fn main() -> ! {
114114
}
115115
```
116116

117-
![running](/docs/example_esp32_dht_running.png)
117+
![running](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/example_esp32_dht_running.png)
118118

119119

120120
## Implementation Specification
@@ -124,8 +124,8 @@ We have gathered all the information you need to understand in order to implemen
124124
The DHT20 differs from the DHT11 and DHT22 because it uses the I2C communication protocol, while both the DHT11 and DHT22 rely on a single-wire signal for data transmission.
125125

126126

127-
- [DHT11 and DHT22 Documentation](docs/dht11_22.md)
128-
- [DHT20 Documentation](docs/dht20.md)
127+
- [DHT11 and DHT22 Documentation](https://github.com/rust-dd/embedded-dht-rs/blob/main/docs/dht11_22.md)
128+
- [DHT20 Documentation](https://github.com/rust-dd/embedded-dht-rs/blob/main/docs/dht20.md)
129129

130130

131131

@@ -142,5 +142,5 @@ The DHT20 differs from the DHT11 and DHT22 because it uses the I2C communication
142142

143143
## Example Schematic
144144

145-
| ![Schematic](./docs/example_esp32_schematic.png) [Click to zoom](./docs/example_esp32_schematic.png) | ![Running](./docs/example_esp32_wired.jpg) [Click to zoom](./docs/example_esp32_wired.jpg) |
145+
| ![Schematic](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/example_esp32_schematic.png) [Click to zoom](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/example_esp32_schematic.png) | ![Running](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/example_esp32_wired.jpg) [Click to zoom](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/example_esp32_wired.jpg) |
146146
|:--:|:--:|

docs/dht11_22.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# DHT11/DHT22
22

3-
![steps](/docs/dht11_22_steps.png)
3+
![steps](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht11_22_steps.png)
44

55
## Step 1
66

@@ -10,20 +10,20 @@ After powering on the DHT11/DHT22 (once powered, allow 1 second to pass during w
1010

1111
The microprocessor's I/O pin is set to output mode and pulled low, holding this state for at least 18 milliseconds. Then, the microprocessor's I/O is switched to input mode. Due to the pull-up resistor, the microprocessor’s I/O line and the DHT11/DHT22 DATA line will remain high, waiting for the DHT11/DHT22 to respond with a signal, as illustrated below:
1212

13-
![step2](/docs/dht11_22_step2.png)
13+
![step2](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht11_22_step2.png)
1414

1515

1616
## Step 3
1717

1818
The DHT11/DHT22’s DATA pin detects an external signal and goes low, indicating that it is waiting for the external signal to complete. Once the signal ends, the DHT11/DHT22’s DATA pin switches to output mode, producing a low signal for 80 microseconds as a response. This is followed by an 80-microsecond high signal, notifying the microprocessor that the sensor is ready to transmit data. At this point, the microprocessor's I/O pin, still in input mode, detects the low signal from the DHT11/DHT22 (indicating the response) and then waits for the 80-microsecond high signal to start receiving data. The sequence of signal transmission is illustrated below:
1919

20-
![step3](/docs/dht11_22_step3.png)
20+
![step3](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht11_22_step3.png)
2121

2222
## Step 4
2323

2424
The DHT11/DHT22 outputs 40 bits of data through the DATA pin, and the microprocessor receives these 40 data bits. The format for a data bit "0" consists of a low level lasting 50 microseconds, followed by a high level lasting 26-28 microseconds, depending on changes in the I/O level. For a data bit "1," the format includes a low level of 50 microseconds followed by a high level lasting up to 70 microseconds. The signal formats for data bits "0" and "1" are shown below.
2525

26-
![step4](/docs/dht11_22_step4.png)
26+
![step4](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht11_22_step4.png)
2727

2828
## End signal
2929

docs/dht20.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# DHT20
22

3-
![steps](/docs/dht20_steps.png)
3+
![steps](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht20_steps.png)
44

55
- SDA = Serial Data Line
66
- SCL = Serial Clock Line
@@ -16,15 +16,15 @@ After powering on, wait at least 100ms. Before reading the temperature and humid
1616
## Step 2
1717
Wait for 10ms before sending the 0xAC command to trigger the measurement. The command consists of two bytes: the first byte is 0x33 and the second byte is 0x00.
1818

19-
![step4](/docs/dht20_step2.png)
19+
![step4](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht20_step2.png)
2020

2121
## Step 3
2222
Wait for 80ms for the measurement to complete. If Bit [7] of the status word is 0, the measurement is done, and you can proceed to read six bytes continuously; if not, continue waiting.
2323

2424
## Step 4
2525
After receiving the six bytes, the following byte is the CRC check data, which can be read if needed. If the receiver requires CRC validation, an ACK is sent after the sixth byte is received; otherwise, send a NACK to terminate. The initial CRC value is 0xFF, and the CRC8 check uses the polynomial: CRC [7:0] = 1 + X^4 + X^5 + X^8.
2626

27-
![step4](/docs/dht20_step4.png)
27+
![step4](https://raw.githubusercontent.com/rust-dd/embedded-dht-rs/refs/heads/main/docs/dht20_step4.png)
2828

2929
## Step 5
3030
Compute the temperature and humidity values.

0 commit comments

Comments
 (0)