demo project

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

Committer:
henryrawas
Date:
Tue Dec 29 23:31:28 2015 +0000
Revision:
7:6723f6887d00
Parent:
4:36a4eceb1b7f
Child:
8:d98e2dec0f40
motion block alerts, more commands

Who changed what in which revision?

UserRevisionLine numberNew contents of line
henryrawas 4:36a4eceb1b7f 1 /*
henryrawas 4:36a4eceb1b7f 2 Copyright (c) 2015 Jonathan Pickett & Microsoft. Some appropriate open source license.
henryrawas 4:36a4eceb1b7f 3 */
henryrawas 4:36a4eceb1b7f 4
henryrawas 4:36a4eceb1b7f 5 #ifndef __ROBOT_NODE_H__
henryrawas 4:36a4eceb1b7f 6 #define __ROBOT_NODE_H__
henryrawas 4:36a4eceb1b7f 7
henryrawas 4:36a4eceb1b7f 8 enum NodeMeasure
henryrawas 4:36a4eceb1b7f 9 {
henryrawas 4:36a4eceb1b7f 10 NM_Temperature = 0x1,
henryrawas 4:36a4eceb1b7f 11 NM_Voltage = 0x2,
henryrawas 4:36a4eceb1b7f 12 NM_Degrees = 0x3
henryrawas 4:36a4eceb1b7f 13 };
henryrawas 4:36a4eceb1b7f 14
henryrawas 4:36a4eceb1b7f 15 enum NodeAction
henryrawas 4:36a4eceb1b7f 16 {
henryrawas 7:6723f6887d00 17 NA_Rotate = 0x1
henryrawas 4:36a4eceb1b7f 18 };
henryrawas 4:36a4eceb1b7f 19
henryrawas 4:36a4eceb1b7f 20 enum NodePartType
henryrawas 4:36a4eceb1b7f 21 {
henryrawas 7:6723f6887d00 22 NT_AX12 = 0x1
henryrawas 4:36a4eceb1b7f 23 };
henryrawas 4:36a4eceb1b7f 24
henryrawas 4:36a4eceb1b7f 25
henryrawas 4:36a4eceb1b7f 26 class RobotNode
henryrawas 4:36a4eceb1b7f 27 {
henryrawas 4:36a4eceb1b7f 28 public:
henryrawas 4:36a4eceb1b7f 29 virtual bool HasMeasure(int measureId) = 0;
henryrawas 4:36a4eceb1b7f 30
henryrawas 4:36a4eceb1b7f 31 virtual float GetMeasure(int measureId) = 0;
henryrawas 4:36a4eceb1b7f 32
henryrawas 4:36a4eceb1b7f 33 virtual float GetLastMeasure(int measureId) = 0;
henryrawas 4:36a4eceb1b7f 34
henryrawas 4:36a4eceb1b7f 35 virtual bool HasAction(int actionId) = 0;
henryrawas 4:36a4eceb1b7f 36
henryrawas 4:36a4eceb1b7f 37 virtual bool DoAction(int actionId, float actionValue) = 0;
henryrawas 4:36a4eceb1b7f 38
henryrawas 7:6723f6887d00 39 virtual int GetLastError() = 0;
henryrawas 4:36a4eceb1b7f 40
henryrawas 4:36a4eceb1b7f 41 virtual NodePartType GetNodeType() = 0;
henryrawas 4:36a4eceb1b7f 42 };
henryrawas 4:36a4eceb1b7f 43
henryrawas 4:36a4eceb1b7f 44 #endif