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.

Healthy Chair

Ryan Chen, Alan Tokarsky, Tod Wang

Healthy Chair

Featured Project

Team Members:

- Wang Qiuyu (qiuyuw2)

- Ryan Chen (ryanc6)

- Alan Torkarsky(alanmt2)

## Problem

The majority of the population sits for most of the day, whether it’s students doing homework or

employees working at a desk. In particular, during the Covid era where many people are either

working at home or quarantining for long periods of time, they tend to work out less and sit

longer, making it more likely for people to result in obesity, hemorrhoids, and even heart

diseases. In addition, sitting too long is detrimental to one’s bottom and urinary tract, and can

result in urinary urgency, and poor sitting posture can lead to reduced blood circulation, joint

and muscle pain, and other health-related issues.

## Solution

Our team is proposing a project to develop a healthy chair that aims at addressing the problems

mentioned above by reminding people if they have been sitting for too long, using a fan to cool

off the chair, and making people aware of their unhealthy leaning posture.

1. It uses thin film pressure sensors under the chair’s seat to detect the presence of a user,

and pressure sensors on the chair’s back to detect the leaning posture of the user.

2. It uses a temperature sensor under the chair’s seat, and if the seat’s temperature goes

beyond a set temperature threshold, a fan below will be turned on by the microcontroller.

3. It utilizes an LCD display with programmable user interface. The user is able to input the

duration of time the chair will alert the user.

4. It uses a voice module to remind the user if he or she has been sitting for too long. The

sitting time is inputted by the user and tracked by the microcontroller.

5. Utilize only a voice chip instead of the existing speech module to construct our own

voice module.

6. The "smart" chair is able to analyze the situation that the chair surface temperature

exceeds a certain temperature within 24 hours and warns the user about it.

## Solution Components

## Signal Acquisition Subsystem

The signal acquisition subsystem is composed of multiple pressure sensors and a temperature

sensor. This subsystem provides all the input signals (pressure exerted on the bottom and the

back of the chair, as well as the chair’s temperature) that go into the microcontroller. We will be

using RP-C18.3-ST thin film pressure sensors and MLX90614-DCC non-contact IR temperature

sensor.

## Microcontroller Subsystem

In order to achieve seamless data transfer and have enough IO for all the sensors we will use

two ATMEGA88A-PU microcontrollers. One microcontroller is used to take the inputs and

serves as the master, and the second one controls the outputs and acts as the slave. We will

use I2C communication to let the two microcontrollers talk to each other. The microcontrollers

will also be programmed with the ch340g usb to ttl converter. They will be programmed outside

the board and placed into it to avoid over cluttering the PCB with extra circuits.

The microcontroller will be in charge of processing the data that it receives from all input

sensors: pressure and temperature. Once it determines that there is a person sitting on it we

can use the internal clock to begin tracking how long they have been sitting. The clock will also

be used to determine if the person has stood up for a break. The microcontroller will also use

the readings from the temperature sensor to determine if the chair has been overheating to turn

on the fans if necessary. A speaker will tell the user to get up and stretch for a while when they

have been sitting for too long. We will use the speech module to create speech through the

speaker to inform the user of their lengthy sitting duration.

The microcontroller will also be able to relay data about the posture to the led screen for the

user. When it’s detected that the user is leaning against the chair improperly for too long from

the thin film pressure sensors on the chair back, we will flash the corresponding LEDs to notify

the user of their unhealthy sitting posture.

## Implementation Subsystem

The implementation subsystem can be further broken down into three modules: the fan module,

the speech module, and the LCD module. This subsystem includes all the outputs controlled by

the microcontroller. We will be using a MF40100V2-1000U-A99 fan for the fan module,

ISD4002-240PY voice record chip for the speech module, and Adafruit 1.54" 240x240 Wide

Angle TFT LCD Display with MicroSD - ST7789 LCD display for the OLED.

## Power Subsystem

The power subsystem converts 120V AC voltage to a lower DC voltage. Since most of the input

and output sensors, as well as the ATMEGA88A-PU microcontroller operate under a DC voltage

of around or less than 5V, we will be implementing the power subsystem that can switch

between a battery and normal power from the wall.

## Criteria for Success

-The thin film pressure sensors on the bottom of the chair are able to detect the pressure of a

human sitting on the chair

-The temperature sensor is able to detect an increase in temperature and turns the fan as

temperature goes beyond our set threshold temperature. After the temperature decreases

below the threshold, the fan is able to be turned off by the microcontroller

-The thin film pressure sensors on the back of the chair are able to detect unhealthy sitting

posture

-The outputs of the implementation subsystem including the speech, fan, and LCD modules are

able to function as described above and inform the user correctly

## Envision of Final Demo

Our final demo of the healthy chair project is an office chair with grids. The office chair’s back

holds several other pressure sensors to detect the person’s leaning posture. The pressure and

temperature sensors are located under the office chair. After receiving input time from the user,

the healthy chair is able to warn the user if he has been sitting for too long by alerting him from

the speech module. The fan below the chair’s seat is able to turn on after the chair seat’s

temperature goes beyond a set threshold temperature. The LCD displays which sensors are

activated and it also receives the user’s time input.

Project Videos