X-Plane is a flight simulator for Mac OS X and Windows, produced by Laminar Research. X-Plane is packaged with other software to build and customize aircraft and scenery, offering a complete flight simulation environment.
X-Plane also has a plunging architecture that allows users to create their own modules, extending the functionality of the software by letting users create their own worlds or replicas of places on earth. It comes with five scenery disks, and one with scenery and the actual simulator.
Simulation is an important phase in aircraft designing process either it is used to predict the Characteristics of the system research the man-machine interface or even for licensing, certification and accident investigations. Thus now a day a lot of flight simulation tools have being developed for fulfilling those various purposes .One of those tools is a well known PC-based flight simulator called X-Plane. Despite of its packaging as a popular computer game, X-Plane used a series of engineering tools and equations to simulate its aircraft collections, and even more, X-Plane can also generate a new aircraft model based on geometry input from users. With those advanced capability, X-Plane begin to be widely used by aerospace researchers from designing from scratches until the flight simulation phase.
A screenshot of the X-Plane 9 flight simulator used to illustrate the article on the simulator itself
The Monarch butterfly
Design in Nature:
When the subject of flight is considered, birds immediately come to mind. However, birds are not the only creatures that can fly. Many species of insects are equipped with flight capabilities superior to those of birds. The Monarch butterfly can fly from North America to the interior of Continental America. Flies and dragonflies can remain suspended in the air.
5-3-2011 07-58-27 PM.png
Flawless Flying Machines: Birds
The question of how the flawless structure of wings might have been formed through a series of consecutive random mutations remains completely unanswered. The process in which the front leg of a reptile could transform into a flawless wing seems to be as inexplicable as ever. Furthermore, the existence of wings is not the only prerequisite for a land creature to become a bird. Land-dwelling animals totally lack a number of Mechanisms that are used by birds in flying. For example, the bones of birds are considerably lighter than those of land-dwelling animals. Their lungs are
of a different structure and function as well as are their skeletal and muscular structures. Their circulatory systems are much more specialized than those of land animals. All of these mechanisms could not possibly come into existence over time through an “accumulative process”. Assertions of the transformation of land-dwelling animals into birds are, therefore, only nonsensical claims.
The strength of a bird’s skeleton is more than adequate even though the bones are hollow. For example, a hawfinch 7 inches long (18 cm) exerts about 151 lbs. (68.5 kg) pressure in order to crack open an olive seed. Better “organised” than land animals, the shoulder, hip and chest bones of birds.
The System of Balance:
Allah has created birds without flaw just as He has the rest of the
Creation. This fact is manifest in every detail. The bodies of birds have been
Created to a special design that removes any possible imbalance in flight. The
Bird’s head has been deliberately created light in weight so that the animal
Does not lean forward during flight: on average, a bird’s head weight is
About 1% of its body weight.
The aerodynamic structure of the feathers is another property of the
System of balance in birds. The feathers, especially in the wing and tail,
Provide a very effective system of balance for the bird.
These features ensure that a falcon maintains absolute balance while
Diving for its prey at a speed of 240 mph (384 km/h).
The OSI Model:
5-3-2011 12-06-28 PM.png
The OSI model is an architectural model that represents networking
Layer 7. Provides an entrance point for programs such as Web
browsers and e-mail systems to gain access to network services. This
layer does not represent programs such as Microsoft Office Word or
Microsoft Office Excel®. This layer represents application
programming interfaces (APIs) that developers can use to perform
network functions when building applications.
Layer 6. Translates data between different computing systems on a
network. The presentation layer translates the data generated by the
application layer from its own syntax into a common transport syntax
suitable for transmission over a network. When the data arrives at the
receiving computer, the presentation layer on the receiving computer
translates the syntax into the computer’s own syntax
Layer 5. Enables two applications to create a persistent
communication connection. This layer ensures that both the sender
and the receiver are ready to communicate. The session layer can also
set checkpoints in the communication process to ensure that it can be
restarted if communication is interrupted.
Layer 4. Ensures that packets are delivered in the order in which they
are sent and without loss or duplication. On the sending side, this
layer is responsible for breaking down larger messages into smaller
packets for transmission on the network. On the receiving side, this
layer is responsible for reassembling the packets into a single message
to pass up to the session layer.
Layer 3. Determines the physical path of the data to be transmitted
based on the network conditions, the priority of service, and other
factors. This is the only layer of the OSI model that uses logical
networking and can move packets between different networks.
Layer 2. Provides error-free transfer of data frames from one
computer to another over the physical layer. The media access control
(MAC) address of a network card exists at this layer and is added to
the packet to create a frame.
In the context of the OSI reference model, a frame is an electronic
envelope of information that includes the packet and other information
that is added by the seven layers of the OSI model.
The data-link layer is responsible for determining when the frame will
be sent on the network and then passing the data to the physical layer.
Data is passed from the data-link layer to the physical layer as a
stream of 1s and 0s.
Layer 1. Establishes the physical interface and mechanisms for
placing a raw stream of data bits on the network cabling.
As each bit of information is received from the data-link layer, the
physical layer converts it to an appropriate format and transmits it on
the network. On a wired network, each bit is translated into an
electrical signal. On a fiber optic network, each bit is translated into a
The TCP/IP Protocol Suite:
5-3-2011 08-11-35 PM.png
TCP/IP is an industry-standard suite of protocols that provides communication
in a heterogeneous environment. The tasks that are involved in using TCP/IP in
the communication process are distributed between protocols that are organized
Into four distinct layers of the TCP/IP stack.
The four layers of the TCP/IP protocol stack are:
1- The application layer.
2- The transport layer.
3- The Internet layer.
4- The network interface layer.
THE Application layer:
5-3-2011 08-17-05 PM.png
The application layer corresponds to the application, presentation, and session
Layers of the OSI model. This layer provides services and utilities that enable
Applications to access network resources.
The application layer corresponds to the application, presentation, and session layers of the OSI model. This layer provides services and utilities that enable applications to access network resources.
Hypertext Transfer Protocol. Specifies the client/server interaction processes between Web browsers and Web servers.
File Transfer Protocol. Performs file transfers and basic file management tasks on remote computers.
Simple Mail Transfer Protocol. Carries e-mail messages between servers and from clients to servers.
Domain Name System. Resolves Internet host names to IP addresses for network communications.
Post Office Protocol version 3. Used by mail clients for reading e-mail.
Simple Network Management Protocol. Enables you to collect information about network devices such as hubs, routers, and bridges. Each piece of information to be collected about a device is defined in a Management Information Base (MIB).
The transport layer corresponds to the transport layer of the OSI model and is responsible for guaranteed delivery and end-to-end communication using one of two protocols described in the following table.
Transmission Control Protocol. Provides connection-oriented reliable communications for applications. Connection-oriented communication confirms that the destination is ready to receive data before sending. TCP confirms that all packets are received to make communication reliable. Reliable communication is desired in most cases and is used by most applications. Web servers, FTP clients, and other applications that move large amounts of data use TCP.
User Datagram Protocol. Provides connectionless and unreliable communication. Reliable delivery is the responsibility of the application when UDP is used. Applications use UDP for faster communication with less overhead than TCP. Applications such as streaming audio and video use UDP so that a single missing packet will not delay playback. UDP is also used by applications that send small amounts of data, such as DNS name lookups.
The Internet layer corresponds to the network layer of the OSI model. The protocols at this layer encapsulate transport-layer data into units called datagrams, address them, and route them to their destinations.
There are four protocols at the Internet layer:
Internet Protocol. Addresses and routes packets between hosts and networks.
Address Resolution Protocol. Obtains hardware addresses of hosts located on the same physical network.
Internet Group Management Protocol. Manages host membership in IP multicast groups.
Internet Control Message Protocol. Sends messages and reports errors regarding the delivery of a packet.
Network interface layer:
The network interface layer (sometimes referred to as the link layer or data-link layer) corresponds to the data-link and physical layers of the OSI model. This layer specifies the requirements for sending and receiving packets on the network media. This layer is often not formally considered part of the TCP/IP protocol suite because the tasks are performed by the combination of the
Network card driver and the network card.
User Datagram Protocol (UDP):
This User Datagram Protocol (UDP) is defined to make available a datagram mode of packet-switched computer communication in the environment of an interconnected set of computer networks. This
Protocol assumes that the Internet Protocol (IP) is used as the
Underlying protocol. This protocol provides a procedure for application programs to send messages to other programs with a minimum of protocol mechanism. The protocol is transaction oriented, and delivery and duplicate protection are not guaranteed. Applications requiring ordered reliable delivery of streams of data should use the Transmission Control Protocol (TCP).
5-4-2011 08-27-16 AM.png
Source Port is an optional field, when meaningful, it indicates the port of the sending process, and may be assumed to be the port to which a reply should be addressed in the absence of any other information. If not used, a value of zero is inserted.
Destination Port has a meaning within the context of a particular
Internet destination address. Length is the length in octets of this user datagram including this header and the data.
(This means the minimum value of the length is eight.)
Checksum is the 16-bit one’s complement of the one’s complement sum of a
Pseudo header of information from the IP header, the UDP header, and the
Data, padded with zero octets at the end (if necessary) to make a
Multiple of two octets. The pseudo header conceptually prefixed to the UDP header contains the source address, the destination address, the protocol, and the UDP length. This information gives protection against misrouted datagrams. This checksum procedure is the same as is used in TCP.
5-4-2011 08-35-42 AM.png
If the computed checksum is zero, it is transmitted as all ones (the
Equivalent in one’s complement arithmetic). An all zero transmitted
Checksum value means that the transmitter generated no checksum
(for debugging or for higher level protocols that don’t care).
The UDP module must be able to determine the source and destination
Internet addresses and the protocol field from the internet header. One
Possible UDP/IP interface would return the whole internet datagram
Including the entire internet header in response to a receive operation.
Such an interface would also allow the UDP to pass a full internet
Datagram complete with header to the IP to send. The IP would verify
Certain fields for consistency and compute the internet header checksum.
Flight dynamics is the science of air vehicle orientation and control in three dimensions. The three critical flight dynamics parameters are the angles of rotation in three dimensions about the vehicle’s center of mass, known as pitch, roll and yaw.
The three Aircraft principal axes:
Lateral axis (pitch):
The lateral axis passes through the plane from wingtip to wingtip. Rotation about this axis is called pitch. Pitch changes the vertical direction the aircraft’s nose is pointing. The elevators are the primary control of pitch. Also called Transverse axis.
Longitudinal axis (roll):
The longitudinal axis passes through the plane from nose to tail. Rotation about this axis is called bank or roll. Bank changes the orientation of the aircraft’s wings with respect to the downward force of gravity. The pilot changes bank angle by increasing the lift on one wing and decreasing it on the other. This differential lift causes bank rotation around the longitudinal axis. The ailerons are the primary control of bank.
Vertical axis (yaw):
Yaw axis is a vertical axis through an aircraft, rocket, or similar body, about which the body yaws; it may be a body, wind, or stability axis. Also known as yawing axis.
The yaw axis is defined to be perpendicular to the body of the wings with its origin at the center of gravity and directed towards the bottom of the aircraft. A yaw motion is a movement of the nose of the aircraft from side to side. The pitch axis is perpendicular to the yaw axis and is parallel to the body of the wings with its origin at the center of gravity and directed towards the right wing tip. A pitch motion is an up or down movement of the nose of the aircraft. The roll axis is perpendicular to the other two axes with its origin at the center of gravity, and is directed towards the nose of the aircraft. A rolling motion is an up and down movement of the wing tips of the aircraft
In analyzing the dynamics, we are concerned both with rotation and translation of this axis set with respect to a fixed inertial frame.
For all practical purposes a local Earth axis set is used, this has X and Y axis in the local horizontal plane, usually with the x-axis coinciding with the projection of the velocity vector at the start of the motion, on to this plane.
The z axis is vertical, pointing generally towards the Earth’s center, completing an orthogonal set.
In general, the body axes are not aligned with the Earth axes.
The body orientation may be defined by three Euler angles, the Tait-Bryan rotations, a quaternion, or a direction cosine matrix (rotation matrix). A rotation matrix is particularly convenient for converting velocity, force, angular velocity, and torque vectors between body and Earth coordinate frames.
Design and Implementation:
X-Plane is a PC-Based flight simulator tool that can predict and simulate an aircraft performances based on the geometry, weight and engine power.
The computation process is basically used the blade element theory and various other real engineering techniques. Moreover, X-Plane had features that allows user to build his own new aircraft, and fly it in an environment, which can also be defined by user. Now a day, because of its nature using the real engineering methods, X-Plane had been used by various aircraft manufacturers and designers to evaluate new design ideas on the personal computers before the planes are flown for real reducing a lot of flight testing cost. The industrial version of X-Plane even had received an FAA certification (Federal Aviation Administration) as an aircraft designing tool.
1- Two computers communicating with each others.
2- Ethernet port using UDP protocol.
3- Flight simulator X-plane.
X-Plane had four methods to let the users accesses the flight data, which are by screen visualization on X-Plane, by flight parameter time-plotting on X-Plane, by generating a text file of flight data, and by send the data through internet by UDP. There are total 124 flight data.
The plan for carrying out this project is as follows:
1- I will connect 2 Pc one with x-plane and the other with Matlab
using Ethernet UDP Protocol.
2- Design a program to see the result in Matlab.
Building up the Matlab/Simulink – X-Plane :
The basic idea of this work is to change the state space model
(x’=Ax+Bu, y=Cx+Du) of B747-400 on the Matlab/Simulink with the X-Plane model of B747-400. That’s mean transferring the elevator deflection calculated on Matlab/Simulink to be the input for X-Plane model, and transferring the speed, angle of attack, pitch and pitch rate from X-Plane into the Matlab/Simulink model. The UDP protocol using internet connection is a common method that both software (Matlab/Simulink and X-Plane)
Accommodate. This simulation system will involve two computer connected via a
Normal LAN cable.
UDP Setup on X-Plane:
The setup on X-Plane is done in the “setting/data input & outputâ€¦” window, selecting the first box of flight data which is the selection of data that will be sent via internet. Which are the elapsed times, the speed, the angular velocities, the Euler angle (pitch, yaw, and roll) and the Angle of Attack, respectively? The UDP rate of the sending data is set to maximum, approximately 100 data per second.
UDP Setup on Matlab/Simulink:
Matlab/Simulink provides a UDP data exchange on its PC Target/UDP toolbox. The Matlab/Simulink elevator deflection data is processed to be a UDP data by the Pack block and send to x plane on the other computer by the UDP Send Binary Block. The Data from X-Plane from the other computer is received using the UDP Receive Binary block, and being unpack as a readable data by the Unpack block. Matlab/Simulink will send the elevator deflection data to X-Plane, while the X-Plane will send the outputs, including the pitch angle that will be used for the feedback of the system. Those data need to be converts in the way the other software could read it in their own way.
Because X-Plane required the elevator deflection in percent of degree, it is needed to include the maximum and minimum deflection of B747-400. For simplicity, it will be assume that the maximum/minimum deflection of the elevator is + 25o
The Pitch-Hold Control System Model for Matlab/Simulink and X-Plane:
This model is basically the same as before when it was purposes for work on Matlab/Simulink only. The difference is the plane model. Here it is used a block named X-Plane Longitudinal Model (internal combustion engine in which the crankshaft is oriented along the long axis of the vehicle, front to back).
The initial condition of the flight on X-Plane is arranged to be equal of the condition on which the state space dynamic model the reference pitch is changeable depending on the simulation configuration. All the output data will be send to the PH_Output for next processing. The elevator deflection and the Pitch can be observed directly from the Display blocks. On the X-Plane computer.
Pitch-Hold Control System for Boeing 747-400 State Space Model:
Boeing 747-400 is a well known aircraft with a lot of references on its performances, which is the default aircraft on the X-Plane system. Based on those natures, this aircraft is chosen to be the subject.
5-19-2011 03-38-41 PM.png
5-19-2011 03-34-58 PM.png
5-19-2011 03-33-15 PM.png
5-19-2011 03-33-43 PM.png
5-19-2011 03-41-37 PM.png
Pitch Hold Control System Model on
X-Plane can be used to simulate an auto pilot system, in this case, a pitch-hold system that been designed using the State-Space model in Matlab/Simulink The auto pilot system is injected into the X-Plane aircraft model using UDP via internet connection. X-Plane can give a good three dimensional video visualization that is also interactive. The X-Plane model shows a matching result of time response with the simulation using State-Space model, for various input of pitch reference. The less smooth curve compared to the State-Space model proved that X-Plane use a non-linier model of Aircraft. The un-matching time response for the unstable gain for X-Plane and State-Space model might caused by the elevator constraint which is not considered on the State-Space model simulation on this paper. It is possible a better match for the simulations could be achieved using an optimum control system design, rather than just a classical method control system design method.
Cite This Work
To export a reference to this article please select a referencing style below: