Editor Version ×
recommended

Pro Edition

free

Brand new interactions and interfaces

Smooth support for design sizes of over 3W

devices or 10W pads

More rigorous design constraints, more

standardized processes

For enterprises, more professional users

Std Edition

Easy to use and quick to get started

The process supports design scales of 300

devices or 1000 pads

Supports simple circuit simulation

For students, teachers, creators

Ongoing

STD ATtiny13 TinyMoisture

ATtiny13 TinyMoisture

Project tags

License

CC-BY-SA 3.0

License: CC-BY-SA 3.0

Mode:

Mode

Editors' pick

Editors' pick

  • 1.6k
  • 0
  • 11
Update time: 2021-12-17 22:05:30
Creation time: 2021-01-08 20:53:02
Description

Description

# Overview TinyMoisture monitors the soil moisture of your plants and gives an alarm if you forget to water them again. - Firmware (Github): https://github.com/wagiminator/ATtiny13-TinyMoisture ![pic1.jpg](https://raw.githubusercontent.com/wagiminator/ATtiny13-TinyMoisture/main/documentation/TinyMoisture_pic1.jpg) ![pic2.jpg](https://raw.githubusercontent.com/wagiminator/ATtiny13-TinyMoisture/main/documentation/TinyMoisture_pic2.jpg) # Hardware TinyMoisture uses the resistance measurement method to determine the soil moisture. The two probes together with the substrate form a variable resistor. The more humid the soil, the better its conductivity and the lower the electrical resistance. Together with the 10k fixed resistor, a voltage divider is formed. This voltage can be measured by the ADC of the microcontroller. The circuit is based on the [SparkFun Soil Moisture Sensor](https://www.sparkfun.com/products/13322). ![wiring.png](https://raw.githubusercontent.com/wagiminator/ATtiny13-TinyMoisture/main/documentation/TinyMoisture_wiring.png) # Software ## Implementation The ATtiny13 spends most of its time in sleep mode. Every eight seconds it is woken up by the watchdog timer. It measures the moisture in the soil and compares it with the threshold value selected by the calibration potentiometer. If the soil is too dry, it emits a short acoustic signal via the buzzer and a short optical signal via the LED (ALARM). Then it goes back to sleep mode. The ATtiny can also be woken up by pressing the TEST button (pin change interrupt). An acoustic and optical signal is then output first so that the user can determine whether the battery is still supplying sufficient power. Then measurements of the soil moisture are carried out until the button is released again. In this way, the correct threshold value can be found and set by turning the poti. To avoid corrosion of the electrodes as far as possible, a voltage is only applied during the measurement. The ATtiny is clocked with only 128 kHz and all unused peripherals are switched off so that the power consumption is as low as possible. ```c // Main function int main(void) { // Reset watchdog timer resetWatchdog(); // do this first in case WDT fires // Setup pins DDRB = (1
Design Drawing

Design Drawing

schematic diagram
1 /
PCB
1 /
The preview image was not generated, please save it again in the editor.
ID Name Designator Footprint Quantity BOM_Supplier BOM_Supplier Part
1 MMBT3904 Q2 SOT-23_1 1 LCSC C20526
2 MLT-5030 BUZZER1 MLT-5030 1 LCSC C95297
3 1k R6,R5 0603 2 LCSC C21190
4 10k R2,R1 0603 2 LCSC C25804
5 100R R3 0603 1 LCSC C22775
6 CR2032-BS-6-1 B1 BATTERY-3 1 LCSC C70377
7 DRY LED1 LED0603 1 LCSC C2286
8 PROBE1 H1 HDR-M-2.54_1X1 1 LCSC C81276
9 PROBE2 H2 HDR-M-2.54_1X1 1 LCSC C81276
10 ATtiny13A U6 SOP-8_150MIL 1 LCSC C14075
11 TEST KEY1 KEY-3.0*6.0 1 LCSC C46491
12 100n C1 0603 1 LCSC C14663
13 10u C2 0603 1 LCSC C466781
14 10k R4 TC33X 1 LCSC C719176
15 MMBT3904 Q1 SOT-23-3 1 LCSC C20526

Unfold

Project Attachments

Project Attachments

Empty
Project Members

Project Members

Target complaint
Related Projects
Change a batch
Loading...

Comment

Add to album ×

Loading...

reminder ×

Do you need to add this project to the album?

服务时间

周一至周五 9:00~18:00
  • 0755 - 2382 4495
  • 153 6159 2675

服务时间

周一至周五 9:00~18:00
  • 立创EDA微信号

    easyeda

  • QQ交流群

    664186054

  • 立创EDA公众号

    lceda-cn