Project Journal for Austin Rejman

=============== Week 15: =================

Entry 7: -----------------------------------------------------------------

Date: April 25th
Start Time: 12:40pm
Duration: 3.75 hours

Project Demo

Entry 6: -----------------------------------------------------------------

Date: April 24th
Start Time: 6:20pm
Duration: 7 hours

Entry 5: -----------------------------------------------------------------

Date: April 24th
Start Time: 12:20pm
Duration: 5 hours

Entry 4: -----------------------------------------------------------------

Date: April 23rd
Start Time: 9:00pm
Duration: 2 hours

Worked on senior design report A13

Entry 3: -----------------------------------------------------------------

Date: April 22nd
Start Time: 2:00pm
Duration: 2 hours

Hot glued lock-in connecting wires to stabalize the connection. Soldered on remaining lock-in connecting headers for remaining hardware. Connected remaining hardware to PCB headers. Tested the stepper motor and it works. Now need someone to test the other hardware with new code to put readings onto LCD screen.

Hardware Connected

Entry 2: -----------------------------------------------------------------

Date: April 21st
Start Time: 3:30pm
Duration: 0.25 hours

Soldered and assembled our new LCD screen for the purpose of being able to prototype the SD card reader.

Entry 1: -----------------------------------------------------------------

Date: April 19th
Start Time: 9:00pm
Duration: 3 hours

Wrote the User Manual.

=============== Week 14: =================

Entry 4: -----------------------------------------------------------------

Date: April 18th
Start Time: 2:25pm
Duration: 4 hours

While I was gone, our LCD somehow broke after incorrect connections were made. A TA helped me to solder a new board from scratch, this time using different headers so that the lock in feature can be used instead of soldering directly to the header pins. The new board is correctly able to turn on the debugging LED and our other screen works on the new PCB. While trying to determine the issue with why the keypad won't work, discovered that the diodes we're using have around a 1M ohm resistance so on the new PCB I decided to not solder them on since the keypad should still be able to be read without the diodes. After I receive confirmation that the keypad works from someone pushing code to it, I will begin soldering on the parts needed for our other hardware like the temperature probe, water level sensor and motor driver.

Newest PCB
Most Recent Revision of Soldering PCB

Entry 3: -----------------------------------------------------------------

Date: April 17th
Start Time: 11:55am
Duration: 4.5 hours

Assembled the water filter to ensure the water level sensor would fit in the filter and that the filter itself worked. Resoldered the buck converters to the PCB by using the hot air gun in lab to remove the converter's lock in headers and then soldering them back onto the new PCB while still having the cables previously attached. With the power system fully operational and the ability to communicate with the micro, soldered on the lock in conncecters for the LCD screen. Made the 1 to 1 connections between the header and the LCD screen by once again soldering the wires directly to the header, with the only conncection having different names on each end was the rightmost 3.3V supply going to the "Lite" pin of the LCD to power the backlight of the screen. The LCD screen was able to turn on and be able to turn blue with code pushed to it and still worked while being power cycled while disconnected from the computer. Next soldered on the previously used diodes with the same orientation from last time, as well as the 8 pin header and I/O expander chip in order to test the keypad. Next will wait to see if keypad works once correct code is written for it and will then start soldering on other hardware like the motor driver.

Buck Soldered
Buck Converters Soldered to new PCB

Soldered Continued
Second Step of Soldering onto PCB

LCD/Keypad Soldered
Current Progress of Soldering LCD and Keypad hardware onto PCB

Filter
Assembled Filter

Entry 2: -----------------------------------------------------------------

Date: April 16th
Start Time: 2:30pm
Duration: 3.25 hours

Got micro xrayed, found bridge and slim soldering depicted below so fixed those issues but micro still is unable to be detected by the STLink. Took TA's advice to start over with the micro on a new board, which ended up finally working. Was able to turn on PB5 debugging LED. I suspect since I had soldered on and desoldered off the micro so many times that maybe the interal hardware of the board itself had been damaged. Desoldered lock in connecters from old board with hot air gun to be reused on new board. With the completed ability to communicate with micro on PCB, next will have to start adding hardware to PCB.

XRAY Zoom
Zoomed in XRAY taken of Soldering job on microcontroller

Debug LED
Debugging LED Turned On

Entry 1: -----------------------------------------------------------------

Date: April 15th
Start Time: 11:45am
Duration: 4.75 hours

Soldered on lock in connecters, 0805 diodes, and the large 100uF capacitor (C2) for the motor driver. Also set up buck converters to output 5V from 12V input and output 3.3V from 5V input by using the left potentiometer on the converters board previously mentioned in previous weeks. Soldered said buck converters to lock in connectors. Our header pins are too large for our wire heads to fit around them so I had to solder directly onto the pins but the conncection is stable and works. Desoldered micro in ECE shop using hot air gun after struggling to desolder micro chip using normal copper wire. Couple pads were ripped off the PCB but they were unused pads so shouldn't be an issue. Drag soldered on a new micro to the PCB. Will have to get soldering job on micro x-rayed tomorrow since no one certified is left in the ECE shop today. Reference: https://services.taiwansemi.com/storage/resources/datasheet/TS4148%20SERIES_A2301.pdf

Diode Orientation
Correct Orientation of Cathode on 0805 Diodes

Solder Progress
Current Progress on Soldering PCB

Diode Zoom
Zoom in on soldered on diodes with orientation

=============== Week 13: =================

Entry 4: -----------------------------------------------------------------

Date: April 9th
Start Time: 2:30pm
Duration: 5 hours

Soldered on header for I/O expander and the reset button for the microcontroller. Wrote short code program to turn on debugging LED connected to PB5 in STM32CubeIDE with new folder for the chip rather than the dev board, where the STLink was not able to be found. Had to update STLink to newest version and then discovered our PCB design for the program header is not the same as the STLink so rerouted the header with extension wires to match the outline on the STLink. Still not able to get microcontroller to be detected by the STLink so ran through may debugging techniques with TA's where we got the microcontroller X-rayed at the ECE shop and got verification that the microcontroller was soldered correctly. Checked the STM32F103 datasheet for the schematic of the decoupling capacitors and found that we had used 10k resistors instead of the recommended 100k so I desoldered and replaced the resistors to the correct value but this did not change our issue. The heartbeat LEDs light up correctly so the power being supplied isn't a problem. Went over the reset circuitry of our micro and determined that shouldn't be the issue. There is an unexpected small amount of voltage being supplied to the debugging LED connected to PB4 which we are unsure why that is happening. Now figuring the microcontroller must be fried, maybe from pressing down the soldering iron too hard or for too long while drag soldering, or maybe that since we were using the power supply cords instead of our buck converters without them being soldered down that maybe it was ungrounded for a moment and fried the micro, not entirely sure but new chips have been ordered and will have to wait to replace ours until they're delivered. There is also concern that our PCB design is wrong and that we will have to reroute a lot of our GPIO connections since SPI is only available on certain pins. Initially talking about having to etch on the board and flywire the SPI signals to PB3,4, and 5 which 4 and 5 are debugging LEDs and would be hard to flywire without shorting the board. Other option is using the GPIO pins currently used in the motor driver and SD card reader which will require a lot of repositioning of our hardware so will have to continue working on how to reroute all the connections to the micro so that the display can access the specific SPI interfacing GPIO pins that are already in use.

STLink Error
Error Description of microcontroller not being detected by STLink


Entry 3: -----------------------------------------------------------------

Date: April 8th
Start Time: 5:30pm
Duration: 2 hours

Researched the correct orientation for the 0805 LED diodes shown below where the short perpendicular extension is the direction of the cathode pointing to ground. Circle of microntroller depicts where pin 1 is located to the left of it, in line with the arrow on our PCB. Soldered on final resistors and capacitors, soldered on debugging and heartbeat LEDs, 10 pin programming header and drag soldered on microcontroller after having TA show me how. Have now made significant progress to catch up in soldering our PCB together. Waiting to solder on I/O expander and motor driver until we know they work on the breadboard. Next will begin testing if the microcontroller works by trying to turn on debugging LED.
LED Orientation
LED Diode Orientation

Current Soldering Progress
Current progress on PCB microcontroller soldering

Entry 2: -----------------------------------------------------------------

Date: April 8th
Start Time: 1:00pm
Duration: 3.5 hours

Checked for any direct shorts between all power and ground pads by probing with the digital multimeter and found no issues. Began soldering the power supply parts onto our board starting with the barrel jack and resistors. Ran into a problem where when soldering, some of the heartbeat LEDs are so close to the resistor that the flux would reach the LED's soldering pad and when trying to remove the solder that would wind up on the wrong pad with a brush, the pad was ripped off shown below. Was forced to restart the soldering process on a new board and to prevent this from happening again, will ensure flux is bound strictly to the pads being soldering and won't use the brush again to try to remove solder. Will continue soldering after lecture.

Ripped off Solder Pad
Solder pad ripped off of PCB
Current Soldering Progress
Current progress on power supply soldering

Entry 1: -----------------------------------------------------------------

Date: April 7th
Start Time: 2:30pm
Duration: 1.5 hours

PCB board was finally delivered, performed a visual inspection and found no discrepencies throughout our board. Checked to see if all our parts would fit through the through holes on our board and found that all the 3.50mm vertical headers we had collected wouldn't fit into our PCB. After looking through the headers available in the lab decided that we'll have to order new ones directly to fit our board. Tomorrow will begin checking the board for shorts and will begin soldering.
Sizing Verification
Sizing verification of parts on board

=============== Week 12: =================

Entry 3: -----------------------------------------------------------------

Date: April 2nd
Start Time: 2:30pm
Duration: 4.5 hours

