Archive for December, 2010

Cmarc Body Modeling

Cmarc by Aerologic is a tool for computational fluid dynamics.  The data generated by this program can be used to determine the flight properties of an aircraft, and with additional work can help determine the stability as well.  However, defining the geometry for the aircraft without the Aerlogic Loftsman tool is a difficult task.  This is due to the need to mesh various objects together when they intersect.  As with many things there are many ways to go wrong during this process and only one way to get it right.

Of particular interest is the connection between the aircraft’s body and the wing.  For the purposes of this project the case of wing attached to the top of a cylindrical body was explored.  The wing has no dihedral at the intersection and only the bottom of the wing touches the body.  The project was built to serve as an extension to Mavl with the code described below all being contained within a new class.

The geometry of the body is defined by two text files.  The first file contains the longitudinal profile (X-Z Plane) of the body as shown below.


The second file defines the lateral profile (Y-Z Plane) of the body.  The coordinates for this experiment were defined in polar coordinates to simplify the creation of the definition file.  Because the section is assumed to be mirrored, only 180 degrees of the profile is defined.  The result is the straight line shown below.


This provides all the information needed to then extrude the lateral profile along the longitudinal profile to create the body.  The next task was to detect an intersection with the wing and alter the body accordingly.  This task must be performed at each slice that intersects.  The first section of this code flags the first point that is higher than the bottom of the wing.  Assuming the body to be a flat between any two points, the exact point of intersection can be found easily.  Knowing this, the angle between the top of the profile and the intersection can be determined.  This determines the angle at which the first point must be located.  The remaining angle is divided equally amongst the remaining points that need to be drawn (The number of points in the body profiles must remain constant along the entire body).  Because the points are equally spaced, any areas of increased resolution in the original profile will be lost.  The resulting body points are displayed in matlab as shown below with the points common to the wing shown in blue.

When the process is done correctly, Cmarc will be able to load and process the geometry.  The result can be viewed using Aerologic’s Postmarc program.  Two such views are shown below.
From the these views it can be seen that the body is being split as it goes under the wing, and then rejoins at the trailing edge.
The next step will be to apply the body’s cutout to the wing.  This will create a seamless joint between the two bodies.  There are also a two of areas in the code where the assumption of a cylinder was used to get this code to a working state.  Removing those assumptions will require a few more hours of work.
The end results is that creating a meshed body is now a process that can be completed in an hour.  A significant improvement over the days to weeks it might take otherwise.

Telemetry Flight

One of the goals with getting the Ardupilot Mega (APM) is to have a means of collecting telemetry information during the flight of an aircraft.  This will have immediate uses during the spring when we start flight testing the senior design aircraft.


Keeping with this goal I took my aircraft with the APM on-board out for another test flight.  Yesterday’s attempt at telemetry gathering was defeated by a lack of  a defined procedure, so before going out the system was run up on the ground.  With this procedure in mind the same steps were performed at the field.  The result was the telemetry pictured above.  The data confirmed observations of the flight that winds above the tree line were fairly high.  This is shown by the close spacing of the data points on the up wind leg.  The flight was short and the temperatures were freezing, but the data is a significant step in the right direction.

Ardupilot Mega

On Thursday the various pieces of my Ardupilot Mega (APM) arrived.  I decided that the APM was worth the expense.  At a minimum the APM will serve as a good practice for working with autonomous systems.  For the past two days I have been reading the manual, assembling, testing, and installing the autopilot on my aircraft.


In January 2010 I flew a few test flights with the original Ardupilot, however the autopilot was shelved due to a number of issues.  The most prominent issue was that the autopilot was designed with the ability to override the safety switch.  After efforts to find and cut the trace on the board that allowed this function failed the autopilot was not flown again.  Additional efforts to resolve this issue might have been made if the autopilot did not also suffer from poor performance.  The design of the APM fixes this problem allowing the safety pilot to take control at any time.

When purchasing the APM I decided that to avoid compatibility issues and to allow a fair evaluation of the system I would stick to using only components supported by the stock autopilot.  I am using the Mediatek GPS and have added the magnetometer and airspeed sensors to the APM.  I was a bit disappointed when I discovered that the magnetometer is not supported by the latest V1.0 APM software.

After the APM was bench-tested I took it outside for a series of telemetry gathering experiments.  So far I’ve conducted three flights to verify the safety switch and telemetry acquisition functions of the APM.  Unfortunately I have been unable to collect telemetry data in-air.  This may be due in part to my inexperience with the system or some other unknown issue.  To address this I’m working on a set of flight checklists and will be adding radio modems to the system.  This will allow the status of the system to be more easily assessed.

I am looking forward to working with the APM over this winter break and hope to achieve autonomous flight very shortly.  Almost more importantly, I plan to release test data benchmarking the APM against the Piccolo Autopilot.

Return top