Challenge

Week - 4

TASK-1:

AIM:

'To implement control logic of a washing machine using Stateflow in Simulink'.

OBJECTIVE:

  1. implementing the control logic of a washing machine using stateflow logic as required :

a) If the power supply is accessible, the framework gets actuated.

b) If the Water supply isn't accessible, stop the interaction and demonstrate through LED.

c) Soaking time ought to be 200s trailed by Washing season of 100s.

d) Then flushing occurs for next 20s and dryer runs for 50s.

After every one of the cycles have finished turn on the completed LED.

MODEL:

The file which contains the model is attached with this report.

Pictorial Representation of Block Diagram from simulink:

Chart Diagram:

Parameters:

We have given waterv, soak, wvashing, rinsning, dryer, and cycle as Outputs of the chart.

We have given our water_supply & power_supply as Inputs of the chart.

Simulation Time parameters:

We used 400 sec so that it can cover the whole cycle and sufficient time to store and solve the parameters.

OUTPUT:

There are two conditions asked to solve in the question.

Condition-1: when Water Supply is OFF.

We should not provide a water supply and check for output.

From the above diagram, We can see that indicator of water is showing Red i.e., When there is no water supply the process is terminated and LED indicator is used to indicate that state.

Condition-2: when Water Supply is ON.

Now we are providing the water supply and checking the output.

As we can observe from teh above figure, All the states have been executed and indicating the Process completion indicator (named as cycle) showing Green.

CONCLUSION:

  • The simulation of the Washing machine using State flow is done and the result is as expected

-------------------------------------------------------------------------------------------

TASK-2:

AIM:

'To make a Simulink chart for the “Gear shift” logic'.

OBJECTIVE:

Making a simulink chart for the Gear Shift for the below mentioned paramters:

Speed Range(kmph) Gear

0 to 15 1

16 to 25 2

26 to 40 3

41 to 60 4

Above 61 5

MODEL:

The file which contatins the model of Gear Shift is attached with this report.

block diagram of model:

chart diagram:

parameters:

Here we give Speed as an Input for the chart.

Here we give Speed as an Output for the chart.

Simulation Time parameters:

Here we gave time as 'Inf' for our simulation should run until we stop it.

INPUT:

We use slider gain to provide input to the chart.

I'm changing my speed values from 0 to 100 using slider gain during the simulation.

OUTPUT:

The Output produced is recorded when it's displaying the each gear.

Gear-1:

Speed range: 0 to 15kmph.

Input speed: 6kmph.

Gear-2:

Speed range: 16 to 25kmph.

Input speed: 19kmph.

Gear-3:

Speed range: 26 to 40kmph.

Input speed: 31kmph.

Gear-4:

Speed range: 41 to 60kmph.

Input speed: 58kmph.

Gear-5:

Speed range: above 60kmph.

Input speed: 71kmph.

CONCLUSION:

  • Created a State Flow for Gear Shift using Simulink and the results are satisfactory.
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.

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.