Challenge

State Flow using Matlab Simulation

Washing Machine Simulation:

Washing machine has following states:

  1. Initial State
  2. System Activated
  3. No water
  4. Soaking State
  5. Washing
  6. Rinsing
  7. Drying
  8. Clothes washed

Input variables:

Power, Water.

Initial state:

In this state, Washing machine is in power off mode. The input variables in this state are:

power = 0

System Activated:

In this state, Washing machine is in power on mode. The system is getting the power supply. In this state, the input variables are:

power = 1

No Water :

Washing machine enters into this state if there is no water supply. State of input variable conditions:

power = 1

water = 0

Soaking state:

In this state, Washing machine is soaking the clothes. The input variable condition to enter this state is

water = 1;

The washing machine is in this state for 200 sec.

Washing state:

In this state, Washing machine is washing the clothes. The input variable condition to enter this state is

water = 1;

The washing machine is in this state for 100 sec.

Rinsing:

In this state, Washing machine is rinsing the clothes. The input variable condition to enter this state is

water = 1;

The washing machine is in this state for 20 sec.

Drying:

In this state, Washing machine drying the clothes. The input variable condition to enter this state is

water = 1;

The washing machine is in this state for 10 sec.

System end state:

In this state, Washing machine has washed the clothes. This ends the process.

2. Gear Simulation:

The gear has following states

  1. Idle
  2. Gear1
  3. Gear2
  4. Gear3
  5. Gear4
  6. Gear5

INPUT:

Slider gain: To give the input during simulation time (Minimum value = 0; Maximum value = 300)

Variable: speed

Output:

Display: to display the gear number

variable : Gear

Blocks:

Idle state:

The condition for this state is

speed = 0

Gear 1:

The condition for this state is

speed = 0 to 15

Gear 2:

The condition for this state is

speed = 16 to 25

Gear 3:

The condition for this state is

speed = 26 to 40

Gear 4:

The condition for this state is

speed = 41 to 60

Gear 5:

The condition for this state is

speed = Above 60.

Attachments: The simulink files for both the problems and the output images.

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.