Skip to content

RFID Moisture Updates

mattguo5 edited this page Jan 28, 2020 · 26 revisions

RFID Moisture Updates

post newest updates at the top and have dividing lines between them:


Jan 28, 2020 - RFID Module Read and Write with Loom Libraries

Author: Matt Guo

  • Loom Libraries for SD and RTC have been added to the RFID Read
Show More Description

The RFID Module supports the OPEnS Hypnos Boards for SD logging and RTC functionality for the constant tag reading functionality. Using the SparkFun RFID Module Library and support, the RFID Reader can now fully display the RSSI, Moisture Value, Frequency of communication, and the customizable EPC of the tag. Below is a picture on the serial monitor showing these values.

The RFID Moisture Feather functionality has now also expanded to writing customizable EPCs for individual tags, using the Feather_Write_EPC Feather M0 sketch. These customizable EPCs can be written directly on the sketch here:

With the Serial Monitor prompts showing as follows:

These combine for great flexibility on how the EPCs can be identified by the reader, and with the Loom module integration to the Constant Read sketch, can be used to log moisture data onto a local SD card, associating the moisture value to the specific, individual tags.

The data is saved onto a .csv file on the SD card, pulling and saving data from the RTC for time and date, EPC header, Moisture value, Frequency that was used for communication, and the RSSI of the signal. Below is a figure of the logged data.

Future Revisions:

  • Putting the entire EPC string and saving that into the .csv file instead of simply the header.

Dec 5, 2019 - Unified PCB for RFID Module and Feather M0

Author: Matt Guo

  • Created a working unified PCB for the RFID Module and Feather M0
Show More Description

A unified PCB that interfaces the RFID Module to the Feather M0 has been designed, soldered, and tested. This PCB contains necessary routing from the TX and RX lines (Pins 11 and 10 on the Feather M0) to the soft-serial port on the SparkFun Simultaneous RFID Reader (Pins 2 and 3 on the RFID Module). Two SN74AHCT125N Logic Level shifters are used on this board, one that level shifts from 3.3V to 5V for the RFID Module, and the other from 5V to 3.3V for the Feather M0. Below is a figure of the board file for the interface PCB.

The top layer of the board lies the 5V plane from the USB pin of the Feather M0. This is what is used to power the 5V level shifter and the RFID Module. The bottom of the board contains the common ground plane. The "Analog In" ports of the RFID Module hookup, which is based off of the same topology as an Arduino UNO, is connected to GPIO A0 - A5 of the Feather M0, should additional GPIO be needed for this design.

The interface board sandwiches the Feather M0 and the RFID Module, with the RFID Module on the bottom and the Feather M0 on the top for ease of access. This is best illustrated in the pictures below.

The red bottom board is the RFID Module, and two board on top of the interface board is the Feather M0 and the Adafruit Relay Switch used to control the irrigation system.

This board was also tested using the Arduino IDE and the revised Feather M0 skeleton code detailed in the previous update log. The 3.3V TX line from the Feather M0 is logic level shifted up to 5V for the RX line of the RFID Module, and the 5V TX of the RFID Module is then logic level shifted down to 3.3V for the Feather M0. The figure below illustrates proper initialization communication between the two.

Future Revisions

  • A long header connection is mandatory between the Interface Board and the RFID Module. While not a future PCB revision, additional units to be soldered should take this into account.
  • A silkscreen message for the Capacitor value size, which should be 0.1uF 0805, could be written on the top layer of the board for ease of soldering.
  • Better Thermal relief connections of the GND pins of the SN74AHCT125N should be added for ease of soldering.
  • Indicator LEDs from the 3.3V and 5V power rails of this board could be added to show proper interfacing of the Interface Board.

Resources


Nov 21, 2019 - Deployment of Soil Moisture Dataloggers at Peoria Gardens

Author: Matt Guo & Max Chu

  • Adafruit Soil Moisture Sensors deployed at Peoria Gardens
Show More Description

The Soil Moisture Dataloggers passed the OPEnS lab QA test, deeming it worthy to be deployed at Peoria Gardens. Three Dataloggers were deployed, with 5 Adafruit Capacitive Soil Moisture Sensors attached to each of the Dataloggers, bringing a total of 15 different sensors testing the moisture level of different soils. Each of the Dataloggers uses one Feather M0 with a multiplexer running on Loom and an OPEnS Hypnos Board to log the moisture value and the timestamp of the measurement. A 6 cell battery is used to power these Dataloggers, capable of a runtime of 10 days per single charge.

Below is the setup of a Datalogger:

The PORT number, start time, plant, and box numbers are listed below.

BOX 1 - Measuring Japanese Holly (start time: 2:14pm 11/21/2019)

  • Furthest Sensor: PORT7
  • 2nd Furthest Sensor: PORT5
  • 3rd Furthest Sensor: PORT4
  • 4th Furthest Sensor: PORT2
  • Closest Sensor: PORT0

BOX2 - Measuring Pansy Fizzle Sizzle Mix (start time: 2:04pm 11/21/2019)

  • Furthest Sensor: PORT0
  • 2nd Furthest Sensor: PORT1
  • 3rd Furthest Sensor: PORT4
  • 4th Furthest Sensor: PORT6
  • Closest Sensor: PORT7

BOX3 - Measuring Primula (start time: 2:24pm 11/21/2019)

  • Furthest Sensor: PORT0
  • 2nd Furthest Sensor: PORT1
  • 3rd Furthest Sensor: PORT4
  • 4th Furthest Sensor: PORT6
  • Closest Sensor: PORT7

Nov 12, 2019 - Feather M0 Port of Sparkfun RFID code

Author: Matt Guo

  • Successful port of Sparkfun RFID constant read to Feather M0
Show More

Description

A successful port of the Sparkfun RFID constant read Arduino code to the Feather M0 has been made. To make this port successful, SN74AHCT125N logic level shifters were needed. These logic level shifters were used over the sparkfun breakout for their faster slew rates, required for high baud rate for the UART transmission. The SN74AHCT125N is a one-way logic level shifter - it can only go from 3.3V to 5V, or vice versa. The output logic level is dictated by the Vcc voltage. Two of these shifters were used for the design, one to transition from 3.3V to 5V, and the other going from 5V to 3.3V.

Below is the current setup for the RFID Soil Moisture Sensor Hardware:

The original Sparkfun RFID constant read code for the Arduino Uno utilizes the softSerial library for Tx and Rx pins on GPIO 2 and 3. When porting over to the Feather M0, this softSerial library is not available, thus alternatives were needed. Adapted from Adafruit's website on 'Adapting Uno Sketches to the M0', PIO_SERCOM's pinPeripheral was initialized on the code to the Feather M0's pins 10 and 11 for Tx and Rx. This allows the creation of a new serial, arbitrarily called as rfidSerial, to be used whenever UART communication is needed in the sketch.

Error's occurred whenever the rfidSerial was closed and reinitialized to actively change the baud rate, which was initially handled in the setupNano() function from the Constant Read code. This was avoided by initializing the rfidSerial to a set baud rate of 115200 and leaving the communication handling to 115200.

References:

Clone this wiki locally