Soldered on 20 pin header to our LCD display on the left side which is the side useed to interface the display using SPI. Used rosin core solder and the pen no-clean flux. Using the reference below, closed the IM1, IM2, and IM3 gates in order to use SPI interfacing on the display (which is also a note printed on the display). Wired the LCD display to the microcontroller according to our KiCAD PCB design, which the only pins we plan to use are the CD and CCS pins for the SD card as well as Lite,RST,D/C,CS,MOSI,CLK,3-5V, and GND. There is some concern we might end up needing the MISO pin as well but in the case that we need to, we can always flywire the pin to our PCB's microcontroller.
Began gathering the needed parts to solder onto our PCB which include the following 0805 parts: 1x0Ω, 8x620Ω, 1x1kΩ, 1x2kΩ, 2x2.2kΩ, 1x4.7kΩ, 2x10kΩ resistors, 1x0.01uF, 7x0.1uF, 1x1uF, 1x4.7uF capacitors, and a small ferrite bead. The parts we coulnd't find in lab and are ordering are a 100uF capacitor, 8 diodes, and 8 LEDS which are all still 0805. I also got a reset button for our micro. We are also ordering a barrel jack and another buck converter.
We should now be fully prepared and ready to hit the ground running once our PCB is delivered to quickly begin the soldering process, so hopefully our PCB is delivered soon so I can start soldering.
Reference: https://learn.adafruit.com/adafruit-2-8-and-3-2-color-tft-touchscreen-breakout-v2/spi-wiring-and-test

Soldered LCD Display
Header and IMs Soldered on LCD Display
Closed IMs for SPI
Soldered closed IMs for SPI interfacing on LCD display
Gathered 0805 Parts
Gathered 0805 parts for when PCB is delivered

Entry 2: -----------------------------------------------------------------

Date: March 31st
Start Time: 2:30pm
Duration: 1 hour

Practiced soldering parts onto spare PCB's in preperation for when our PCB gets delivered. Practiced by soldering on 0805 resistors since many of the parts we'll be using on our PCB are 0805, and practiced soldering on different headers as well.

Entry 1: -----------------------------------------------------------------

Date: March 29th
Start Time: 8:45pm
Duration: 0.75 hour

Went into lab to meet with Shivam to order our PCB. Created a JLCPCB account to order the PCB. Created the gerber files by referencing https://forum.kicad.info/t/9-0-gerber-file-generation-changes-and-jlcpcb/59155 since our KiCAD file uses KiCAD9 which defers from previous KiCAD versions.

=============== Week 11: =================

Entry 2: -----------------------------------------------------------------

Date: March 26th
Start Time: 3:25pm
Duration: 2.5 hours

Now that all of our prototyping is complete excluding our screen, began working on combining all of our individual STM32CubeIDE project folders for prototyping the hardware into one file that can control all of our hardware at the same time. Despite originally having the clock configured to run at 48MHz for the temperature probe and having the clock configured to run at 64MHz for the water level sensor, all our current hardware (water level sensor, temperature probe, ultrasonic sensor, motor driver with motor, I/O expander with keypad) are able to run seemingly accurately with the clock configured to 72MHz.
Main Code
The main function of our code
Currently running into the issue of the keypad not being read correctly, I believe it's due to the additional HAL delays from the other hardware's scripts for processing, ultimately messing with the timing of the keypad's reading function.
Output of Code
Displayed Output of Code
The output of the code is currently looping to first display the currently read distance from the ultrasonic sensor as "Distance: XX cm", then it displays the currently read temperature as "XX.XX C" for the temperature in degrees Celsius, and finally it will print whatever key is detected as being pressed on the keypad as "Key: X".

Entry 1: -----------------------------------------------------------------

Date: March 23rd
Start Time: 3:00pm
Duration: 0.5 hour

Watched soldering technique videos to remfamiliarize myself in order to be prepared for when we receive our PCB.
Watched the following videos:
https://www.youtube.com/watch?v=eHu_fGAyNY4
https://www.youtube.com/watch?v=Qps9woUGkvI
https://www.youtube.com/watch?v=EW9Y8rDm4kE
https://www.youtube.com/watch?v=5uiroWBkdFY
All of our components should be hand-solderable so I don't believe we'll need to use the hot plate for our PCB soldering.
Also read this article about desoldering: https://clevercreations.org/how-to-desolder-guide


Next, since a majority of our prototyping is complete except for the LCD screen and the I/O expander which should be close to complete, I'll combine all of our hardware's individual project files into one project file so that they can all be controlled at the same time.

=============== Week 10: =================

Spring Break

=============== Week 9: =================

Entry 2: -----------------------------------------------------------------

Date: March 14th
Start Time: 3:40pm
Duration: 3.5 hours

Made updates to our PCB layout according to the feedback we received from TAs. Corrected acute angles to be either 90 degrees or more, for example at the buck converter J8 pin1 and J1 pins 2 and 8. Rerouted the 5V and 3.3V signal traces that were under the I/O expander to go around it to ensure the signals won't cause any noise to the I/O expander since it has I2C signals. Fixed the issue of having the U7 microcontroller pin14 trace feeding a thin trace to a thick trace. Moved mounting screw hole H4 away from the 12V signal to ensure no problems are caused from this. Resized vias to have a hole diameter of 0.4mm to be capable of fly-wiring. Swapped C20 and C21, as well as C19 and C28 to have the correct capacitor closer to the microcontroller. I've never used KiCAD for PCB designing before so also had to learn how to use the software.
Updated PCB Layout
Updated PCB Layout

