Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Text Gauge - Sim Time

Featured Replies

Hello,

I would like to use th Text Gauge for StreamDeck using the AAO StreamDeck plugin.

I can find the variable for zulu time but it is in seconds.  What would I need to do to show whateve the current sim time is?

Thanks

  • Commercial Member
1 hour ago, IrwinMFletcher said:

I can find the variable for zulu time but it is in seconds.

Seconds is just the default unit, the simulator will convert the value internally when you use different units (like Hours or Minutes)

See here: Simulation Variable Units

Here is one way to do it
Select Type "S:" for Variable 1 
Put this code into the box:
%(E:ZULU TIME, Hours)%!02d! ':' scat %(E:ZULU TIME, minutes) (E:ZULU TIME, Hours) flr 60 * -%!02d! scat
Press "Submit"
 

LORBY-SI

  • Author

Thank you for the very detailed response.  I am learning!

I changed your code above a little in an attempt to display the local sim time.  IE:  When I go to the weather tab in MSFS 2024 and I change the game time to 15:09 (20:09 UTC) the code always displays the local time +5 hours (UTC Time)

%(E:LOCAL TIME, Hours)%!02d! ':' scat %(E:LOCAL TIME, minutes) (E:LOCAL TIME, Hours) flr 60 *  -%!02d! scat

Examples:

MSFS TIME     TIME DISPLAYED
03:09               08:09
14:54               20:54
13:28               18:28

I just want the clock time from the sim, whatever it is.

Thanks again!

  • Author

Ok, got it working.  Thanks for the assistance.  Out of curiosity, what 'language' is that bit of code from above, I want to go to YouTube University.

 

%(E:LOCAL TIME, Hours)%!02d! ':' scat %(E:LOCAL TIME, minutes) (E:LOCAL TIME, Hours) flr 60 *  -%!02d! scat

Thanks again.

  • Commercial Member
34 minutes ago, IrwinMFletcher said:

what 'language' is that bit of code from above, I want to go to YouTube University.

Unfortunately, this "language" is essentially MS flightsim specific.

The syntax is RPN (reverse polish notation) or more accurately "post-fix notation". This is very old tech. Because it is so close to how computers actually work, it was very common even until late in the 1980s.

But the operators in that code are mostly Microsoft flightsim specifc. This coding has been used in gauges and animations in the MS sims, at least since FSX, maybe FS9 even.

I chose this RPN language for the primary coding in AAOs scripting engine because the MSFS behavior code is also using RPN. Ideally people can directly use the code from the behavior debug dialog in MSFSs developer mode or from gauges etc.

The starting point would be the MSFS SDK documentation (or FSXs or P3Ds). Just be mindful that in AAO there are more operators and commands than in the spec (just because I can...) and that some more obscure code constructs are missing (because I decided that nobody needed them...).

Reverse Polish Notation

prepar3d.com/SDKv5/LearningCenter.php -> SDK -> Scripting -> RPN Scripting

Apart from RPN you can also use Javascript, JScript and VBScript in AAO - check out the AAO manual. 

 

Edited by Lorby_SI

LORBY-SI

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.