Here’s what we accomplished in the remaining weeks!

Sensors + Making the bin neater

With the bin opening and flap redesigned (stated below), we tried to find the best height to position the ultrasonic sensors and decide the distance threshold (when a smaller distance is detected, it would mean that there is trash in the way) so that it will be able to detect bin fullness correctly. After measuring and testing, we decided on a good height for the ultrasonic sensors. Ultrasonic sensor 1’s distance threshold is 33cm while Ultrasonic sensors 2 and 3’s thresholds are both 23cm.

 

Also, with the many wires that we had, we also tried to make it neater so they would not get in the way of the bin as much as possible. We did this by coiling and taping the wires to the side and ensuring that they run along the side of the bin.

 

The logic of the sensors work such that when 2 out of 3 sensors detects a distance of less than their respective thresholds, the bin would lock.

Prototype of extra bin

Rather than building a second bin, we are just using a box to represent Bin 2 as the main point is to show that the logic works. The logic that we tested and worked is that when Bin 1 locks, the electromagnetic lock in Bin 2 will unlock and it did.

Bin opening

Previously, we made wedges for the opening of the bin that will have an angle of 120 degrees. However, when we attached our corrugated cardboard pieces to the wedge and attached the full opening to the bin, we realised that the slope of 120 degrees was too gentle and when we attempted to throw trash into our bin, some of them were unable to fall into the bin. The wedges were also too thick which led to too much open space at the side of the opening.

Shane altered these 2 aspects of the wedge and after much trial and error (Thanks Shane!), these are our final wedges for the bin opening.

s

Here is how the bin opening looks like now when attached to the bin:

We attempted throwing different objects into the bin and with this larger slope angle, objects were able to fall seamlessly into the inner bin.

Raspberry Pi Camera

We also decided to have a transparent top part of the bin (using acrylic boards) so light can enter for the camera to be able to see what is inside the bin, instead of installing lights in the bin. We also found an optimal position for the camera on the underside of the top of the bin so it can capture all items in the inner bin.

Here’s an image of the bin’s contents taken by the Raspberry Pi camera:

Weight Sensor

With the weight sensor, we realised that the HX711 amplifier would spoil over some time, leading to great inaccuracies in the mass recorded, such as constantly drifting values. As such, we bought multiple of these amplifiers to use when each one starts to show signs of deterioration. Hence we replaced HX711 twice throughout the duration of our project.

More recently, despite replacing HX711, we noticed that the weight sensor was still not functioning correctly. It would read an accurate value just after being tared, but read entirely inaccurate values once we added/removed masses from the weight sensor. Hence, Josiah discovered that this could be due to the loose connections between the DuPont wires and pin headers we soldered onto HX711.

Our former HX711 with pin headers

The wires often came loose and it was difficult to ensure a secure connection, so we changed it to JSTXH 2.54mm connector, by replacing both the wires and the connectors. This seemed to improve the accuracy and consistency of readings from the weight sensor, though values were not accurate, they had a consistent ~500g deviation from the actual mass.

HX711 with JSTXH 2.54mm connector soldered on