element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • 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 & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • 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 Sensors Design Challenge
  • Challenges & Projects
  • Design Challenges
  • Summer of Sensors Design Challenge
  • More
  • Cancel
Summer of Sensors Design Challenge
Blog Summer of Sensors Design Challenge - In The Air Tonight – Blog #4 (Data Acquisition)
  • Blog
  • Forum
  • Documents
  • Design Challenge
  • Leaderboard
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Summer of Sensors Design Challenge to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: abhayrjoshi
  • Date Created: 11 Nov 2022 4:52 PM Date Created
  • Views 747 views
  • Likes 6 likes
  • Comments 6 comments
  • zmod4510
  • Summer of Sensors Design Challenge
  • renesas
  • In the Air Tonight
Related
Recommended

Summer of Sensors Design Challenge - In The Air Tonight – Blog #4 (Data Acquisition)

abhayrjoshi
abhayrjoshi
11 Nov 2022

Challenger - ZMOD4510 - Outdoor Air Quality Sensor

Hello element14 Family,

In order to correctly fit the board into the case properly, I first soldered pullup resistors onto the OLED display itself. After that, I assembled all the parts at my workstation.

From Left to Right:
Si7021 Temperature & Humidity Sensor, MAX4466 Electret Microphone (Set To 25x Gain), OLED FeatherWing, Feather M0 WiFi Board – with the ZMOD4510 in the background!

image

Once the SLA-printed structure was complete, I had to give it a nice alcohol bath to make sure no harmful resin remained on it. There is an excellent explainer available from the manufacturer if you want to know more about it.

 image

followed by a curing process of 30 minutes and breakout of the support structures (which is always fun and scary at the same timeWink)

image

Finally, I attached the thin wires onto the MAX4466 Electret Microphone and the Si7021 Temperature and Humidity Sensor at my workstation. I can now choose a Feather M0 LoRa board or a Feather M0 WiFi board to use for the sample.

image

Color Code: RED – PWR, BLACK – GND, YELLOW – SCL, GREEN - SDA

I just decided to go ahead with the WiFi board for now to maybe try and demonstrate the cloud features. Since I2C is a shared bus, I connected the PWR, GND, SCL and SDA from the Si7021 and ZMOD4510 together, along with the PWR and GND from the MAX4466 Electret Microphone. Then, I connected the common PWR wire to 3.3V, the GND wire to GND, the SCL wire to Pin 21 and SDA wire to Pin 20 on the Feather M0. Finally, I connected the OUT of MAX4466 to an analog pin (A5) and inserted the OLED feather wing on to the base pins.

To perhaps try and demonstrate the cloud functionalities, I've just decided to move forward with the WiFi board for the time being. I linked the PWR, GND, SCL, and SDA from the Si7021, ZMOD4510, as well as the PWR and GND from the MAX4466 Electret Microphone together since I2C is a shared bus.

After that, I wired the Feather M0 by connecting the common PWR wire to 3.3V, the GND wire to GND, the SCL wire to Pin 21, and the SDA wire to Pin 20. Finally, I attached the OLED feather wing to the base pins, while connecting the MAX4466's OUT pin to analog pin (A5) on the Feather M0.

The final wired chump looks something like this:

image

Now, I tried to test the access to the sensor using the OAQ 1st Gen Sensor example, however, I was unable to see any logs on the serial console. I noticed that there was no particular logging information initially available and I added additional logs, which were also not displayed on the console.

I then tried to use the OAQ 1st Gen Sensor example to verify access to the sensor, but I was unable to view any logs on the serial console. I added more logs after realizing that there was initially no specific logging information accessible, however those logs were also not shown on the console.

However, after flashing, the OAQ 2nd Gen Sensor sample worked perfectly! I therefore asked the Renesas Support Team for their opinion, albeit their response is pretty understandable:

image

As I already have the Si7021 attached, I can move on to the OAQ 2nd Gen example for the time being (since it is also an example of ultra low power measurement) and implement algorithmic compensation using the sensor's recorded values for temperature and humidity.

Then, using the Adafruit SSD1306 example as a model, I created some code to test the basic functionality:

/* Includes For Adafruit OLED Featherwing */
#include <SPI.h>
#include <Wire.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>

/* OLED Display Width (Pixels) */
#define SCREEN_WIDTH   128
/* OLED Display Heighth (Pixels) */
#define SCREEN_HEIGHT  32
/* OLED Reset Pin (-1 If Sharing Arduino Reset Pin) */
#define OLED_RESET     -1 
/* OLED I2C Address (Datasheet: 0x3C for 128x32) */
#define SCREEN_ADDRESS 0x3C 

/* OLED Display */
Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET);

void setup()
{
    /* Initialize The Serial Port */
    Serial.begin(9600);

    /* Initialize The OLED Display */
    /* SSD1306_SWITCHCAPVCC - Generate Display Voltage From 3.3V Internally */
    if(!display.begin(SSD1306_SWITCHCAPVCC, SCREEN_ADDRESS))
    {
        Serial.println(F("SSD1306 OLED Display Error"));
        for(;;); // Don't Proceed, Loop Forever
    }
    
    display.clearDisplay();
    display.setTextSize(1);      // Normal 1:1 Pixel Scale
    display.setTextColor(SSD1306_WHITE); // Draw White Text
    display.setCursor(0, 0);     // Start At Top-left Corner
    display.cp437(true);         // Use Full 256 Char 'Code Page 437' Font

    /* Print A Welcome Message */
    display.println(F("Welcome To"));
    display.println(F("element14"));
    display.println(F("Summer of Sensors"));
    display.println(F("Design Challenge!\n"));
    display.display();
    delay(5000);
    display.clearDisplay();
    display.setTextColor(SSD1306_WHITE);
    display.setCursor(0, 10);
    display.println(F("In The Air Tonight..."));
    display.display();
    delay(100);
}

void loop() {
}

image image

Next, I will pack the components into the case integrate a display which provides information on the current environment and exposure level.

Until then, Happy Cleaning!

image

Next Blog Series: Summer of Sensors Design Challenge - In The Air Tonight – Blog #5 (System Integration)

  • Sign in to reply
  • abhayrjoshi
    abhayrjoshi over 2 years ago in reply to dougw

    About 5 and a half hours - with the layer finesse set to adaptive in PreForm!

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • dougw
    dougw over 2 years ago

    How long did the SLA print take?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • abhayrjoshi
    abhayrjoshi over 2 years ago in reply to ntewinkel

    Yes, true! It works well for the dynamically changing scenarios and location - however, I did want to see what is the delta between the 1st Gen and the 2nd Gen. I'll fix it later around the Christmas break ;)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • abhayrjoshi
    abhayrjoshi over 2 years ago in reply to rsjawale24

    Thank you for reading, rsjawale24 :)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • ntewinkel
    ntewinkel over 2 years ago

    Strange that the 1st Gen sample would fail?
    I think the 2nd Gen algorithm will be better for your project anyway - the results are MUCH quicker. I think the 1st gen only samples like once per hour.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
>
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