robot arm demo team / Mbed 2 deprecated RobotArmDemo Featured

Dependencies:   AX-12A Dynamixel mbed iothub_client EthernetInterface NTPClient ConfigFile SDFileSystem iothub_amqp_transport mbed-rtos proton-c-mbed wolfSSL

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers NodeEmul.h Source File

NodeEmul.h

00001 // Copyright (c) Microsoft. All rights reserved.
00002 // Licensed under the MIT license. See LICENSE file in the project root for full license information.
00003 
00004 #ifndef __NODE_Emul_H__
00005 #define __NODE_Emul_H__
00006 
00007 #include "RobotNode.h"
00008 
00009 
00010 
00011 class NodeEmul : public RobotNode
00012 {
00013 public:
00014     NodeEmul(int id);
00015     
00016     virtual bool HasMeasure(int measureId);
00017     
00018     virtual float GetMeasure(int measureId);
00019     
00020     virtual void ClearMeasureCache();
00021     
00022     virtual bool HasAction(int actionId);
00023     
00024     virtual bool DoAction(int actionId, float actionValue);
00025     
00026     virtual int GetLastError();
00027     
00028     virtual bool HasError();
00029     
00030     virtual NodePartType GetNodeType();
00031     
00032 private:
00033     
00034     // last read temperature
00035     int _LastTemperature;
00036     
00037     // last read position
00038     float _LastPosition;
00039     
00040     // last read voltage
00041     float _LastVoltage;
00042     
00043     // last read load
00044     float _LastLoad;
00045 };
00046 
00047 #endif