Entry 1: -----------------------------------------------------------------

Date: March 12th
Start Time: 2:30pm
Duration: 3.5 hours

Finished wiring the I/O Expander according to the previously shown schematic for the PCF8574 chip, while instead using the MCP23008, in order for the keypad to be I2C and began helping to debug the expander. Currently running into the issue of having the keypad read different input values as you drag your finger across the keypad instead of pressing down on the keypad's buttons. May be being caused by parasitic capacitance. Might have to switch to the bulky keypad instead of the ultra thin to ensure precision of inputs.
In getting ready for the PCB to be ordered, requested our STM32F103 microcontroller and determined we'll need the following headers:
locked 10 pin programming header for microcontroller, 10 pin header for spi lcd display, 2 pin header for sd card (even though sd card reader is in display), 4 pin header for ultrasonic sensor, 3 pin header for water level sensor, 3 pin header for temperature sensor, two 2 pin headers for stepper motor driver to stepper motor
Discussed how we should connect 4 debugging leds to our microcontrollers which will be helpful since we have so many different sensors and hardware modules.
Determined from feedback from midterm that we should use two S9V11MACMA buck converters to step down our input voltage from 12V down to 5V and then down to 3.3V, instead of the combination of our originally planned AP1117 and L7805 buck converters since we already prototyped with the S9V11MACMA and we shouldn't have to worry about the customer setting the output voltage of the buck converter since they ideally won't be interacting with our PCB directly.
Next will ensure the prototyping of the I/O expander is finished and will begin soldering the PCB once it is delivered.

=============== Week 8: =================

Entry 5: -----------------------------------------------------------------

Date: March 6th
Start Time: 1:30pm
Duration: 1 hour

Reviewed Team 18: Grid Wars' midterm design review presentation.

Entry 4: -----------------------------------------------------------------

Date: March 5th
Start Time: 2:30pm
Duration: 2 hours

Met just before our presentation to practice through what we were all going to say. Then presented our midterm design review presentation.

Entry 3: -----------------------------------------------------------------

Date: March 4th
Start Time: 8:00pm
Duration: 5.5 hours

Met with Caroline and Luke to work on being prepared for midterm review presentation. Helped planning of pcb layout and schematic, specifcally the power distribution and pin connections of our hardware. Decided we should use the L7805 buck converter to step our input voltage of 12V down to 5V for most of our sensors and then use the AP1117 buck converter to step down the 5V to 3.3V for our microcontroller. The reason for this change was that it wouldn't make sense to make the customer have to access the PCB to set the output of the S9V11MACMA buck converter to both 3.3V and 5V, and ideally would be easier to solder. Helped determine placement of heartbeat LEDs for our different voltages on our PCB of 12V, 5V, and 3.3V. Did a lot of research for alternative parts to our major components as well as specifications of our hardware to show in the midterm presentation. Also updated and split our block diagram into an interfacing block diagram as well as a power block diagram for ease of viewing.
Next will need to continue to prototype our I/O expander, and continue to improve on our pcb layout once we recieve feedback from the midterm.

Interfacing Block Diagram
Interfacing Block Diagram

Power Block Diagram
Power Block Diagram

Entry 2: -----------------------------------------------------------------

Date: March 4th
Start Time: 3:30pm
Duration: 1 hour

Reviewed Team 9: Fairway Finder's midterm design review presentation. They had the fact that some of their diodes were backwards in their schematic pointed out to them, so incorporated that feedback into our design as well.

Entry 1: -----------------------------------------------------------------

Date: March 4th
Start Time: 12:00pm
Duration: 3.5 hours

Finished prototyping the S9V11MACMA buck converter to properly step down our 12V input down to both 5V and 3.3V. Utilizes a potentiometer to set the output voltage of the converter. Only used the pins for input voltage, output voltage and ground, did not make use of the PG pin or EN pin.
Researched I/O expanders and based on what the ECE shop had available decided on using the MCP23008 which will convert our 8 wire signal from the keypad to a 2 wire I2C signal. I/O expander requires a 2.2K ohm pull up resistor on both the SDA and SCL signals.
Reference: https://www.instructables.com/I2C-keypad/
The above reference uses the PCF8574 chip which the MCP23008 should work identically.
Next will finish my presentation slides and help to make sure the pcb layout and schematic will be finished later today.

IO Expander Wiring
I/O Expander Wiring Diagram

MCP23008 Pinout
MCP23008 Pinout

Buck Converter Prototyping
S9V11MACMA Prototyping

=============== Week 7: =================

Entry 4: -----------------------------------------------------------------

Date: February 27th
Start Time: 12:00pm
Duration: 2 hours

Tried a new temperature sensor probe and the code and sensor worked. Temperature sensor repeatedly reports detected temperature to the console as seen in the code below. In addition to having the keypad now displaying properly, we have finished a high majority of our prototyping so we can move forward with the scehematic and PCB layout designs since we know our hardware works.
Next will begin working on redrawing the block diagram of our project for next week's design review.
Temperature Sensor Code
DS18B20 Temperature Sensor Code with Temperature Readings

