Project

# Title Team Members TA Documents Sponsor
47 Automatic cake decorator
Honorable Mention
James Zhu
Muye Yuan
Rui Gong
Jason Zhang design_document1.pdf
design_document2.pdf
final_paper1.pdf
presentation1.pdf
proposal2.pdf
proposal1.pdf
video
# Team Members:
Muye Yuan(muyey2)
Rui Gong(ruigong5)
James Zhu (tianyi9)

# Problem

The current challenge lies in manual application of cream on cakes, prompting the need for an automated solution. Traditional methods often result in variations in cream thickness, coverage, and overall quality due to the nature of manual application. This not only demands skilled workers but also leads to increased production costs and the potential for human errors. Moreover, labor costs can be a significant factor in the overall production costs.

# Solution

We decided to make an automatic cake decorator, which puts creams with shapes and curves around the edge of the top surface of the cake. By automating this process, we aim to eliminate the inconsistencies associated with manual application, enhance the overall quality of decorated cakes, and reduce production costs. Ultimately, this device can offer a more efficient and cost-effective solution for the baking industry. The decorator can move along the edge of the cake detected by the camera. According to the input, the movement will be divided by x and y components which can lead the stepper motor to the appropriate position. This system differs from existing food printer solutions, which only print pixelated images on the food. It leaves a vectorised, continuous trail of cream. So it requires a more dedicated CV algorithm to recognize the shape of cakes.

# Solution Components
##Subsystem1 Computer vision and detector:
1x 1080p usb camera, laptop
A frame holds the camera hanging it on the top of our decorator machine, looking down to the cake in it. It’s connected to a laptop running our recognition program. The program would recognize the edge of the camera with a CV algorithm. It could identify the cake successfully even with other distractions (like the machine itself) in the view, and fit the edge into a set of waypoints for the cream extruder to follow. The program presents a preview of it for the user to confirm. The laptop is connected to MCU PCB with USB. Once a key is pressed, it would send out a waypoint to the MCU and signal for it to start moving the mechanical parts.

##Subsystem2 MCU and PCB
1x ATmega328P MCU, 1x self designed PCB with the MCU and the motor driving circuit
Input: Usb connected from the laptop
Output: Control signal to the step motors driving the extruder and the cream syringe.
Once a set of waypoints is received, the trajectory following the waypoint would be converted into its projections on the x and y axis, and the function of x and y position over time would be calculated. (these calculations might be done on the laptop as well). Then the program on the MCU would start and drive the two sliding rail motors, as well as the motor pushing the syringe.

##Subsystem3 Mechanical structure
3x 42-40 Stepper Motor, Cake Decorating Tools Cupcake Injector, rectangular frame, and 2x Linear Rail Guide, height adjustable base (placing the cake)
The structure of the machine resembles that of a cartesian robot, or a 3D printer, which is two perpendicular sliding rails (powered by motors) connected to each other, able to move its tips to arbitrary x-y positions. A large syringe with cream inside is mounted at the tip, extruding the cream uniformly when pushed by a motor.

# Q&A
##1.Decide whether to implement a 2D or 3D movement system.

We want to implement the 3D movement system, but we don’t know how complex it is. Thus, if the 3D system is too complicated for us to implement, we will change to implement a 2D movement system.

##2.Clarify the mechanisms you plan to use for x, y, and z movements. Will they be similar to those in a 3D printer, and how will you ensure movements, when working with a medium like cream?

Yes. It is similar to 3D printers with two perpendicular sliding rails. And we are planning on putting a rubber hose on the syringe and the end factor of the mechanism grabbing the other end of the hose, keeping the relatively heavy syringe static.

##3.Determine the dimensions of the machine(syringe size, etc). Are you considering a vertical actuator to push the cream out of the syringe? Detail out all the electrical components required for this idea.

We want to start from a small size, so the amount of cream will not be large. For example, we start from using the Cake Decorating Tools Cupcake Injector and a step motor pushing it to get the cream out.

##4. The incorporation of a camera for position detection adds complexity. How do you plan to convert the camera inputs into xyz position? The coding required to convert camera output into g-code(x,y,z) is critical.

The z position is fixed for a cake. We first require the user to place height of the cake manually so that its top surface is near the extruder. Later we might add an ultrasound system and an automatically adjustable base for the cake. For x,y coordinates, we might first try to mount the camera high enough, so that we can assume it’s a planar projection from the pixel coordinates to the physical. We would first fix the relative position of the machine and the camera and do calibration (mapping from pixel coordinate to physical) manually. But later we could try adding some marks on the edges on the machine, the camera can automatically figure out the linear translation without the need to calibrate every time. If the error of assuming planar projection turns out to be too large, we could still figure out the intrinsic of the camera and do unprojection with formulas.


# Criterion For Success
-CV system recognize the edge of the target successfully

-Moving system can successfully follow the input instruction

-Put cream with a curve around the edge of the top surface of the cake.

Habit-Forming Toothbrush Stand

John Kim, Quinn Palanca, Rahul Vasanth

Habit-Forming Toothbrush Stand

Featured Project

I spoke with a TA that approved this idea during office hours today, and they said I should submit it as a project proposal.

# Habit-Forming Toothbrush Stand

Team Members:

- Rahul Vasanth (rvasant2)

- Quinn Andrew Palanca (qpalanc2)

- John Jung-Yoon Kim (johnjk5)

# Problem

There are few habits as impactful as good dental hygiene. Brushing teeth in the morning and night can significantly improve health outcomes. Many struggle with forming and maintaining this habit. Parents might have a difficult time getting children to brush in the morning and before sleep while homeless shelter staff, rehab facility staff, and really, anyone looking to develop and track this habit may want a non-intrusive, privacy-preserving method to develop and maintain the practice of brushing their teeth in the morning. Keeping track of this information and but not storing it permanently through a mobile application is something that does not exist on the market. A small nudge is needed to keep kids, teenagers, and adults of all ages aware and mindful about their brushing habits. Additionally, many tend to zone out while brushing their teeth because they are half asleep and have no idea how long they are brushing.

# Solution

Our solution is catered toward electric toothbrushes. Unlike specific toothbrush brands that come with mobile applications, our solution applies to all electric toothbrushes, preserves privacy, and reduces screen time. We will implement a habit-forming toothbrush stand with a microcontroller, sensors, and a simple LED display that houses the electric toothbrush. A band of sensors will be wrapped around the base of the toothbrush. Lifting the toothbrush from the stand, turning it on, and starting to brush displays a timer that counts seconds up to ten minutes. This solves the problem of brushing too quickly or losing track of time and brushing for too long. Additionally, the display will provide a scorecard for brushing, with 14 values coming from (morning, night) x (6daysago, 5daysago, . . . , today) for a "record" of one week and 14 possible instances of brushing. This will augment the user's awareness of any new trends, and potentially help parents, their children, and other use cases outlined above. We specifically store just one week of data as the goal is habit formation and not permanent storage of potentially sensitive health information in the cloud.

# Solution Components

## Subsystem 1 - Sensor Band

The sensor band will contain a Bluetooth/Wireless Accelerometer and Gyroscope, or Accelerometer, IR sensor (to determine height lifted above sink), Bluetooth/Wireless connection to the microcontroller. This will allow us to determine if the electric toothbrush has been turned on. We will experiment with the overall angle, but knowing whether the toothbrush is parallel to the ground, or is lifted at a certain height above the sink will provide additional validation. These outputs need to be communicated wirelessly to the habit-forming toothbrush stand.

Possibilities: https://www.amazon.com/Accelerometer-Acceleration-Gyroscope-Electronic-Magnetometer/dp/B07GBRTB5K/ref=sr_1_12?keywords=wireless+accelerometer&qid=1643675559&sr=8-12 and individual sensors which we are exploring on Digikey and PCB Piezotronics as well.

## Subsystem 2 - Toothbrush Base/Stand and Display

The toothbrush stand will have a pressure sensor to determine when the toothbrush is lifted from the stand (alternatively, we may also add on an IR sensor), a microcontroller with Bluetooth capability, and a control unit to process sensor outputs as well as an LED display which will be set based on the current state. Additionally, the stand will need an internal clock to distinguish between morning and evening and mark states accordingly. The majority of sensors are powered by 3.3V - 5V. If we use a battery, we may include an additional button to power on the display (or just have it turn on when the pressure sensor / IR sensor output confirms the toothbrush has been lifted, or have the device plug into an outlet.

# Criterion For Success

1. When the user lifts the toothbrush from the stan and it begins to vibrate (signaling the toothbrush is on), the brushing timer begins and is displayed.

2. After at least two minutes have passed and the toothbrush is set back on the stand, the display correctly marks the current day and period (morning or evening).

3. Track record over current and previous days and the overall weekly record is accurately maintained. At the start of a new day, the record is shifted appropriately.

Project Videos