Esempio n. 1
0
    /**
    * Terminates module execution and performs cleanup
    * @return this method cannot fail, so it always returns true
    */
    virtual bool close()
    {
        if (m_ptf.isValid())
        {
            m_ptf.close();
        }
        if (m_pmap.isValid())
        {
            m_pmap.close();
        }

        if (m_rosPublisher_occupancyGrid.asPort().isOpen())
        {
            m_rosPublisher_occupancyGrid.interrupt();
            m_rosPublisher_occupancyGrid.close();
        }
        if (m_rosPublisher_initial_pose.asPort().isOpen())
        {
            m_rosPublisher_initial_pose.interrupt();
            m_rosPublisher_initial_pose.close();
        }
        if (m_rosNode)
        {
            delete m_rosNode;
            m_rosNode = 0;
        }
        m_rpcPort.interrupt();
        m_rpcPort.close();

        return true;
    }
Esempio n. 2
0
    virtual bool close()
    {
        mHandlerPort.interrupt();
        mHandlerPort.close();

        //mNavThread->shutdown();
        mNavThread->stop();
        delete mNavThread;
        mNavThread=NULL;

        return true;
    }
Esempio n. 3
0
    virtual bool close()
    {
        rpcPort.interrupt();
        rpcPort.close();

        //gotoThread->shutdown();
        gotoThread->stop();
        delete gotoThread;
        gotoThread=NULL;

        return true;
    }
Esempio n. 4
0
    /**
    * Interrupts ports operations
    * @return this method cannot fail, so it always returns true
    */
    virtual bool interruptModule()
    {
        m_rpcPort.interrupt();

        return true;
    }
Esempio n. 5
0
    virtual bool interruptModule()
    {
        mHandlerPort.interrupt();

        return true;
    }