Wednesday, December 18, 2019

Glass panels and Technically Advanced Airplanes (TAA)

People often want to track their time in aircraft with advanced avionics - often referred to as "glass" or "technically advanced airplanes" - for insurance, professional, or personal reasons.  In this post, I'll discuss MyFlightbook's support for this.

Like other aircraft-related attributes (complex, tailwheel, multi-engine, etc.), glass is an attribute of the aircraft used for a flight, and thus not something that you should ever need to log.  If you log time in an aircraft with a glass panel, then MyFlightbook will recognize that fact and allow you to search on it, providing a quick way to get totals in glass aircraft.

I should step back for a moment and point out that "glass" has never (to my knowledge) been formally defined, but "TAA" has; see my earlier blog post on TAA for more information about this.  Note that TAA is a strict subset of glass: all TAA aircraft MUST be glass (since it requires having a PFD and an MFD), but not all glass aircraft are TAA (e.g., a C-172 with a G1000 might not have an autopilot and thus would not be TAA)

Anyhow, most aircraft attributes that matter for logbooks are tracked at the model level because they are (essentially) immutable characteristics of that model, shared by every aircraft of that model.  E.g., a Boeing 737 is a multi-engine turbine aircraft, always; there are no piston versions, no fixed-gear 737's, and no single-engine versions (let's hope; that indicates an emergency).

Glass and TAA, however, are mutable.  I.e., going from steam to glass/TAA - or going from glass to TAA - is not an unusual transition.  For this reason, I need to have a hierarchy of capabilities, starting with the model and looking at the aircraft as needed.

To determine if an aircraft is glass or TAA, I use the following criteria:
  • If the model of the aircraft is flagged as being TAA, this means that every aircraft that has ever come off of the line is TAA, and therefore the aircraft MUST be TAA.  These aircraft cannot be upgraded on the Glass/TAA dimension.
  • If the model of the aircraft is flagged as being glass (every aircraft coming off the line has glass, but may not meet the TAA definition), then the aircraft is glass, but to determine TAA, I have to look at the aircraft itself.  These aircraft may be upgraded from glass to TAA, but obviously cannot be upgraded to glass since glass is the base configuration.
  • If the model may come from the factory in various configs, then I have to look at the individual aircraft.  For example, a C-172 S may or may not have steam gauges.  (Note: I'm not sure anybody is still buying a C-172 S with steam gauges any more, but the point is that if you tell me an aircraft is a C-172 S, I can't say with certainty if it has glass).  An aircraft of this model can be upgraded from steam to glass, or to TAA.
You can indicate whether a model is strictly glass or TAA by editing the model (requires using the website, not the iOS/Android app).  You can indicate that an aircraft has been upgraded by editing the aircraft.  In some models, the glass-only option has become so ubiquitous that it's become its own model on MyFlightbook.  E.g., there is in fact a "C-172 S/G-1000" model which is very specifically a factory-installed G-1000 version of the Skyhawk.  This is (not surprisingly) flagged as "glass only", whereas the vanilla "C-172 S" is not.

But upgrading an aircraft raises an interesting question: how to distinguish flights in the aircraft prior to the upgrade from flights after the upgrade?  When indicating an upgrade on MyFlightbook, you can optionally specify a date for the upgrade.  Flights before the upgrade will be treated as non-glass, and flights after the upgrade will be treated as glass/TAA (depending on the level of upgrade).  And if you ordered your specific aircraft with factory glass, just leave the date of upgrade blank; that will cause all flights in that aircraft to be treated as glass/TAA.

TAA time is now an option for FAA Commercial ratings in lieu of a complex aircraft; MyFlightbook can determine TAA time towards this rating based on the criteria described above.

Some people also wish to distinguish the kind of avionics that an aircraft has. I choose not to explicitly support the type of avionics because there are an unbounded numbers of possible configurations, with new ones introduced all the time.


So for this, I generally suggest making up tags like “#G1000#” or “#ENTEGRA#” and putting them into the private notes of your aircraft.  You can then search for “#G1000#” and the result would be all of your time in aircraft that are tagged #G1000#.  (Note that there’s nothing magical about the “#” prefix/suffix; I just suggest it as a convention because it avoids false positives when searching).  So if you want to see all of your glass time with G-1000 avionics, you could search for "#G1000#" and the resulting totals will reflect your G-1000 time.

Tuesday, December 3, 2019

User Created Airports

If you've created airports on MyFlightbook, well, first, "thank-you" - you're helping MyFlightbook have a very thorough (and living!) airport database!

But you may notice a few changes regarding your airports recently (early December 2019).
I've finally gone in and built a tool that lets me review user-created airports that might be duplicates of existing airports. It's always a challenge as airports are closed, new airports are opened (or assigned re-used codes), or airports move from one location to another. But I also want to avoid things like "JFKIA" (an airport somebody created to be "JFK International Airport") being coincident with KJFK and getting picked up as the nearest airport by the GPS.

