PMS7003 not sending any data to Arduino Nano 33 IoT

Hi! I am trying to build a small dust detection project with Arduino Nano 33 IoT and the PMS7003 Sensor. The problem is that the sensor is not sending any data to Arduino (Uart serial receiving small random numbers, that are just some noise probaby, cause when there's nothing plugged in, the results are the same).
Here is my build:


Here is the code:

#include "PMS.h"
#include <Arduino.h>
#include "wiring_private.h"
Uart mySerial (&sercom0, 5, 6, SERCOM_RX_PAD_1, UART_TX_PAD_0);
void SERCOM0_Handler()
{
  mySerial.IrqHandler();
}
PMS pms(mySerial);
PMS::DATA data2;

void setup() {
  mySerial.begin(9600);
  delay(2000);
  pinPeripheral(5, PIO_SERCOM_ALT);
  pinPeripheral(6, PIO_SERCOM_ALT);
  Serial.begin(9600);
  delay(2000);
  Serial.print("Testing the dust sensor");
  delay(2000);
  pms.activeMode();
  pms.wakeUp();
}

void loop() {
  pms.requestRead();
  Serial.print("PM 1 level  : ");
  Serial.println(data2.PM_AE_UG_1_0);
  Serial.print("PM 2,5 level: ");
  Serial.println(data2.PM_AE_UG_2_5);
  Serial.print("PM 10 level : ");
  Serial.println(data2.PM_AE_UG_10_0);
  Serial.print("READ        : ");
  Serial.println(mySerial.read());
  delay(2000);
}

And the results I am getting:

20:17:41.469 -> PM 1 level  : 0
20:17:41.469 -> PM 2,5 level: 0
20:17:41.469 -> PM 10 level : 0
20:17:41.469 -> READ        : 0
20:17:43.479 -> PM 1 level  : 0
20:17:43.479 -> PM 2,5 level: 0
20:17:43.479 -> PM 10 level : 0
20:17:43.479 -> READ        : 151
20:17:45.483 -> PM 1 level  : 0
20:17:45.483 -> PM 2,5 level: 0
20:17:45.483 -> PM 10 level : 0
20:17:45.483 -> READ        : 0

The sensor itself:


Edit:
I forgot to mention that the fan in the sensor is running!
I've read another post where someone just got a broken sensor and ordered another one. I assume that might be the case, but I thought I can ask before.

which pins of the PMS7003 are connected to which pins of the Nano (power supply and serial)

PMS7003's TX is connected to D5 on Arduino and RX to D6. Power supply is connected to 5V and mass to mass (external power).

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.