Entry 3: -----------------------------------------------------------------

Date: February 26th
Start Time: 2:30pm
Duration: 3.5 hours

Continued debugging temperature sensor and tried debugging keypad before lab began. During lab figured the temperature probe might be fried since it can't read any temperature other than an intially set zero and decided to order new ones which should come tomorrow. Keypad seems to run without error but am having trouble displaying to the console which key is being pressed on the keypad. Discussed how our product would be mounted to the side of the fish tank with some parts hanging over the top of the tank like the automatic feeder which will be 3D printed. Also looked into what filter/pump system we would be able to implement in the final product to show how the water level sensor will detect a clog from the filter's water level getting too low. The 20 pine headers are unable to be prototyped using our breadboard so we switched to a different display which was able to be turned on.
Next we will continue to debug keypad, display and temperature sensor.
Keypad Reference: https://embeddedthere.com/how-to-interface-matrix-keypad-with-stm32-example-code-included/
Keypad Code
Keypad Sensor Code

Entry 2: -----------------------------------------------------------------

Date: February 26th
Start Time: 12:30pm
Duration: 1 hours

Began prototyping the temperature sensor since no progress was being made. Reference code displays to an oled so instead rewrote the code to display to the console. Uses multiple given libraries for the sensor that needed to be imported. Initially isn't detecting the temperatue sensor but after reworking the cubeide clock now the probe is only reading 0's. Will come back after class to continue debugging the temperature sensor.
DS18B20 Reference: https://microcontrollerslab.com/ds18b20-sensor-stm32-nucleo-stm32cubeide-oled/

Entry 1: -----------------------------------------------------------------

Date: February 24th
Start Time: 1:30pm
Duration: 2 hours

Started and finished prototyping for the HC-SR04 ultrasonic sensor. Measures the distance by measuring the on-time of the echo pulse signal. The first figure below shows the echo output signal with respect to the input trigger signal and 8 sonar pulses. Set the clock system to 72 MHz. Set the trigger pin to GPIO pin A10 and the echo pin to GPIO pin A4. Displays the distance between an object and the sensor to the uart console as seen in the second figure below.
Next will continue prototyping the temperature sensor and keypad if no progress is made.
HC-SR04 Reference: https://microcontrollerslab.com/hc-sr04-ultrasonic-sensor-stm32-nucleo-stm32cubeide/
Ultrasonic Sensor Timing
HC-SR04 Ultrasonic Sensor Timing
Ultrasonic Sensor Code
HC-SR04 Ultrasonic Sensor Code with Distance Readings

=============== Week 6: =================

Entry 5: -----------------------------------------------------------------

Date: February 21st
Start Time: 2:30pm
Duration: 3 hours

Finished prototyping the stepper motor after discovering a main issue was that the green and red wires of the motor must be conncected through the two B ports of the driver and the blue and yellow wires must be connected through the two A ports for the motor to work properly. Also prototyped the water level sensor to work, which some requirements we found for it to work through debugging is that it must have a 5V input and the voltage output sign is dependent on how high the water level it detects is. In order to determine the sensor works, wrote code to have the microcontroller turn off an LED once the water level sensor detects water.
Next we will meet early in week 7 to ensure all our prototyping is finished so we can focus on pcb design.
Water Level Sensor While Loop Code
Water Level Sensor While Loop Code
Stepper Motor Function Code
Stepper Motor Function Code
Wiring on 2/22
Wiring on 2/22

Entry 4: -----------------------------------------------------------------

Date: February 20th
Start Time: 5:30pm
Duration: 0.5 hours

Went back down to lab after lecture to quickly try a couple different debugging techniques like applying the TIM3 instead of HAL delay which ended up losing power to the motor so decided to step away from that approach temporarily. Also made sure the motor was being properly powered with 12V as well as the motor driver was being properly powered with a 100µF capacitor for the motor supply. Will continue debugging tomorrow.

Entry 3: -----------------------------------------------------------------

Date: February 20th
Start Time: 12:00pm
Duration: 4 hours

The ULN2003 motor driver was giving us trouble so we decided to switch to the DVR8825 motor driver. The difference is that the DVR8825 has only 2 information signals for STEP and DIR (direction) as opposed to 4 information signals from the previous driver. We were able to power the stepper motor to turn on but it was only able to randomly jitter instead of being able to smoothly rotate. Begun writing into the while loop in main to call a stepper function to rotate in one direction for a set amount of steps, wait a delay, rotate the opposite way in the same steps, wait another delay, and repeat. We were recommended to switch to one of the softwares internal timers instead of a function call to a delay which we've begun looking into how to implement that.
Next will meet again tomorrow in order to continue to debug code for the stepper motor and begin coding other sensors.
Stepper Motor While Loop Code
Stepper Motor While Loop Code

Entry 2: -----------------------------------------------------------------

Date: February 19th
Start Time: 3:30pm
Duration: 2 hours