So I've built a tool that lets me review all user-created airports (or seaports/heliports) that might be coincident with an existing airport (seaport/heliport) and decide what to do. I have several (not-mutually-exclusive) choices in these cases:
  • If both the new and the existing airport are legitimate (E.g., "EGLL" and "LHR" are ICAO and IATA, respectively, for London Heathrow), then I will actually "absorb" the airport. I.e., I will remove your name as the creator of the airport, and it will be treated as a native airport. It will no longer show up as one of your airports.  Thank-you for your contribution!!!
  • I will typically mark one of the two codes (usually the 4-letter ICAO code), in the above scenario, as being "preferred". That way, if you're somewhere at the airport and use the app to read the closest airport, it will be equally close to multiple codes; this allows me to bias towards the code that is least likely to have ambiguity (which is why it's typically ICAO). Or, if one of the codes is an obsolete code, it can use the newer code.
  • I can also coalesce the precise latitude/longitude between the two airports, so that multiple codes are equally close.  This helps to avoid the mobile apps picking up EGLL on one side of Heathrow airport and LHR on the other.
  • d) Finally - and this is relatively rare, but I've done it with a few dozen airports - I can delete your airports. Usually this is due to a typo (e.g., I've seen codes that mix up a capital-O with a zero), but it can also be due to a made-up code when there is a legitimate ICAO/IATA code that applies. If I delete your airport, the tool will automatically map any flights that use the old code to instead use the new code. This doesn't violate any signed flights (route is excluded from the change detection), but it obviously does mean some minor changes to your logbook.
The mobile apps can't update their airport databases over the net; instead, every few months when I'm updating the mobile apps I'll update the airport database as well, so it can take a few months before these changes will show on the mobile apps. But all of the changes are live on the website today (and ongoing).

Thursday, November 7, 2019

Local Time part II

In an earlier blog post, I discussed the challenges of supporting local times on the MyFlightbook website. 

The short summary of the problem is that it's critical that all underlying times be UTC, in order to enable any math or computation determining length of flight or duty periods or similar.  The blog post described why I don't support import/export using anything other than UTC, and why I don't store local times in the database.

However, it is possible to provide support for data entry and editing in a local time zone, just as the mobile apps do.  The idea (as the mobile apps do) is that you convert any UTC time to local time when putting it into an editable field, and then convert back to UTC when committing the edit (i.e., when saving or updating the flight). 

iOS and Android always know their current offset from UTC - i.e., the offset at the time and place where you are making the edit.  This is fine, as the iOS and Android apps are generally optimized for data entry in-the-moment (e.g., during or shortly after your flight) rather than bulk entry of historical flights.

Web browsers, sadly do not provide time zone information.  I can get the current offset from UTC for the user's browser (and only after the first request - too late for the first page that is requested!), but I cannot get a name for the timezone (thus enabling, for example, "EDT" for "Eastern Daylight Time"), nor any rules around daylight saving time

But all is not lost, and today I released a new feature that allows you, if you like, to declare a preferred time zone.  (Go to Profile->Preferences->Flight Entry).  This applies on the web only, and will allow you to enter/edit times in the specified time zone.

If you enable anything other than "UTC", then all of the time fields that usually have a "UTC" label or description will change to say "Custom TZ"; you can hover over this to see which time zone is in use; doing this will show you the standard offset from UTC, even if you are in daylight time, but any conversion should correctly account for standard/daylight time. 

As an aside: I use "Custom" rather than "Local" because "Local" is inherently ambiguous: e.g., if you live in Chicago, but you have a flight from LA to New York, is the "local time" Pacific, Central, or East Coast?  "Custom" here at least clarifies that it's one you've specified.  Why not use a 3-letter acronym like "EDT"?  Two reasons: (a) the acronyms don't span daylight/standard time.  E.g., EDT is specifically daylight time, but in August you probably would want EST, so you'd have to use the more ambiguous "ET" and (b) more practically, the system doesn't provide a set of acronyms for the ~139 timezones in the system.

There's actually an additional benefit here that goes one better than the iOS/Android apps: by specifying a timezone, the daylight time rules are encapsulated.  So if it is August 8 and I'm transcribing a flight from February that was at 1pm Pacific time, that will be correctly converted to 9PM UTC (Pacific Time in February is Pacific Standard Time, which is UTC-8) but a similar flight from May would be 8PM UTC. 

