# Environment Temperature and Humidity Module

![](https://kittenbothk.readthedocs.io/en/latest/_images/05_05.png)

This module is used to get the temperature and humidity of the nearby environment. It can be used with the Soil Moisture or Water Level Sensors.

### Details

![](https://kittenbothk-eng.readthedocs.io/en/latest/_images/05_041.png)

### Specifications

* Voltage: 3V-5V
* Dimensions: 56mm X 24mm X 19mm
* Connector: 4Pin PH2.0, 3Pin PH2.0
* Temperature Range: 0-50°C, Accuracy ±2°C
* Humidity Range: 20-90%RH, Accuracy ±5%RH
* Sensor Value Return Range: 0-1023

### Precautions

* This module cannot be placed underwater, doing so would cause a short circuit.

### Connecting the module

Connect the Environment Module to Armourbit with a 4Pin cable.

![](https://kittenbothk.readthedocs.io/en/latest/_images/env_wire.png)

### MakeCode Coding Tutorial

![](https://kittenbothk.readthedocs.io/en/latest/_images/mcbanner13.png)

#### Load Powerbrick Extension:

#### Search "Powerbrick" in the search bar.

![](https://kittenbothk.readthedocs.io/en/latest/_images/powerbrick_search.png)

#### Or search the following link.

<https://github.com/KittenBot/pxt-powerbrick>

#### Environment Module Blocks:

![](https://kittenbothk-eng.readthedocs.io/en/latest/_images/environmentblocks1.png)

#### Reading the temperature

{% embed url="<https://makecode.microbit.org/_7iaJkbDr3H0J>" %}

[Sample Program](https://makecode.microbit.org/_7iaJkbDr3H0J)

#### 相對濕度測量編程

{% embed url="<https://makecode.microbit.org/_iwp6isU4hLRR>" %}

[Sample Program](https://makecode.microbit.org/_iwp6isU4hLRR)

#### Makecode Tutorial Video

{% embed url="<https://www.youtube.com/watch?v=ilXSpFd86DQ>" %}

### Extension Version and Updates

There may be updates to extensions periodically, please refer to the following link to update/downgrade your extension.

[MakeCode Extension Update](https://sharinghub-eng.kittenbot.hk/programming-platforms/makecode-tutorial/makecode-extension-updates)

### KittenBlock Coding Tutorial

![](https://kittenbothk-eng.readthedocs.io/en/latest/_images/kbbanner.png)

#### 加Load Powerbrick Extension

Select Powerbrick from the hardware column.

![](https://kittenbothk.readthedocs.io/en/latest/_images/addextension1.png)

#### Environment Module Blocks

![](https://kittenbothk.readthedocs.io/en/latest/_images/kbenvblocks.png)

#### Reading the temperature

![](https://kittenbothk-eng.readthedocs.io/en/latest/_images/kbtemp1.png)

[Sample Program](https://bit.ly/PowerbrickM1_01sb3)

#### Reading the relative humidity

![](https://kittenbothk.readthedocs.io/en/latest/_images/kbhumid.png)

[Sample Program](https://bit.ly/PowerbrickM1_01sb3)

### FAQ

1：Why is there no reaction when I click the blocks?

Make sure you have connected the Micro:bit correctly and flash the firmware again.
