Skip to content

Instantly share code, notes, and snippets.

@deliastephens
Last active June 11, 2019 17:05
Show Gist options
  • Save deliastephens/a7144b50509f97a37b59a5e540ffdf5c to your computer and use it in GitHub Desktop.
Save deliastephens/a7144b50509f97a37b59a5e540ffdf5c to your computer and use it in GitHub Desktop.
PhoenixRC Build Notes

Custom Models for PhoenixRC

My first task this summer was to build a model of the Bormatec MAJA for use in the PhoenixRC flight simulation software. This is a German-made long-range aerial surveillance vehicle with a pusher propeller and an extremely large wingspan. The problem with this drone, however, is that I lack the confidence to fly it; it’s big, expensive, heavy, and not entirely stable (though it does have stabilization, it was recommended we fly without it. I’m still not entirely sure how I feel about this).

This project is a ground-up discovery of the functions of Solidworks, Blender, and other modeling techniques. I’m coming in with 0 training, background knowledge, and experience, so most likely things will not be done as efficiently as they could possibly be.

The Body

The first thing that I decided to reconstruct was the main body. While I don’t yet have the dimensions, I used a reference image as seen here:

Bormatec MAJA Side view
For now, I was OK with my scale being a little bit off, because I thought it would be simple to rescale things in Solidworks (this ended up being about 50% true, but more on that later).

I ended up with something that looked kind of like this:

MAJA Body First Draft

The Wings

My next task was crafting the wings. Luckily (or perhaps unluckily, because this means the MAJA is going to land pretty fast), the MAJA has no dihedral. Previous tests with the model of the Silent But Deadly showed me that for some reason I struggle to calculate dihedral, so I was grateful that these wings seem comparatively similar.

One interesting thing about the MAJA is the presence of winglets on the side of the wings. I’m not exactly sure why they’re there: perhaps they are present to help with wingtip vortices, or maybe they give the viewer a stronger visual indication of the orientation of the plane. But they were fun to model anyways.

To model the wings, I ended up using the Spline tool along the reference image. I then duplicated the side plane a half-span away, shrank my first Spline by a somewhat arbitrary amount, and did a lofted boss between the two.

I wasn’t sure exactly how to stick the wings onto the body of the drone, so I ended making a small extruded boss on the bottom. A later task is to give that small extrusion an angle, because I’m not a huge fan of the aerodynamics right now.

I spent a whole semester studying fluid flow over the wings of an aircraft, so as an exercise I might run a Solidworks simulation and do some math of my own later; for right now, though, I’ve got some wings.
MAJA Wings First Draft

The Propeller and Motor

The Bormaket MAJA uses a 300W motor with a 10x6 propeller. My first task is modeling the 10x6 propeller.

Because I didn’t understand exactly what these two numbers meant, I turned to the Internet. Here is an excellent discussion of what those numbers mean; a key takeaway is that my propeller has a diameter of 10 inches and will travel forward 6 inches for every complete turn of the propeller in some theoretical environment.
Discussion of what "pitch" means.
Again, here is an in-depth description of the physics behind a propeller. It’s an interesting read, but also entirely nonessential for understanding how to model one.

Eventually, I concluded that making a really nice, detailed model of the propeller wasn’t exactly what I needed for this project; while I’m here to learn about Solidworks, I don’t want to spent a long time doing something I don’t need to do.
Prop

Stabilizers

These two parts were fairly simple and similar to make. I started by using the Spline tool to create some symmetric airfoils. Then, in the case of the vertical, I duplicated that curve and did a lofted boss/base between the two. In the case of the horizontal, I just created an extruded boss out from my symmetric airfoil.
Vertical stabilizer
Horizontal Stabilizer

Assembly

After that, I had to stick all of these parts together. Because of the reference image I used to create my propeller, I had some scale issues; the propeller was about 6 times larger than the rest of the body. Online references indicated that there was some way to scale parts from within the assembly, but I found myself unable to do that and instead opened up each part and scaled it after I found a value that seemed to work (it was 6, for reference). Most likely, I will need to rescale and make some other edits as I do a more detailed comparison to the actual MAJA.

Here’s the assembled version, before control surfaces:

Drone Assembly

Control Surfaces

The next thing I had to do was add in control surfaces. Based on some quick experimentation done with my Silent But Deadly model, it’s best if each control surface is its own parts so PhoenixRC can get the correct geometry and collision meshes.

What I decided to do was split the parts and add a fillet onto the stabilizer to avoid collisions as the parts moved up and down. I don’t know if this is the best way to do this, but it produced reasonably decent results the first time I did it.

