diff options
author | Marc Lichtman <marcll@vt.edu> | 2018-11-02 00:53:52 -0400 |
---|---|---|
committer | Marc L <marcll@vt.edu> | 2019-06-07 12:45:14 -0400 |
commit | 73b074f121b0ab2ac38336916a60891c4d88d2cb (patch) | |
tree | de8f1782c897af3c278c224dcfbf96345c5c6f1d /docs/doxygen/other/prefs.dox | |
parent | b6f15c59e96aa83142c47aeacd64da793dd8ba31 (diff) |
docs: moved usage manual to wiki
docs: first snapshot of wiki's usage manual
Diffstat (limited to 'docs/doxygen/other/prefs.dox')
-rw-r--r-- | docs/doxygen/other/prefs.dox | 96 |
1 files changed, 0 insertions, 96 deletions
diff --git a/docs/doxygen/other/prefs.dox b/docs/doxygen/other/prefs.dox deleted file mode 100644 index d8c2782b1d..0000000000 --- a/docs/doxygen/other/prefs.dox +++ /dev/null @@ -1,96 +0,0 @@ -# Copyright (C) 2017 Free Software Foundation, Inc. -# -# Permission is granted to copy, distribute and/or modify this document -# under the terms of the GNU Free Documentation License, Version 1.3 -# or any later version published by the Free Software Foundation; -# with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. -# A copy of the license is included in the section entitled "GNU -# Free Documentation License". - -/*! \page page_prefs Configuration files - -\section prefs Configuration / Preference Files - -GNU Radio defines some of its basic behavior through a set of -configuration files located in -${prefix}/etc/gnuradio/conf.d. Different components have different -files listed in here for the various properties. These will be read -once when starting a GNU Radio application, so updates during runtime -will not affect them. - -The configuration files use the following format: - -\code -# Stuff from section 1 -[section1] -var1 = value1 -var2 = value2 # value of 2 - -# Stuff from section 2 -[section2] -var3 = value3 -\endcode - -In this file, the hash mark ('#') indicates a comment and blank lines -are ignored. Section labels are defined inside square brackets as a -group distinguisher. All options must be associated with a section -name. The options are listed one per line with the option name is -given followed by an equals ('=') sign and then the value. - -All section and option names must not have white spaces. If a value -must have white space, the it MUST be put inside quotes. Any quoted -value will have its white space preserved and the quotes internally -will be stripped. As an example, on Apple desktops, an output device -of "Display Audio" is a possible output device and can be set as: - -\code -[audio_osx] -default_output_device = "Display Audio" -\endcode - -The result will pass Display Audio to the audio setup. - -The value of an option can be a string or number and retrieved through -a few different interfaces. There is a single preference object -created when GNU Radio is launched. In Python, you can get this by -making a new variable: - -\code -p = gr.prefs() -\endcode - -Similarly, in C++, we get a reference to the object by explicitly -calling for the singleton of the object: - -\code - prefs *p = prefs::singleton(); -\endcode - -The methods associated with this preferences object are (from class gr::prefs): - -\code - bool has_section(string section) - bool has_option(string section, string option) - string get_string(string section, string option, string default_val) - bool get_bool(string section, string option, bool default_val) - long get_long(string section, string option, long default_val) - double get_double(string section, string option, double default_val) -\endcode - -When setting a Boolean value, we can use 0, 1, "True", "true", -"False", "false", "On", "on", "Off", and "off". - -All configuration preferences in these files can also be overloaded by -an environmental variable. The environmental variable is named based -on the section and option name from the configuration file as: - -\code - GR_CONF_<SECTION>_<OPTION> = <value> -\endcode - -The "GR_CONF_" is a prefix to identify this as a GNU Radio -configuration variable and the section and option names are in -uppercase. The value is the same format that would be used in the -config file itself. - -*/ |