I am only doing this for editing times; I am still sticking with UTC for all display purposes, such as printing or displaying details of a flight in the logbook list.  Not only does it avoid ambiguity to do so, but it also removes the need to display the timezone (and as mentioned above, the system doesn't provide me with a short abbreviation for the time zone names, so it would literally have to display something horrendously long like "Pacific Time (US & Canada)" (i.e., the name of the timezone) next to each time.

Sunday, October 6, 2019

"Total Time" and "Total Flight Time"

I have a confession to make.  I use the term "Total Time" liberally throughout MyFlightbook for the "bottom-line" time of a flight entry.  The problem is, that phrase is not really defined, and could be used by a given pilot to refer to either Pilot Time or Total Flight Time.

These are not quite the same thing.  Per 61.51(j), (in the US at least), Flight Time is in "an aircraft".  No training devices are listed here.  Pilot Time, on the other hand, is what contributes to total aeronautical experience (per 61.1(b)), and it is a superset of Flight Time and appropriate Sim time.

That is to say, if you have 100 hours in an actual flying machine aircraft, 20 hours in a certified level-D full-motion simulator, and 30 hours playing Microsoft Flight Simulator, then you properly have a Total Flight Time of 100 hours, and a total Pilot Time of 120 hours.

When MyFlightbook reports a "Total Time", it is a straight-line sum of that field (constrained by any search criteria you specify); it is not distinguishing sim time from real aircraft; it's not even excluding any time you logged there in uncertified sims like Microsoft Flight Sim.  (MyFlightbook does, however, separate these all out in the 8710 form) So if you log time in a sim in the "Total Time" field, you are adding to your Pilot Time, not to your Flight Time.

As I mentioned in a previous post regarding sims, my best advice here is to leave the "Total Time" field blank when not recording time in an actual flying machine; instead, put any sim time into the "Ground Sim" field (or ground instruction into the "Ground Instruction" property, using any aircraft you like).

So if it's a bad idea, then why do I allow people to put time into the "Total Time" field for sims?  Three reasons:
  • Some pilots are using this to count Pilot Time.  
  • Under other non-FAA regulatory environments, it can sometimes be counted towards flight time.
  • Many pilots do catch-up flights to carry-forward time from paper or other logbooks; as this would be a mix of sim and actual aircraft time, I allow people to mix these.

But there's a third reason people will log this: credit towards aeronautical experience.  For example, a requirement for an ATP rating (61.159) in the US is 1,500 hours of aeronautical experience.  But 61.159(a)(6) allows up to 100 hours of this 1,500 hours to be acquired in an appropriate training device, so many pilots view this as allowing them to "count" up to 100 hours in sims towards their total time.


If you do this, then you are following the "Pilot Time" rule - that's OK, but if someone asks you for your total Flight Time, you need to back out your sim time.

I think, however, that the "correct" (can I use "correct" and "I think" in the same sentence?  Sure, I'll allow it...) way to interpret the aeronautical experience requirement in 61.159 here is "The sum of your Flight Time and MIN(100, time in an FTD or FFS under appropriate rules) is at least 1,500 hours". 

MyFlightbook does know about this substitution and applies it to FTDs and FFSs (under the assumption that you're doing it under a part 121/135/141/142 training course) when reporting your progress towards the ATP rating, so it is not necessary to explicitly add total time for these sim sessions in order to receive credit.  And, in fact, to avoid double-counting, a given flight actually credits MAX(Ground Sim, Total Time), in case you logged both.

So I'll repeat my advice: to keep things clean, only log "Total Time" for flights that are in an actual aircraft.

Thursday, October 3, 2019

Local time

What time is it?  Generally, there are two answers to that question: what time is it where I am, and what time is it in UTC (Zulu).

All times in MyFlightbook are in Zulu (UTC) time, for a pretty obvious reason: it's the only way to do computations.  If you depart at 4PM EST and land at 7PM PST, you're flight was 6 hours long, not 3, after all; as with all math, you need to use common units.  And in order to compute things like night flight, one needs to know the position of the sun relative to the horizon at a given latitude/longitude and time - and thus the time needs to also be in a common unit system.

The iOS and Android apps on MyFlightbook have an option to use local time.  When this is selected, all the times are still in UTC.  The only difference is in the display.  So in the example above, if you enter "4PM" while you are in New York (EST = UTC-4), that goes into the database as 8PM UTC (2000Z).  When you land at 7PM in LA (PST=UTC-7), that 7PM goes into the database as 2AM (0200Z) the next day.

What's interesting is that if you go and look at your New York departure time after your landing in LA, it will no longer say 4PM - it will say 1PM.  Why?  Because you're now in LA, and it's displaying the unmodified 2000Z departure time in PST, (2000Z-0700=1300PST).  Note that the underlying time is invariant; only the display has changed.

That works well on the device, which typically always knows its location and its timezone offset.  It also works for times that are either entered in UTC, or which are entered relative to your current time zone offset.

But the key thing is that the local time option always works based on *where you are* *right now*.  I.e., it's not based on the time or location of the flight data, it's based on your time and location as the viewer of that data.

Unfortunately, converting from local time to UTC - especially for other than the "right here, right now" case - is a significantly more complicated problem.

E.g., if you are going through old flights and want to log something that departed ABC at 4PM local and arrived at DEF at 7PM local on Oct 23, 1997, you need to know the timezone offset for ABC and for DEF on those dates, including if/when Daylight Saving time is observed (and, if it is observed, when the cut-over dates are)

This is absolutely a solvable problem, but requires a lot of data and it requires maintenance of that data.  Specifically, it requires:
  • A database of geographic boundaries of each time zone, including changes over time.
  • A database of daylight saving time rules, including changes in those rules over time.
So to compute, say, total time for a flight with local departure/arrival times specified:
  • Look up the latitude/longitude of the departure or arrival airport on the date of departure/arrival
  • Find the appropriate time zone based on those coordinates
  • Determine whether or not to apply daylight saving time based on the date of flight, taking care of the time of arrival (since a flight can span the typical 2am-local transition to/from daylight saving time)
  • Adjust the local times based on the offsets computed above.
MyFlightbook does not do the above conversions.  Why?  Money.  There are services which can do precisely the computations above, but because of the large data set and the maintenance required to keep up with ever changing timezone rules, these are not free.  As a free service, it's dangerous for me to offer functionality that could result in unbounded potential expense.

For this reason, my suggestion is to convert local time to UTC before entering historical flights.

Monday, September 2, 2019

EASA currency and license revalidation

I did some updates over the past few days to better support EASA currency rules.

For a while, I've supported EASA LAPL (FCL.140) rules, which can be turned on in preferences on the website. 

If you turn this option on, I also default to EASA PPL rules where appropriate rather than FAA rules for regular passenger currency.  The EASA PPL rules (FCL.060) for carrying passengers are basically the same as the FAA rules (3 takeoffs+landings within 90 days), but they differ for night:
  • Whereas FAA rules require 3 takeoffs and landings to a full-stop between 1 hour after sunset and 1 hour before sunrise, the EASA rules require only one takeoff/landing, and it doesn't have to be to a full stop.
  • If you have an instrument rating, EASA imposes no particular night requirement.
The way that I've implemented this is that I look for a night takeoff and either a full-stop night night landing or a night touch-and-go landing within the past 90 days.  But if I see any evidence that you have an instrument rating, such as an instrument checkride, an IPC, or one of a few other things that qualify as an IPC, then I don't bother reporting night currency because it is then identical to (and thus redundant with) your regular FCL.060 passenger-carrying currency.

Note that I said "if you hold an instrument rating", not "if you have a valid instrument rating", or "if you have an instrument rating for the category or class".  The regulation is worded thusly:

(b) Aeroplanes, helicopters, powered-lift, airships and sailplanes. A pilot shall not operate an aircraft in commercial air transport or carrying passengers:
(1) …; and
(2) as PIC at night unless he/she:
(i) has carried out in the preceding 90 days at least 1 take-off, approach and landing at night as a pilot flying in an aircraft of the same type or class or an FFS representing that type or class; or
(ii) holds an IR;
(b)(2)(ii) above simply says "holds an IR", with no other qualifier, so I am treating that as being unqualified.

Another key difference in EASA land vs. FAA rules is that FAA ratings don't expire, but EASA ratings do need to be re-validated periodically.  This is like the FAA requirement to have a flight review.  But EASA adds a wrinkle to this: you need to do the validation within the 3 calendar months prior to the expiration of your rating. 

So, for example: suppose your rating expires Sept 30 2019 and is good for a year.  If you did your validation flight on July 15, 2019, then your rating is now good until Sept 30 2020; in effect, you can have as long as 15 calendar months as a result.  But if you did your validation flight on May 15, 2019, then your rating is now extended only until May 31 2020.

As a result, it is impossible to predict when a validation is required without knowing when your rating expires, which means that there is no way to escape having you enter those expiration dates somewhere.  And since the number of possible ratings is unbounded (due to type ratings), I can't enumerate the set of due dates that you need.

So here is my recommendation for dealing with re-validation of EASA ratings:
  • For each rating that you hold that requires re-validation, create a custom deadline (Profile->Preferences->Deadlines) that reflects the date by which the validation is due.  This will then show up in your currency.  Set it up to automatically extend by 12 or 24 calendar months, as appropriate.
  • When you do the re-validation, update the deadline to reflect the new date.  This will allow you to handle the 3 month window for performing the validation.
  • If you like, you can also set up a custom currency rule that looks for a flight review or IPC (to indicate revalidation) in an appropriate set of category, class, or model.  This will use a date extending by 12/24 calendar months, where you might actually be entitled to more, but at least this will give you a conservative date.
  • Note that re-validation of simple SEP ratings can be accomplished essentially by remaining current via LAPL rules, so you can track that simply by tracking your LAPL currency.

Friday, July 19, 2019

Rounding and totals

Minutes and decimals don't always play nicely together, since minutes are a denominator of 60 when converted to decimal.

As a result, someone will occasionally catch what appears to be a math error.

Consider these totals, and the three flights that make it up that a pilot sent me this past week:

At first glance, this looks incorrect, since 1.37+1.70+1.32=4.39, not 4.38.  But it's actually the best math that I can do, given that I want to keep per-minute accuracy.
In this case, both 4.38 hours (=262.8 minutes) and 4.39 hours (=263.4 minutes) both round to 263 minutes, which then converts to 4.383333333 hours, which displays as 4.38 since I round to two decimal places.

So the good news is that the rounding is only ever off by a hundredth of an hour here or there, and it cancels out statistically.  

Actually, I can make a stronger statement: I deliberately maintain to-the-minute accuracy at all stages - including in totals - but I don't promise to maintain sub-minute accuracy.

Here's where it's worth getting into some of the esoterica, but the important thing is that I'm actually optimizing for the math to always work in the hours:minutes space over the decimal space.

In order to do this, I convert the decimal to hours/minutes before adding. So, for example, 1.32 hours is 79.2 minutes.  I round that to 79 (nearest minute) and then divide back by 60 to get the hours input to the totals, which is 1.31666667 hours.

So in the example above,

Flight, As Logged    Flight, rounded to nearest minute
1.37 1.366666667
1.7 1.7
1.32 1.316666667
Total, Logged:   Total, rounded:
4.39 4.383333333


The left column above is raw addition of the values as entered.  The right column has each of those numbers multiplied by 60 (to get minutes), rounded, and then converted back to hours.  That sums up to 4.38333, or 4.38 hours.  Because each of the numbers in the right column represents a precise minute count, the sum represents a precise minute count, so no minutes are lost or added; this is why I can make the claim that all values are accurate to-the-minute.

Doing it this way keeps the math working regardless of whether you use hh:mm (hours:minutes) or decimal hours. 

It's worth noting that if you're using decimal and only use one decimal place (which is 6 minutes), then there's no rounding issue whatsoever, since 6 minutes precisely equals 0.1 hour.  In hh:mm format, though, you need at least two decimal places to capture all 60 possible minutes in an hour.  But conversely, 2 digits actually gives you 100, not just 60, possible slices of an hour, so there's inevitably some rounding that happens somewhere.

Computers and databases only store so many digits of precision - I chose 2 digits because it's enough to accurately handle minutes in hh:mm.   The conversion I do above (multiplying by 60 and then rounding to get whole minutes) restores as many digits of precision as the computer can handle, which will always be enough for any actual logbook to not have any rounding errors.

Some logbooks store all times under-the-covers as minutes and divide by 60 in the display; that works fine (it's exactly the same as doing the right-hand column above without the division by 60), but it too would have rounding issues.  After all, imagine if you entered 1.31 hours (=78.6 minutes which becomes 79 if you're storing minutes in the database).  When reading from the database and converting for decimal display, that would display as 79 / 60 = 1.3166667 = 1.32 hours.

Yet another alternative is to store lots of digits of precision in the database, but that has its own problems: the math works fine, but putting long decimals into fields you can edit can be cumbersome for you, the user, and leads to other problems as well.  E.g., that 1.316666667 number above is too large to fit in many fields on a screen so it would need to get truncated to, say,
1.3167 - and if you then read that field back (for example, when updating a flight) then presto, you've lost the very precision you were trying to preserve.

So it's an interesting anomaly of decimal display that sometimes the hundredth's-place digit in totals appears to be off.  But yes: since I can promise that all numbers - both at the individual flight level and in totals - are accurate to the minute, then I can also promise that any accumulated rounding error - using to-the-minute flights - is also less than one-sixtieth of an hour.  And since .02 is more than one-sixtieth, and I only have two decimal places, any such rounding discrepancy (I shouldn't even call it "error") should thus actually be limited to 0.01.  And in hh:mm display, there will be no such rounding discrepancy.

UPDATE AUG 2023: I've just taken out an option to let you explicitly use hundredths-of-an-hour.  Same rules apply: all numbers are rounded to the nearest 100th of an hour before being added.  

Note that if you choose this options, then the "error" will go the other way.  

For example, imagine you have 3 40-minute flights.  That's 2/3 of an hour.  You can enter them as 0.67 each, or 0:40 in hh:mm format; it doesn't matter - they're stored as 0.67 under the covers.  

Using per-minute math, these get converted to ROUND(0.67 x 60) / 60 = ROUND(40.2) / 60 = 40 / 60 = 0.6666666666667.  Add these up and you get 2.00 - which makes sense, since 3 x 40 minutes = 120 minutes.

Now switch to hundredths of an hour you look at your totals.  ROUND(0.67 * 100) /100 is just ... 0.67.  And 0.67 + 0.67 + 0.67 is 2.01.  So that will display as 2.01 using decimal, or (since 0.01 is 36 seconds) as 2:01 in hh:mm.

It's all a function of where you want the rounding to occur.

I still default to per-minute math because I think it makes more sense - after all, if you look at your watch or your phone to see "what time is it", you're typically not looking at the seconds, so you're truncating to the nearest minute anyhow.  I.e., your 40 minute flight was probably not 0:40:00...

But now you can change it.

Tuesday, June 18, 2019

Flight Templates

MyFlightbook has over 640 different "flight properties" (with new ones added all the time!), which are attributes that you can add to a flight, describing everything from Aircraft Carrier landings to Zero-visibility Takeoffs.  The idea is that any given pilot, on any given flight, uses only a tiny subset of these properties.  This, of course, presents a clutter problem: how do you manage such a large set of potential options?  Historically, I've done this automatically, showing you those properties that you've used before, with an option to explicitly exclude ones you no longer need.

Today, I'm adding new "template" functionality.  The idea is that you can define templates for various sorts of flights, and choose the template that is appropriate for a given entry.  E.g., if you fly for the airlines during the week, but fly gliders on the weekend, you can load up one template for each kind of flight, optimized with the fields you need most of the time.

A template is really nothing more than a collection of flight properties.  You can define your own templates, or choose from a library of templates authored by other pilots.  There are also a few "automatic" templates that the system makes available and applies automatically (discussed below):

Creating Templates

You can define templates by going to "Preferences" under the Profile tab on the website and expanding the "Flight Properties" section.  You'll see a list of your current templates:



Possibly the easiest way to get going with templates is to choose one from a library of templates shared by other pilots.  If you click "Brows available templates", you can browse this library and copy any that you like into your account.

If nothing in the library suits your needs, you can create a new template:

You can give your template a name, a description, and a category.  Then you'll see two lists.  On the left are the set of available properties; on the right are the properties in your template.  Drag-and-drop from left to right to select the properties you want (or from right to left to remove a property you no longer want).  You can also type in the search box to quickly filter properties by name.

The "Category" of a template is just a grouping mechanism.  At the moment, there are 5 categories, though I may add more over time if it makes sense.  Current categories are:
  • Automatic - These are implemented by the system; you can't create these.
  • Training - Flights where you are honing specific skills, such as performing aerobatic maneuvers or instrument approaches, go here.
  • Lesson Plans - Use for flights that are following a specific lesson of a syllabus.
  • Checkrides and Reviews - checkrides and other periodic flights to ensure proficiency like a regulatory/company/club-mandated periodic review of flight skills
  • Missions - Specific purposes for a flight might go here.  E.g., fire fighting, search-and-rescue, charity flights, and so forth.
  • Roles - These are for templates that vary based on your role in a given flight - e.g., are you PIC or SIC? Instructor or student?

Once you save the template, it is available for use.
The two checkboxes in the image above warrant additional explanation:
  • Checking the "Shared" checkbox makes the template available for other pilots; unchecking it removes it from the library of templates.  If you have made a template that works well for your scenario and might work for others, then I strongly encourage you to please check this box!
  • "Use by default" tells the system that you want that template's properties to appear by default for new flights.

Using Templates

Great, you've defined some templates.  So how do you use them?

On the website, you'll see a downward-facing arrow to the right of where you can select properties today:

When you click that arrow, you'll see the set of templates from which you can choose.  As you turn templates on or off, you'll see the set of properties displayed for editing change accordingly.  (Note: if you have any property that has a non-empty value, it will always be displayed, regardless of template selection.

You can choose from the set of templates that you've defined, plus the automatic templates I mentioned earlier.  At the moment, there are three of these:
  • Previously Used - This matches the pre-template functionality.  It contains all of the properties that you've used on prior flights, minus the ones you've explicitly excluded (in Preferences).  This is what is used if you don't check the "Use by default" box for any other templates.
  • Simulator / Training Device (Basic) - this is automatically selected whenever you choose a simulator as the aircraft for a flight.  It (currently) adds two properties ("Ground Instruction Received" and "Simulator/Training Device Identifier") to whatever other properties you are using.
  • Anonymous Aircraft (Basic) - this is automatically selected whenever you choose an anonymous aircraft, and adds a property ("Aircraft Registration") where you can record the specific aircraft used for a flight.
The iOS and Android apps are now updated as well to include template functionality.  On the iOS app, tap the information icon on the right side of the Properties header to view available templates (you may need to refresh your property list for this).  On Android, there is a "View Flight Templates" menu item.  The apps respect default templates, but to create/edit templates you do need to use the website.

"Power template tips"

  • Templates are not mutually exclusive - you can use more than one at a time, or specify that more than one should be used by default.  E.g., if you're a CFII, you might create an "Instrument Flight" template and an "Instructor" template and use them both at the same time.
  • You can attach a template to an aircraft.  Tap on the downward-facing arrow to the right of the aircraft (on the website) and you'll see any templates you've defined.  Whenever you select that aircraft for a flight, the specified template(s) will be used.  For example, if you fly aerobatics in one plane, but not in others, you might define an aerobatic template and use it for flights in that aircraft, but not clutter up flights with aerobatic maneuvers you won't perform in other aircraft:

  • The mobile apps refresh templates from the website when they download properties, which happens periodically.  You can force a refresh, though, by doing pull-to-refresh (try to scroll past the top of the screen) while viewing templates or properties.
Please send me any feedback about templates, and please share any useful ones that you create!

Tuesday, May 28, 2019

What constitutes a "valid" flight entry?

With any data system, one must be prepared to do validation on the data that goes in.  A logbook is no exception to that rule.

It turns out, though, that there are surprisingly few validation checks that can be universally applied to a flight - there are a lot of things that look like an error in some scenarios, but which are perfectly valid in others.

An example that I am asked about frequently is that the system does not flag flights where Dual plus PIC plus SIC does not equal Total time.  For much of flying in much of the world, that equation is satisfied, but (in particular) it is not here in the US, where you can simultaneously log Dual and PIC if you're appropriately rated for the aircraft yet receiving instruction.

Probably the most common scenario where a flight frustrates data validation is "catch-up" flights, where you make one or more entries in your logbook to represent totals from prior (typically paper) logbooks.  Such flights typically include large numbers (larger than any single flight could actually have), and a mix of things that might be difficult or impossible to do in a typical actual wheels-up-to-wheels-down scenario.

Over the years, it seems that whenever I put in a validation check, I soon find counter examples of perfectly acceptable flight entries that violate my rule.

So in an evolutionary process of "survival of the fittest", here are the checks that have withstood the test of time:

  • Valid aircraft - every flight must be associated with an aircraft (even if no actual flying was done; you can generally use any aircraft you like for ground sessions - since the times are zero, any aircraft will work).  This is because the aircraft's model determines all sorts of attributes about the flight, such as the category/class, whether it was complex or high performance or turbine, etc.
  • No negative numbers.  I've yet to find a scenario where negative numbers are allowed.
  • Hobbs start after hobbs end.  (I don't currently validate tach time because I don't currently perform any computations on tach time).
  • Flight start after flight end or engine start after engine end (I don’t currently validate block time) 
  • Full-stop night landings + full stop day landings greater than the total landings (unless total landings is 0, in which case I auto-fill it)
  • Full-stop Night landings indicated without any night flight.
  • Night takeoffs at towered airports + night takeoffs at non-towered airport (which, kinda by definition, is all of the possible night takeoffs) is greater than total night takeoffs
  • More described approaches (e.g., a property indicating two ILS approaches) than logged approaches
  • Comments or Route field too long (13K and 128 characters, respectively)
  • Date before 1900 or more than 2 days from "right now" in Pacific time

Wednesday, May 15, 2019

International functionality Part 3: Functionality

In my previous two posts, I discussed how internationalization affects languages and regional conventions; in this third and final post, I will discuss actual functional changes that vary based on different jurisdictions.

While most software functionality does not vary worldwide (think Microsoft Office or the Chrome browser, which do the exact same things wherever they are), other software must be responsive to local markets and the rules, regulations or conventions therein, which means actual changes in functionality depending on where you are.  While aviation is largely harmonized across the world, it is nevertheless governed by each country and that results in a wide variety of rules.

At one level, simple logging of data is not really dependent on local rules.  After all, what you did on a flight is what you did regardless of where you are. The complexities tend to arise when performing things computations or reports on that data.

A challenge here compared to the language or regional conventions discussed in the prior two posts is that those can typically be determined automatically.  But functional rules generally need to be declared explicitly, because it is not uncommon for someone in one jurisdiction to follow the rules from another jurisdiction.  As a result, all of the functionality I'll describe here are things that are configured explicitly (generally in Profile->Preferences on the website)

Probably the most important (or visible) functionality that can vary is currency rules. By default, MyFlightbook implements US (FAA) rules.  MyFlightbook does also support Canada currency and EASA LAPL (European Light Plane) currency rules.

The FAA "groups" currency by category/class/type, so if you do your takeoffs and landings in a Piper Archer, you're current in a Cessna 172 as well, and vice versa.  But some countries require currency to be specific in a model: you need to have performed your takeoffs and landings in that model in order to be current in that model.  MyFlightbook supports either model.  You can also choose to view your totals grouped by category/class/total, or by model.

Different countries have different certification rules for pilots.  In addition to FAA rules, MyFlightbook supports some EASA, Canadian, and Australian ratings.  Adding new ratings is generally pretty straightforward, so if you can point me to a reference document, send it my way and I'll see what I can do.

Another visible place where different regional conventions are on display is in printing formats.  Some regions, like the US, specify what you should record, but make no particular recommendation on the form or layout in which it is displayed.  Others (Europe) can be very prescriptive (see prior posts about printing here and here).  MyFlightbook currently supports layouts that approximate the EASA standard, as well as layouts that conform to typical layouts in South Africa, Canada, and New Zealand.  If you have an additional layout, send it to me; it's generally pretty easy to add.

There are a few other bits of functionality that, while not strictly international or regulatory, do tend to correlate with region:
  • Input or display of times in decimal vs. hour:minute (HH:MM) format.  You can turn this setting off/on in Profile->Preferences on the website, or in settings on the mobile apps.
  • How night flight and night landings are computed.  You can set this on the web site next to the "autofill" button, or in settings on the mobile apps.  Night can be computed based on sunrise/sunset, or an offset from the start/end of civil twilight.  Night landings can either be anything at night, or 1 hour offset from sunrise/sunset.
  • On the mobile apps, you can also adjust how total flight time is computed from flight/block/engine times.

I'm a US-based pilot and fly on FAA conventions, so that's what I know best, but my goal is for MyFlightbook to be useful to pilots worldwide.  I hope this series of posts help explain MyFlightbook's international support, and I hope you'll contact me if there's any functionality you'd like to see (or bugs I need to fix!)

International functionality Part 2: Local conventions

In my last post I discussed how MyFlightbook handles different languages.  In this one, I will discuss how MyFlightbook handles regional differences.

Language and Region are independent variables.  E.g., English is spoken in both the US and the UK, but we express our dates differently.  I am writing this on May 15, 2019.  In the US, the short form of that date would be written 5/15/2019 (i.e., month/day/year), but in the UK, it would be 15/5/2019 (day/month/year).

Besides dates, there are several other conventions that vary based on locale:
  • Times.  E.g., by default is 4:15pm expressed  as "4:15 PM" or as "16:15"?
  • Decimal points and thousands separators.  E.g., one-thousand two-hundred fifty-two and a half would be "1,252.5" in the US or "1 252,5" in France.
  • List separators: typically a comma or a semicolon.  This is particularly important for CSV
  • Currency symbols.  Obviously, the US uses $, but Europe uses €
All modern operating systems provide services that software like MyFlightbook can use that makes all of this automatic and transparent.  MyFlightbook uses those services, so all conventions should be followed appropriately.

The trick is to ensure that MyFlightbook knows which region should be used.

For the apps on iOS or Android, you can set your device's region by going into the device's settings app.  There's a language and region area where you can set both the preferred language (as discussed in the last post, the iOS and Android apps are translated into French as well as English) and your preferred region.  Most people do not need to do anything here because their device comes pre-configured for their language and region.

The website gets slightly more complicated because it is one instance of the software that is running on a machine in the US (in the cloud somewhere; I actually have no idea where), so it is using US conventions, but it needs to service people from all over the world.  How to solve this?

Whenever your browser requests a page, it sends a list of language-region codes along with the request.  A language region code looks like "en-us": the "en" part means it is requesting English language, and the "us" part means it wants to use US conventions.

The list of these codes is in priority order.  So a request might include the following list: "en-us", "en-gb", "fr-ca", "fr-fr".  This tells the server that English is preferred, then French.  And that the preferred regions are US if possible, then UK ("gb" = "Great Britain"), followed by Canada, then France.

Note that this is sent by the browser, so if you are using a Windows or Mac OS with, say, French Canadian conventions, but your browser is set up for English/US, then you will get English.  The MyFlightbook server can't see your OS's settings, it can only see what the browser sends.

This can be set in various ways, depending on the browser.  In Chrome, you'd go to settings (using the menu or the URL chrome://settings/), then go to advanced, and you can specify language/region there:

In Firefox, you'd go to Options (or about:preferences) and find Languages from there:



In my next post, I'll talk about regional functionality.

International functionality Part 1: Languages

In the software world from which I come (I'm an alum of Microsoft and Expedia), we would think of internationalization along three dimensions: translation into a local language, localization to use local conventions, and functionality that varies by locale.  I figured it might be worth a discussion of how MyFlightbook breaks down along these dimensions.

I'll talk about each of these in successive blog posts, starting here with the first: translation.

Translation is pretty straightforward, albeit very lightly implemented.  While I know varying degrees of several languages, I'm essentially monolingual.  The fact that English is the world-wide language of aviation certainly makes it easier for MyFlightbook to get away with being all English than for other software programs, but nevertheless I am rigorous about ensuring that all of the code - whether on the website or in the mobile apps - can be localized and is not tied to English, even if much of the time English happens to be the only available language. 

In fact, thanks to a French-speaking user who did the initial translation (and Google Translate, which helped with subsequent translations, which might be humorous, but I wouldn't know...), the iOS and Android apps are entirely bi-lingual.  If you set your iOS or Android device to use French, the MyFlightbook UI will appear in French.

It's not seamless, however: much of the text used in display does come from the server, and the server is only lightly translated.  So if you are using French settings, you may still see English inserted in numerous places because that text derives from the database or from the web site (which only has a few pages translated.)

The key thing, though, is that the code is structured to be easily translated.  Specifically, this means that all text is kept outside of the code and loaded (based on language) as it is needed.  Keeping the text separate from the code makes translation easier, since a linguist can take a file with text in it and just go through and translate each item, without having to have any coding capabilities.  And it means that new languages can be added simply by adding appropriate translated text files.

If anybody is interested in helping to translate the website, all of the text is separate from the code, so it's pretty straightforward to do.  (It's just a lot of text...)

Supporting different languages actually goes beyond just translation, though, particularly since MyFlightbook *pilots* speak and use a huge variety of languages.  Most of this is pretty transparent - the system uses Unicode so it can handle data in Kanji, Hindi, Hebrew, Arabic, etc. without any issues.  The main thing that the code needs to handle here is right-to-left languages like Hebrew or Arabic and ensuring that the appropriate alignment occurs based on language (i.e., not hardcoding left or right alignment, but instead keying off of the language).


In my next post, I'll talk about localization.

Wednesday, May 1, 2019

Drones and MyFlightbook

Probably the fastest growing area in aviation these days is in the unmanned aerial system ("UAS", aka "unmanned aerial vehicle" or "UAV", or more colloquially, "drone") space.  And many UAS pilots are using MyFlightbook to record their flights.

MyFlightbook supports UAS as a psuedo-category/class.  E.g., as a peer to AMEL or Helicopter.  You can create UAS aircraft using one of many UAS models on the system, and include drone flights next to manned flights.  Since they are separate category/class, flights in one should not pollute things like currency or totals in the other.

Of course, since these are flights in your logbook, any times you record will accrue in your totals.  But alas, it's also easy to back these out, if you like, by using the search functionality.

There are a variety of flight properties that are in the system today that are focused on UAS scenarios.  As of this writing (more are added all the time!), the system has the following:

Property NameDescription
UAS - AutonomousIndicates that the flight was an autonomous UAS flight
UAS - Hand-held TransmitterIndicates that the UAS flight was controlled by a hand-held transmitter
UAS - Lost Link ReturnIndicates that the UAS executed return procedures after a loss of communication
UAS LaunchesNumber of times that a UAS (drone) was launched
UAS RecoveriesNumber of times that a UAS (drone) was recovered
UAS: Air Vehicle Operator TimeTime spent operating a drone
UAS: Mission Payload Operator TimeTime spent managing the paylod in a drone
UAS: Ground Control Station TimeTime spent in ground control for a drone
UAS: Maritime Flight HoursTime spent flying a drone (UAS) over water
UAS: Electro-Optical Sensor TimeTime spent using an electro-optical sensor (drone/UAS)
UAS: Infrared Sensor TimeTime spent using an infrared sensor (drone/UAS)
UAS: Short Wave Infrared Sensor TimeTime spent using a short-wave infrared sensor (drone/UAS)
UAS: Medium Wave Infrared Sensor TimeTime spent using a medium-wave infrared sensor (drone/UAS)
UAS: Synthetic Aperture Radar Sensor TimeTime spent using a synthetic aperture operations with a drone (UAS)
UAS: Hyperspectral Imaging Sensor TimeTime spent doing imaging (hyperspectral) with a drone (UAS)
UAS: Multispectral Imaging Sensor TimeTime spent doing imaging (multispectral) with a drone (UAS)
UAS: Signals Intelligence TimeTime spent doing signals intelligence with a drone (UAS)
UAS - 107.73 - Aeronautical Knowledge TestIndicates that the pilot took and passed a knowledge test (initial or recurrent) covering the areas specified in 107.73
UAS - 107.74 - Training CourseIndicates that the pilot successfully passed a training course (initial or recurrent) covering the areas specified in 107.74


As part of ensuring that unmanned aircraft are utilized safely - and don't conflict with manned aircraft! - the FAA introduced part 14CFR107, governing unmanned systems. 107.65, in particular, defines recent experience required to operate a UAS under many circumstances.  It works like currency, except that it focuses on recent knowledge training rather than flight experience.

To be current per 107.65, you must have done one of the following three things in the preceding 24-calendar months:
  • Pass an initial knowledge test, 
  • Pass a recurrent knowledge test, or 
  • Have a valid flight review (of the manned flight variety, per 61.56) and take a knowledge course.

To indicate that you have done either of the first items above, add an entry into your logbook with the "UAS - 107.73 - Aeronautical Knowledge Test" property; if you take the appropriate course, add an entry with the "UAS - 107.74 Training Course" property.  And, of course, if you are a licensed pilot of manned aircraft, you'll want to show that you have a valid flight review anyhow; you can do this by adding a property to the appropriate flight: "Flight Review," "BFR", or one or the various checkrides that qualify.


MyFlightbook will show (and update) 107 currency once you have met any of the requirements above.