Main Page · Modules · All Classes · Class Hierarchy
MATailController.hpp
1 /*
2  * This file is part of the AiBO+ project
3  *
4  * Copyright (C) 2005-2016 Csaba Kertész (csaba.kertesz@gmail.com)
5  *
6  * AiBO+ is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * AiBO+ is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Street #330, Boston, MA 02111-1307, USA.
19  *
20  */
21 
22 #pragma once
23 
24 #include <boost/shared_ptr.hpp>
25 
26 #include <MCThreadLocalData.hpp>
27 
28 #include "MAController.hpp"
29 
30 class MADevice;
31 class MATailController;
32 
38 namespace MA
39 {
42 }
43 
48 {
49 public:
53  virtual ~MATailController();
54 
55 private:
56  virtual void UpdateRobotState(MARobotState& state) override;
57 
58 public:
59  virtual MA::DeviceList GetMotors() const override;
60  void SetPower(bool new_state);
61  bool IsPowerOn();
62  bool IsMoving();
63  void Stop();
64  MA_DECLARE_TRANSITION_ACTION(Wag)
65  MA_DECLARE_TRANSITION(ToBack, IsAtBack)
66  virtual MA::DeviceGeneratorsMap GetSkitTransitionGenerators(MA::SkitBaseSPtr skit) override;
67 
68 protected:
70  boost::shared_ptr<MADevice> TailTilt;
72  boost::shared_ptr<MADevice> TailPan;
73 };
74 
boost::shared_ptr< MADevice > TailPan
Tail pan.
Base class for the controllers.
Device class.
Definition: MADevice.hpp:57
boost::shared_ptr< MADevice > TailTilt
Tail tilt.
Tail controller class.
A wrapper class to cover boost::thread_specific_ptr/folly::ThreadLocal API on certain targets...
Robot state.