discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Need help with control port client


From: Alexandru Csete
Subject: Re: [Discuss-gnuradio] Need help with control port client
Date: Fri, 5 Apr 2013 00:37:15 +0200

On Thu, Apr 4, 2013 at 1:52 AM, Alexandru Csete <address@hidden> wrote:
> Greetings,
>
> I'm trying to write a control port client in C++ but I got stuck and
> need some help.
>
> My problem is that the control port interface gives us a map
> containing GNURadio::KnobPtr but to get access to the value I need a
> typed pointer, e.g. GNURadio::KnobDPtr, which is derived from KnobPtr.
> I tried a static_cast as illustrated in this snippet:
> http://pastebin.com/NqWyqSeu - but gcc throws it right back at me with
> an error:
>
> In file included from /usr/include/Ice/LocalObjectF.h:15:0,
>                  from /usr/include/Ice/CommunicatorF.h:24,
>                  from /usr/include/Ice/Initialize.h:13,
>                  from /usr/include/Ice/Ice.h:13,
>                  from strx-mon.cpp:1:
> /usr/include/Ice/Handle.h: In constructor
> ‘IceInternal::Handle<T>::Handle(const IceInternal::Handle<Y>&) [with Y
> = GNURadio::Knob, T = GNURadio::KnobD]’:
> strx-mon.cpp:28:72:   instantiated from here
> /usr/include/Ice/Handle.h:73:9: error: invalid conversion from
> ‘GNURadio::Knob*’ to ‘GNURadio::KnobD*’ [-fpermissive]
>

Sorry for the noise. I realized that adding -fpermissive to gcc will
make it compile and run as expected. I guess I can now look forward to
being publicly crucified at the next C++ convention... On the other
hand the Python does the same thing behind the scenes so I will not
loose any sleep over this.

Alex



reply via email to

[Prev in Thread] Current Thread [Next in Thread]