~aleteoryx/muditaos

ref: 8fd488b08459d68f6101aeb681104cc172ada768 muditaos/module-apps/application-antenna/ApplicationAntenna.hpp -rw-r--r-- 1.4 KiB
8fd488b0 — Piotr Tanski [EGD-3720] Database service API cleanup for messages application. (#720) 5 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
 * ApplicationAntenna.hpp
 *
 *  Created on: 18 lut 2020
 *      Author: kuba
 */

#ifndef MODULE_APPS_APPLICATION_ANTENNA_APPLICATIONANTENNA_HPP_
#define MODULE_APPS_APPLICATION_ANTENNA_APPLICATIONANTENNA_HPP_

#include "Application.hpp"
#include "windows/AppWindow.hpp"

namespace app
{

    inline const std::string name_antenna = "ApplicationAntenna";

    class ApplicationAntenna : public app::Application
    {
      protected:
        AppTimer appTimer;
        void timerHandler(void);
        bool cellularRequestInProgress = false;

      public:
        ApplicationAntenna(std::string name = name_antenna, std::string parent = "", bool startBackgound = false);
        virtual ~ApplicationAntenna();

        sys::Message_t DataReceivedHandler(sys::DataMessage *msgl, sys::ResponseMessage *resp) override;
        sys::ReturnCodes InitHandler() override;
        sys::ReturnCodes DeinitHandler() override;

        sys::ReturnCodes SwitchPowerModeHandler(const sys::ServicePowerMode mode) override final
        {
            return sys::ReturnCodes::Success;
        }

        void createUserInterface() override;
        void destroyUserInterface() override;
        void setScanInProgress(bool value)
        {
            cellularRequestInProgress = value;
        };
    };

} /* namespace app */

#endif /* MODULE_APPS_APPLICATION_ANTENNA_APPLICATIONANTENNA_HPP_ */