Met in lab and began the prototyping process for the stepper motor. Downloaded the SMT32CubeIDE software in order to begin coding the STM32F103RB microcontroller. Used this website to learn how to use the functions in STM32CubeIDE: https://deepbluembedded.com/stm32-gpio-write-pin-digital-output-lab/. Used this youtube video as reference for learning how to code the NEMA-17 stepper motor with the driver and the STM32: https://www.youtube.com/watch?v=rI_FXATKCD4&t=193s.
Next will meet tomorrow with the team to continue prototyping the hardware for the project.

Entry 1: -----------------------------------------------------------------

Date: February 15th
Start Time: 11:00am
Duration: 1 hours

Worked on bill of materials which required researching supplier and manufacturer information for all our hardware.
Next will meet in lab to discuss moving forward with prototyping.

=============== Week 5: =================

Entry 4: -----------------------------------------------------------------

Date: February 14th
Start Time: 7:10pm
Duration: 3 hours

Wired our temperature sensor, feeder level sensor, and keypad to the microcontroller. Temperature sensor requires an external pullup resistor of approximately 5kΩ (used 4.7kΩ); thus, the idle state for the 1-Wire bus is high. Each keypad channel requires a 1kΩ resistor connecting it to the microcontroller. Still waiting on 20-wire ribbon cable to be able to connect the TFT display but most of our hardware is connected and ready to prototype once working code is ready.
Next will continue to work on running code with our hardware to make sure we can receive data correctly.
Level Sensor Reference: https://cdn.sparkfun.com/datasheets/Sensors/Proximity/HCSR04.pdf
Temperature Sensor Reference: https://cdn-shop.adafruit.com/datasheets/DS18B20.pdf
Wiring on 2/14
Keypad Matrix Hardware
Keypad Matrix Configuration
Temperature Sensor Configuration

Entry 3: -----------------------------------------------------------------

Date: February 13th
Start Time: 12:00pm
Duration: 2 hours

Wired the microcontroller, motor driver and stepper motor together on a breadboard for prototyping with a 5V adapter input from a wall outlet. Next will figure out how to wire the level sensor, keypad, and temperature sensor to the microcontroller.
Used this website as reference for connecting the stepper motor and motor driver: https://controllerstech.com/interface-stepper-motor-with-stm32/
Stepper Motor and Motor Driver
Wiring on 2/13

Entry 2: -----------------------------------------------------------------

Date: February 12th
Start Time: 3:30pm
Duration: 2.5 hours

In lab I discussed the hardware we acquired like the TFT display, 4x4 matrix keypad, temperature sensor, motor driver and stepper motor, and I inquired about how to wire our TFT display and came to the conclusion we'd need the Wurth Electronics INC 687620050002 series ribbon cable to be able to connect the display to our microcontroller.
We picked out the 28BYJ-48 stepper motor for our prototyping since it's efficient at making precising turning measurements and only requires a 5V input. We also picked out the motor driver IC ULN2003 since it is very easy to use to connect between the voltage input, the stepper motor, and the microcontroller. We chose to order the Ultrasonic Ranging Module HC-SR04 to work as our automatic feeder's level sensor since it doesn't require light and can use ultrasonic waves to detect how close an object is away from it so if we place it on the lid of our feeding dispensers storage, it will be able to detect when the storage gets low on fish food.
Now that our hardware is chosen can begin to wire them together on the breadboard

Stepper Motor and Motor Driver 28BYJ-48-Pinout
28BYJ-48-Pinout

Entry 1: -----------------------------------------------------------------

Date: February 11th
Start Time: 5:30pm
Duration: 0.5 hours

Met with teammates after lecture to discuss how we were going to switch our microcontroller to the STM32F091 from the ESP32 since no progess was being made with the ESP32. Determined our chosen hardware should still work with the STM32.
Next I will begin to wire our hardware to the breadboard to begin prototyping.

=============== Week 4: =================

Entry 4: -----------------------------------------------------------------

Date: February 7th
Start Time: 10:00pm
Duration: 1.5 hours

Drew up the system block diagram for our product depicting all the different hardware parts and how they'll comunicate through interfacings as well as the power distribution throughout the system. Had to research different hardware's input voltage requirements and interfacings.
Next will begin prototyping with the hardware between the microcontroller like the stepper motor, temperature probe, and display. Also will have to work on component analysis tomorrow.
System Block Diagram
System Block Diagram

Entry 3: -----------------------------------------------------------------

Date: February 6th
Start Time: 6:00pm
Duration: 2.25 hours

Work session to complete the electrical overview for our product. In order to complete the assignment, researched the interfacing considerations of all our hardware as well as the maximum currents for our hardware. Also researched and calculated the new expected memory needed to be held for our product to use a SD card.
Next will design the system block diagram of the interfacing and power distribution of our project.

Entry 2: -----------------------------------------------------------------

Date: February 5th
Start Time: 3:30pm
Duration: 2.25 hours

We decided on not moving forward with the oxygen sensor since we still have too many PSDR worthy components and the oxygen sensors are far too expensive for our budget. Explored the available graphical displays within the lab and researched which one would be the best fit for our project between the QC12864B, the NHD-160128WG-BTGH-VZ#-1, the ILI9341, the EVE2-43A-BLM-TPN, and the NX1060P101-011C-I.

https://exploreembedded.com/wiki/images/7/77/QC12864B.pdf
https://newhavendisplay.com/content/specs/NHD-160128WG-BTGH-VZ-1.pdf
https://cdn-shop.adafruit.com/datasheets/ILI9341.pdf
https://www.digikey.com/en/products/detail/matrix-orbital/EVE2-43A-BLM-TPN/7650296?msockid=3fa0bc329fc867af0d3dac549eb666a0
https://amperka.ru/product/display-nextion-intelligent-nx1060p101-011c-i

Decided on trying the EVE2 because of its compatability with the ESP32 microcontroller, its SPI interfacing, as well as its 3.3V power consumption. Physically, it is a thinner and sleeker model display that would fit nicely with our product since we don't want a screen that's too bulky for the fish tank. This should allow us to begin prototyping our product's display.
Waterproof temperature probe and the physical fish tank should be on the way.
Next will work on researching the power distribution between the different hardware for our product.
QC12864B NHD-160128WG-BTGH-VZ#-1
------------ QC12864B ---------------- NHD-160128WG-BTGH-VZ#-1
ILI9341 EVE2-43A-BLM-TPN
-------------- ILI9341 -------------------------- EVE2-43A-BLM-TPN
NX1060P101-011C-I
------ NX1060P101-011C-I

Entry 1: -----------------------------------------------------------------

Date: February 4th
Start Time: 6:30pm
Duration: 2 hours

Work session towards the electrical overview for our product. Researched the supply voltages for our hardware, like that the maximum voltage our project would require is 12V for the mercury stepper motor, as well as the some of the interfacings for our hardware including I2C and SPI. Also determined we'd use a buck regulator to convert our 12 volt input to 5 volts for the ESP32 microcontroller.
Next will meet in lab to decide on a specific LCD display and to review our PSDR's.

=============== Week 3: =================

Entry 3: -----------------------------------------------------------------

Date: January 29th
Start Time: 3:30pm
Duration: 3 hours

Filled out the hardware request form for the Pmod HYGRO sensor. Decided on using the Mercury stepper motor for our automatic feeding dispenser. Decided to forgo having a UV-C bacteria light and the pH sensor as well as regarding any regulation components to be possible reach PSDRs. Decided on using the ESP32 Feather V2 for our microcontroller. Also will use a 4x4 keypad with the ESP32 to be able to have the user set boundaries for desired sensor ranges like water temperature ranges. Displayed parts of what I researched in lab. This brings us to having finalized our plan for the direction of our project's development. Next will need to begin prototyping hardware like the Pmod HYGRO and the Mercury stepper motor with the the ESP32.
stepperMotor
https://docs.rs-online.com/0db3/A700000011341897.pdf

Entry 2: -----------------------------------------------------------------

Date: January 25th
Start Time: 10:10pm
Duration: 1 hour

Designed the functional block diagram using powerpoint. Details the motor using DAC/ADC, the SD card and OLED using SPI, and the sensors using I2C, all working with the ESP32.
Next we will still need to finalize what hardware we're going to use when we meet in lab.
Block Diagram
The Functional Diagram

Entry 1: -----------------------------------------------------------------

Date: January 25th
Start Time: 1:55pm
Duration: 4 hours

Worked on A2. Filled out sections 4.1 and 4.2. Contributed to sections 1.0, 4.3, 4.4, and 4.6.
In order to fill out the sections, I researched a graphical OLED display that can be used with the ESP32 with either SPI or I2C for us to display our stored results from our results. Researched analog dissolved oxygen and pH levels sensors from the brand Gravity that could work for our product. Further researched and calculated how much memory in bytes our product would need to be able to hold to take minutely readings everyday from multiple sensors which the ESP32 plus a possible SD card will be able to hold. Also found the Uxcell floating water level sensor in case we nant to measure the height of the water to ensure nothing is broken like a jammed water filter. Also researched the limit to the weight for our product as well as filtering system logistics for if we were to use a water pump which we decided is most likely not optimal for our purposes.
Next we will finalize what hardware we're going to use when we meet in lab.
Water Level Sensor

Link to Water Level Sensor: https://www.harfington.com/products/p-1154114?currency=USD&variant=42110344102137&utm_source=bing&utm_medium=cpc&utm_campaign=bs_us_hw1l&stkn=f8e35277684b&utm_term=Bing-shopping&utm_content=ywh&msclkid=91367a9d210b105f08f41d085a1625c2
example1
Link to OLED: https://www.amazon.com/2-42inch-OLED-Display-Module-Communication/dp/B0DLFVTDRN/ref=sr_1_37?adgrpid=1330410799635776&dib=eyJ2IjoiMSJ9.5lmOPq3pVdb8uDFeMJ1yAdIoaa5orkY1EhEpSQT8Y1fwKQgSgGwiAnmsRzvqnJYjCBZH2af2wTE5JOvuzAz47HZHsY6nOTqXcYVs_qVXBph1nxcBf-q_cLy-_N4pEAA7xXW-EqVHGDfhjy7aLva5GVge5Utjm0InwoISVhAEotpvnVPUXKODZPmd8wkcgVy57ryi_mEdW2W1e1DMj4iEYBWc0k4PJfe3t3qxo82NUGw.X1-XvWQEimhI_PRZzyv44cFDIIXjNL9vjiqP4lTw_cw&dib_tag=se&hvadid=83150964101866&hvbmt=bb&hvdev=c&hvlocphy=96463&hvnetw=o&hvqmt=b&hvtargid=kwd-83151790524713%3Aloc-190&hydadcr=24360_13514968&keywords=oled%2Bdisplay%2Bi2c%2B128x64&msclkid=74a63516a23c1e48fef852832089ab31&qid=1737851608&sr=8-37&xpid=x_yXgMo7k__1v&th=1

=============== Week 2: =================

Entry 2: -----------------------------------------------------------------

Date: January 23rd
Start Time: 3:30pm
Duration: 1 hour

Added personal information to the website. Then met with Shivam to discuss possible prototyping methods for our project and were directed toward using the Pmod HYGRO as our temperature reading sensor. It's an I2C. Begun the process of looking at available oxygen sensors although the ones in house aren't waterproof. We will have to begin coding the programming for the temperature sensor.
pmodHygro
Reference Manual : https://digilent.com/reference/_media/reference/pmod/pmodhygro/pmod-hygro-rm.pdf
The sensor's readings can be obtained by using a TI HDC1080 which the reference manual for the chip can be found here: https://www.ti.com/lit/ds/symlink/hdc1080.pdf
HDC1080

Also began looking into the functionality of stepper motors for our automatic feeding dispenser. Next will begin working on A2 to determine logistics like constraints.

Entry 1: -----------------------------------------------------------------

Date: January 22nd
Start Time: 3:30pm
Duration: 2.25 hours

During our weekly meeting we discussed which features we plan to implement for our project and possible new features like a bacteria killing UV light as well as having as SD memory card so that we could display graphs of previously read data on the tank. Also figured we would need to have a filtering system for the tank and began researching the benefits of filtering through a mesh/paper filter that would need to be replaced or a filter that would need to be emptied periodically. We determined that a pH sensor would be unnecessary for our project and that we would not create an app to remote control the tank from afar. Also determined that I am the only one with soldering experience so I will be one of the individuals to work on that for our team.
We started the discussion of which motors and filters we would use for our fish tank and I found the source https://www.aquacultureid.com/recirculating-aquaculture-system/ which gave us great insight on different filtering methods for the fishtank, like using a drum motor, as well as the UV killing bacteria idea.
Drum Filter
Other logistics we discussed included how we were going to power our project which we decided would not be battery powered but would be plugged into the wall. Our product will need to have access to electricity 24/7 to run properly. Possibility of need for buck-boost converter. Next we meet with Shivam to discuss which sensors to get for prototyping.

=============== Week 1: =================

Entry 2: -----------------------------------------------------------------

Date: January 18th
Start Time: 3:30pm
Duration: 1.25 hours

Our team determined each members role within the group project by reviewing our expertises, and we decided that since I'm the only Electrical Engineer that I should be the Hardware Lead. I also helped revise the A1 Final Project Proposal initial PSDRs.

-Hardware
1. Integrated Sensor Monitoring
The system will utilize pH, temperature, and oxygen sensors interfaced with the STM32F091 microcontroller. Sensor data will be sampled through ADC channels, with appropriate hardware filtering to reduce noise, ensuring accurate real-time water quality readings.
2. Automated Feeding Mechanism
The design will include a programmable food dispenser motor, controlled via PWM signals. The hardware will ensure precise and consistent motor operation.
3. Power Regulation and Safety
The PCB will manage stable power distribution to all components, including sensors and motors. It will monitor voltage and current levels to detect anomalies and activate safety mechanisms to prevent damage or unsafe conditions.

-Software
4. Real-Time Data Processing and Alerts
The microcontroller will process sensor readings and compare them against predefined thresholds. Alerts will be generated for unsafe water conditions and displayed on the LCD or transmitted to a connected app, ensuring timely user notification.
5. User-Friendly Interface
The software will provide an intuitive interface for configuring system settings, displaying real-time data, and showing alerts. The interface will support navigation via buttons or app integration, ensuring ease of use for hobbyists and pet store operators.

Next we will finalize which functions are to be featured in our project and how we plan to implement them.

Entry 1: -----------------------------------------------------------------

Date: January 15th
Start Time: 3:30pm
Duration: 2 hours

Toured the lab and interviewed with the lab TAs. Determined which areas of our project proposal are still fuzzy and need to be reconsidered like what features we will be using for our fish tank. The options determined were an oxygen sensor/temperature sensor/pH level sensor/automatic feeding dispenser/screen display. Next we will discuss specifics for the features of our project.