I then realized that splitting parts would create a lot more parts, which would ultimately change my assembly. This was a tragic realization, but I had to continue (because I didn’t know how to do it any other way).

Splitting the wing was fairly difficult; I was eventually able to split the wing by creating two planes, one above and one below the wing. I then sketched a box on each of these planes and split the body using these features.

This is what I ended up with.

Assembly with Control Surfaces
Assembly Drawing

I’m not super proud of it, and it’s not perfect, but it’s definitely a start! The next part that I’ll have to do is get the model ready to go into PhoenixRC. This is a somewhat complicated process that involves putting the model into Blender, resizing, and exporting a mesh.

Changing Materials

After a while, I realized it would be a good idea to change the materials. I thought that perhaps this would change the texture (it didn’t), but it was entertaining and I was able to add control surfaces in a better way using this technique.

A Better Model

Blender

The next thing I had to do was stick my model into Blender. This is a multi-step process:

  1. Export the assembly as a bunch of STLs.
  2. In Blender, File -- Import -- Stl, and Shift - M1 to import multiple STLs. Important settings: y-forward, z-up, 1/4000
  3. Set all of the meshes to have their parents as the body of the plane. I’m not sure if the master parents matters, but the body is the simplest part and also should contain the center of gravity, so this is what I chose to do.
    Blender Parenting
  4. Next, I had to play with scale for a while in Blender. I then opted to not try to texture the model simply because I didn’t know if it would work, and I didn’t want to waste time texturing an (all black) model anyways.

Aside: I experimented with changing the model material in Solidworks simply because that was a little bit easier. It was at this point that I realized I actually had a better way of making the wing control surfaces. This meant that I ended up totally recreating the assembly with new wing pieces.

  1. Okay, so now I had an untextured model in blender. Sweet. I then exported that model as a .obj, sent it over to the other computer, and got working.

Putting the Model into PhoenixRC

This next bit is honestly not that interesting and involves a bunch of nonsense in PhoenixRC Builder.

Lessons Learned

  • If you group all the objects together, it becomes easier to apply a scale (and scaling in Blender doesn’t mean you’ll have a correctly scaled model: I ended up multiplying by about 100 to get the appropriate size.
  • PhoenixRC has lots of stuff already baked in (collisions, physics, etc.). This is nice, but it means that there’s a lot of stuff to tune that I don’t fully understand.

PhoenixBuilder

The process generally went like this:

  1. Import Mesh, select all bodies and group them together in Geometry.
  2. Scale appropriately.
  3. Rename all bodies under Model so that the name is a little more illustrative.
  4. Texture if you want.
  5. Give the model a material and then give it a center of mass.
  6. Create airfoils and control surfaces for wings, stabilizer, and fin.
  7. Create the prop, spinner model.
  8. Give airfoil, control surfaces, and prop geometries by selecting the appropriate mesh from the Model - Geometry section and dropping it into the thing you want to
  9. Add collision meshes so the plane will crash if it hits the ground (which sounds bad but is actually good).

Tuning

I noticed that my plane was really freaking nose heavy. I knew that the center of gravity had to be somewhere behind the wing, so I decided to change the elevator trim a little bit to help combat this issue (for reference, -3 deg).

I then jacked up the thrust and lift to 300%, their maximum possible values, because the drone seemed to be struggling to generate enough lift.

I also raised the difficulty to 100% to make the drone more difficult to fly; this increased the sensitivity of the controls. If you can fly and land the plane with Phoenix, then you can fly and land the plane with anything.

This seemed to help a little bit with the overall flight characteristics of the model, but I think it might make sense to perhaps reduce the thrust a little bit.

Conclusions

Now I have a sweet untextured model hanging out in PhoenixRC. We can use this to train to fly the Bormatec MAJA, which is most certainly not a beginner’s drone. It is this way because of the payload requirements; I believe that the original designers put the wings so far back to make it easier to load payload into the front of the plane. This also explains the far back center of gravity issue when the plane is unloaded; it is designed to carry cameras and other instrumentation in the nose.

I learned a lot about Solidworks, Blender, and 3D Modeling in the process of creating this drone; I feel way more confident with these technologies than I did before, and I’d like to create some really bizarre models and stick them in to Phoenix.

Special thanks to rickp ,who created this really fantastic guide for putting custom models into PhoenixRC. He also has a ton of other custom models, which are fun to poke around with and experiment with.

Potential Continuations

  1. Texture the model with Blender.
  2. Design a flight program so that people can get trained on the new drone. (aside: make a logbook file so each pilot can train and understand).
  3. Figure out differences between the motors.
  4. Continue tuning the model.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment