Challenge

Project 2 - Implement the Code for controlling the retraction and extension of Airplane’s landing gear

Overview of the project:

In this project, controlling the retraction and extension of Airplane’s landing gear can be implemented using Finite State Machine (FSM). FSM is the most efficient algorithm which is mathematical model of computation.

Problem Statement:
Implement the Code for controlling the retraction and extension of Airplane’s landing gear

Description of the Hardware:

Actually an airplane has 3 gears for landing :
• Nose Gear
• Left Gear
• Right Gear
There is a hydraulic pump which is exerting pressure to the gears to bring it down or pull it up and that pump is electrically driven.

Limit switches:
Every leg of the gear has one limit switch.

Nose gear has one extra Squat Switch to determine whether the airplane is in ground or not.

Switch State State of Gears
Limit Switch CLOSED Gear is UP
Limit Switch OPENED Gear is DOWN
Switch State State of Airplane
Squat Switch CLOSED Airplane is grounded and Gears
are locked
Squat Switch OPENED Airplane is taking off / landing /
airborne

Consider this cases:
• There is a possibility that the plane is about to take off and emergency comes where pilot has to abort the take off
• When taking off,to ensure that its right time to raising the gear,check for at least 4 seconds that squat switch is open
Contant:
• When the airplane is parked at the bay and nose gear is down,then the nose gear is always experiencing a pressure on it due to airplane weight,weight of luggage and weight of passengers boarding on the airplane.Hydraulic mechanism is monitoring the pressure exerted on the nose gear and to neutralize that pressure its applying a pressure on the opposite direction

• Hydraulic Control can detect the rising edge and falling edge of pilot’s lever
• In case of Hydraulic system failure,there are two gas pressurized springs by which gears can be extended
• The case of failure of Squat Switch is ignored

key Highlights of the project:

A direction valve is controlled by the software to allow the hydraulic pressure to either raise or lower the landing gear.

In this project we have created NINE files.There are,

  • EIGHT ".c" file and ONE ".h" file.
  1. Checking befor landing.c file
  2. Checking befor takeoff.c file
  3. Gear down.c file
  4. Gear up.c file
  5. Init state machine.c file
  6. Lowering gear.c file
  7. Raising gear.c file
  8. Main.c file
  9. States.h file

Screenshot of Checking befor landing.c file code:

Screenshot of Checking befor takeoff.c file code:

Screenshot of Gear down.c file code:

Screenshot of Gear up.c file code:

Screenshot of Init state machine.c file code:

Screenshot of Lowering gear.c file code:

Screenshot of Raising gear.c file code:

Screenshot of Main.c file code:

Screenshot of States.h file code:

Scrrenshot of the output:

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.