diff options
author | Tom Rondeau <tom@trondeau.com> | 2014-04-15 18:20:29 -0400 |
---|---|---|
committer | Tom Rondeau <tom@trondeau.com> | 2014-04-15 18:36:04 -0400 |
commit | bbb03d35c01a73d24be4c946ad38d12ba7972ee3 (patch) | |
tree | 6b194514de2bd06b407d5b0f3b4d4fa0a1057907 /gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h | |
parent | 374832a7a63d71af80428e58bf9b12a8db986957 (diff) |
controlport: adding a 'toggle' interface for ControlPort.
This is very similar and accessed like a 'set' function only it does not take a parameter; it simply calls a function. Meant to toggle an action, like reseting the performance counters or locking/unlocking the flowgraph.
Diffstat (limited to 'gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h')
-rw-r--r-- | gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h b/gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h index 3d2d4cc79a..814749fe66 100644 --- a/gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h +++ b/gnuradio-runtime/include/gnuradio/rpccallbackregister_base.h @@ -1,9 +1,9 @@ /* -*- c++ -*- */ -/* +/* * Copyright 2012 Free Software Foundation, Inc. * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) @@ -28,7 +28,7 @@ typedef uint32_t DisplayType; -// DisplayType Plotting types +//! DisplayType Plotting types const uint32_t DISPNULL = 0x0000; const uint32_t DISPTIME = 0x0001; const uint32_t DISPXY = 0x0002; @@ -36,7 +36,7 @@ const uint32_t DISPPSD = 0x0004; const uint32_t DISPSPEC = 0x0008; const uint32_t DISPRAST = 0x0010; -// DisplayType Options +//! DisplayType Options const uint32_t DISPOPTCPLX = 0x0100; const uint32_t DISPOPTLOG = 0x0200; const uint32_t DISPOPTSTEM = 0x0400; @@ -80,7 +80,7 @@ struct callbackregister_base class callback_t : public callback_base_t { public: - callback_t(T* callback_, priv_lvl_t priv_, + callback_t(T* callback_, priv_lvl_t priv_, const std::string& units_, const DisplayType display_, const:: std::string& desc_, const pmt::pmt_t& min_, const pmt::pmt_t& max_, const pmt::pmt_t& def_) : callback_base_t(priv_, units_, display_, desc_, min_, max_, def_), @@ -88,6 +88,12 @@ struct callbackregister_base { } + callback_t(T* callback_, priv_lvl_t priv_, const:: std::string& desc_) : + callback_base_t(priv_, "", 0, desc_, pmt::pmt_t(), pmt::pmt_t(), pmt::pmt_t()), + callback(callback_) + { + } + Tsptr callback; }; |