Week - 4
Implementation of control logic of a washing machine using simulink chart
- In the chart block we can implement the control logic of any finite state machine
- As per the given conditions in the question the washing machine changes state from inactive to active to soaking to washing to rinsing and finally dryer is turned on for some time.
- A finite state machine changes its state when the changes in input is detected.

- in the above diagram the inputs to the system (washing machine) are power supply,water supply and delay.

- initially the flow chart starts from deactivated state and it first checks for power supply is available or not.
- Next if the power supply is avilaible the system is turned on and checks for water supply next.
- If water supply is not available the no water supply led is turned on and the process is terminated.
- Otherwise the loop jumps to soaking for 200 seconds followed by washing for 100 seconds.
- Followed by rinsing for 20 seconds and finally the clothes are dried by turning on the in-built dryer for 20 seconds.
The finished led is turned on and finally the loop is executed once before switching back to deactivated state.
The symbols are to be labelled as input,output or chosen as per desired type.
The chart can be used efficiently when the given sequence is fed to state chart.
Simulink logic for "gear shift"
- In these example the finite state machine is the motor vehicle and the states are the different gears with input being speed and output being gear shift.
- As suggested in question the input sequence is given to the chart via repeating sequence,output is taken from display.

- Initially the system or vehicle is at rest and engine is switched off so the gear condition is neutral
- when the speed increases gradually or instantaneously the gear shift is seen accordingly

- There are 5 gears and the conditions for state change or gear change is necessarily need to be mentioned on the transition arrow
- Here the output is the gear shift and output is gear shift
- the number of the gear is displayed on the display respectively.