element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Summer of Green Tech Design Challenge
  • Challenges & Projects
  • Design Challenges
  • Summer of Green Tech Design Challenge
  • More
  • Cancel
Summer of Green Tech Design Challenge
Blog Blog #3: Testing of Individual Components
  • Blog
  • Forum
  • Documents
  • Leaderboard
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Summer of Green Tech Design Challenge to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: paulcastor30
  • Date Created: 19 Oct 2023 2:21 AM Date Created
  • Views 402 views
  • Likes 2 likes
  • Comments 0 comments
  • rgb led
  • mq135
  • buzzer
  • Grove DHT20
  • samd21
Related
Recommended

Blog #3: Testing of Individual Components

paulcastor30
paulcastor30
19 Oct 2023

This blog assumes that you already have the required materials discussed in Blog #2: Gathering the Essentials: Materials for Your Classroom Indoor Air Quality Monitoring Project. Below are the steps for testing the individual components together with the SAMD21 Microcontroller and Arduino IDE.

I. Grove - Temperature & Humidity Sensor (DHT20)

  • Prepare your Grove Temperature and Humidity DHT20 Sensor.
  • Connect your Grove Temperature and Humidity DHT20 Sensor to the SAMD21 Microcontroller pins. We have four pins that need to be connected; 5V, GND, SDA, and SCL.
  • Connect your Seeeduino XIAO SAMD21 Microcontroller to your PC or Laptop via a USB Type-C Cable.
  • Download the Seeed DHT library from Github.
  • Refer to "How to install library to install library" for Arduino.
  • Open the “DHTtester” example via the path: File --> Examples --> Grove_Humidity_Temperature_Sensor-master --> DHTtester. Through this demo, we can read the temperature and relative humidity information of the environment.
  • Upload the demo. If you do not know how to upload the code, please check how to upload the code.
  • Open the Serial Monitor of Arduino IDE by clicking Tool-> Serial Monitor. Or tap the CTRL+SHIFT+M keyboard keys at the same time. if everything goes well, you will get the temperature and humidity readings.

II. RGB LED

  • Prepare your RGB LED Sensor.
  • Connect your RGB LED to the SAMD21 Microcontroller pins. We have four pins that need to be connected; GND, R, G, and B. In my case, the R, G, and B pins are digital pins which are connected to 10, 9, and 8 digital pins of SAMD21 MCU.
  • Connect your Seeeduino XIAO SAMD21 Microcontroller to your PC or Laptop via a USB Type-C Cable.
  • Download the Seeed DHT library from Github.
  • Refer to "How to install library to install library" for Arduino.
  • Open the “ Flash” example via the path: File --> Examples --> RGB --> Flash. Through this demo, we can make our RGB flash like a regular LED flasher circuit.
  • Upload the demo. If you do not know how to upload the code, please check how to upload the code.

III. Buzzer

  • Prepare your Buzzer Sensor.
  • Connect your Buzzer to the SAMD21 Microcontroller pins. We have three pins that need to be connected; GND, 5V, and OUT. In my case, the OUT pin is a digital pin which is connected to digital pin 3 of SAMD21 MCU.
  • Connect your Seeeduino XIAO SAMD21 Microcontroller to your PC or Laptop via a USB Type-C Cable.
  • Open the “ Blink” example via the path: File --> Examples --> Basics--> Blink. Through this demo, we can make our Buzzer on and off like every second.
  • Upload the demo. If you do not know how to upload the code, please check how to upload the code.

IV. MQ135 Gas Sensor

  • Prepare your MQ135 Gas Sensor.
  • Connect your MQ135 Gas Sensor to the SAMD21 Microcontroller pins. We have three pins that need to be connected; GND, 5V, and OUT. In my case, the OUT pin is an analog pin which is connected to analog pin A1 of SAMD21 MCU.
  • Connect your Seeeduino XIAO SAMD21 Microcontroller to your PC or Laptop via a USB Type-C Cable.
  • Download the MQ135 library from Github.
  • Refer to "How to install library to install library" for Arduino.
  • Open the “MQ135” example via the path: File --> Examples --> MQ135 --> MQ135. Through this demo, we can read the carbon dioxide information of the environment.
  • Upload the demo. If you do not know how to upload the code, please check how to upload the code.
  • Open the Serial Monitor of Arduino IDE by clicking Tool-> Serial Monitor. Or tap the CTRL+SHIFT+M keyboard keys at the same time. If everything goes well, you will get the carbon dioxide readings.
  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube