Week - 4
- Implement control logic of a “washing machine” using Stateflow as per given sequence:
- If the power supply is available, the system gets activated
- If the Water supply is not available, stop the process & indicate through LED
- Soaking time should be 200s followed by Washing time of 100s.
- Then rinsing happens for next 20s & dryer runs for 50s
After all the processes have completed turn on the finished LED
The working principle of the washing machine is centrifugation. Centrifugal force is a force on a body moving in a circular path and is directed away from the centre. The centrifugal force caused by spinning the clothes at around 800-1200 rpm.

- If the power supply is available, the system gets activated
- When the Power Supply is on all the LEDs will blink Constantly

- If the Water supply is not available, stop the process & indicate through LED

- Soaking time should be 200s followed by Washing time of 100s.
- Then rinsing happens for next 20s & dryer runs for 50s

2. Make a Simulink chart for the “Gear shift” logic as per below conditions:
Speed Range(kmph) Gear
0 to 15 1
16 to 25 2
26 to 40 3
41 to 60 4
Above 61 5
Give speed input while the simulation is running & display the gear number.
Components :
- Chart
- Display
- Constant
- Lamp
- Rocker Switch
- Slider

At Speed 72 kmph

At speed 72kmph which is above 61kmph gear 5 is implemented and Gear_fifth LED is glow Blue and display output as 1.
At speed 20 kmph

At speed 20kmph which is above 16kmph gear 2 is implemented and Gear_second LED is glow Blue and display output as 1.
At Speed 48 kmph

At speed 48kmph which is above 40kmph gear 4 is implemented and Gear_fourth LED is glow Blue and display output as 1
Conclusion :
Thus all condition simulated through stateflow chart successfully.