demo project
Dependencies: AX-12A Dynamixel mbed iothub_client EthernetInterface NTPClient ConfigFile SDFileSystem iothub_amqp_transport mbed-rtos proton-c-mbed wolfSSL
Utils/MeasureBuf.h@33:8b9dcbf6d8ec, 2016-02-04 (annotated)
- Committer:
- henryrawas
- Date:
- Thu Feb 04 20:10:33 2016 +0000
- Revision:
- 33:8b9dcbf6d8ec
- Parent:
- 21:051751f9ca9e
update libs
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
henryrawas | 19:2f0ec9ac1238 | 1 | // Copyright (c) Microsoft. All rights reserved. |
henryrawas | 19:2f0ec9ac1238 | 2 | // Licensed under the MIT license. See LICENSE file in the project root for full license information. |
henryrawas | 18:224289104fc0 | 3 | |
henryrawas | 18:224289104fc0 | 4 | #ifndef __MEASUREBUF_H__ |
henryrawas | 18:224289104fc0 | 5 | #define __MEASUREBUF_H__ |
henryrawas | 18:224289104fc0 | 6 | |
henryrawas | 18:224289104fc0 | 7 | #include "mbed.h" |
henryrawas | 18:224289104fc0 | 8 | #include "SafeCircBuf.h" |
henryrawas | 18:224289104fc0 | 9 | #include "RobotArmCfg.h" |
henryrawas | 18:224289104fc0 | 10 | |
henryrawas | 18:224289104fc0 | 11 | |
henryrawas | 21:051751f9ca9e | 12 | #define MeasureBufSize 8 |
henryrawas | 18:224289104fc0 | 13 | |
henryrawas | 18:224289104fc0 | 14 | |
henryrawas | 18:224289104fc0 | 15 | class MeasureGroup |
henryrawas | 18:224289104fc0 | 16 | { |
henryrawas | 18:224289104fc0 | 17 | public: |
henryrawas | 18:224289104fc0 | 18 | MeasureGroup() {}; |
henryrawas | 18:224289104fc0 | 19 | |
henryrawas | 18:224289104fc0 | 20 | MeasureGroup& operator=(const MeasureGroup& rhs); |
henryrawas | 18:224289104fc0 | 21 | |
henryrawas | 18:224289104fc0 | 22 | void SetMeasure(int numParts, float vals[]); |
henryrawas | 18:224289104fc0 | 23 | |
henryrawas | 18:224289104fc0 | 24 | int NumVals; |
henryrawas | 18:224289104fc0 | 25 | |
henryrawas | 18:224289104fc0 | 26 | float MeasVals[NUMJOINTS]; |
henryrawas | 18:224289104fc0 | 27 | }; |
henryrawas | 18:224289104fc0 | 28 | |
henryrawas | 18:224289104fc0 | 29 | class MeasureSnapshot |
henryrawas | 18:224289104fc0 | 30 | { |
henryrawas | 18:224289104fc0 | 31 | public: |
henryrawas | 18:224289104fc0 | 32 | MeasureSnapshot() {}; |
henryrawas | 18:224289104fc0 | 33 | |
henryrawas | 18:224289104fc0 | 34 | MeasureGroup Temps; |
henryrawas | 18:224289104fc0 | 35 | |
henryrawas | 18:224289104fc0 | 36 | MeasureGroup Volts; |
henryrawas | 18:224289104fc0 | 37 | |
henryrawas | 18:224289104fc0 | 38 | MeasureGroup Loads; |
henryrawas | 18:224289104fc0 | 39 | |
henryrawas | 18:224289104fc0 | 40 | MeasureGroup Positions; |
henryrawas | 18:224289104fc0 | 41 | |
henryrawas | 18:224289104fc0 | 42 | time_t Created; |
henryrawas | 20:891b5270845a | 43 | |
henryrawas | 20:891b5270845a | 44 | int CreatedMs; |
henryrawas | 18:224289104fc0 | 45 | }; |
henryrawas | 18:224289104fc0 | 46 | |
henryrawas | 18:224289104fc0 | 47 | extern SafeCircBuf<MeasureSnapshot, MeasureBufSize, uint32_t> MeasureBuf; |
henryrawas | 18:224289104fc0 | 48 | |
henryrawas | 18:224289104fc0 | 49 | #endif |