Skip to main content
Jump to: navigation, search

Papyrus-RT/User/User Guide/Tips

< Papyrus-RT‎ | User‎ | User Guide
Revision as of 09:11, 28 November 2016 by Charles.zeligsoft.com (Talk | contribs) (Initial page creation with first tip)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
PapyrusForRealTime-Logo-Icon.png




Tips & Tricks




Overview

This page contains usage tips and tricks for Papyrus for Real Time.

Logging

You may know that Papyrus-RT provides a logging mechanism, the "Log" service, that can be used within your model to output information from you model. By default, this information is sent to the standard error output, e.g., "stderr." So to see the output of the log, you can simply run your application from the command line and look at the output, e.g.,

./MyApp

You can also redirect the output to a file:

./MyApp</ >& myAppLog.log

You can also turn this on programmatically, in cases where you can not change the command line, e.g., for an application running on an embedded platform or if you want to selectively log parts of the execution.

This is done by using the "redirect" method (message) on the port:

log.redirect("mylog.log"); (where ""mylog.log" is the name of the file where the log will be written.)


Back to the top