Erick / Mbed 2 deprecated ICE-F412

Dependencies:   mbed-rtos mbed

Committer:
jmarkel44
Date:
Tue Jan 24 19:05:33 2017 +0000
Revision:
0:61364762ee0e
Port from IAR to Nucleo-F412 board

Who changed what in which revision?

UserRevisionLine numberNew contents of line
jmarkel44 0:61364762ee0e 1 /******************************************************************************
jmarkel44 0:61364762ee0e 2 *
jmarkel44 0:61364762ee0e 3 * File: CompositeAlgorithm.h
jmarkel44 0:61364762ee0e 4 * Desciption: interface file for the ICE Composite Algorithm
jmarkel44 0:61364762ee0e 5 *
jmarkel44 0:61364762ee0e 6 *****************************************************************************/
jmarkel44 0:61364762ee0e 7 #ifndef COMPOSITEALGORITHM_H
jmarkel44 0:61364762ee0e 8 #define COMPOSITEALGORITHM_H
jmarkel44 0:61364762ee0e 9
jmarkel44 0:61364762ee0e 10 #include <stdio.h>
jmarkel44 0:61364762ee0e 11 #include <string>
jmarkel44 0:61364762ee0e 12
jmarkel44 0:61364762ee0e 13 class CompositeAlgorithm
jmarkel44 0:61364762ee0e 14 {
jmarkel44 0:61364762ee0e 15 private:
jmarkel44 0:61364762ee0e 16 std::string controlFile; // the control file
jmarkel44 0:61364762ee0e 17 std::string id; // algorithm id
jmarkel44 0:61364762ee0e 18 std::string tag; // input (real or virtual)
jmarkel44 0:61364762ee0e 19 std::string opr; // right operand
jmarkel44 0:61364762ee0e 20 std::string op; // operation to perform (+, -, ==, etc.)
jmarkel44 0:61364762ee0e 21 std::string resultTrue; // what to do when true
jmarkel44 0:61364762ee0e 22 std::string resultFalse; // what to do when false
jmarkel44 0:61364762ee0e 23
jmarkel44 0:61364762ee0e 24 bool validateControlData(const char *buf);
jmarkel44 0:61364762ee0e 25 void copyControlData(const char *buf);
jmarkel44 0:61364762ee0e 26 public:
jmarkel44 0:61364762ee0e 27 CompositeAlgorithm() {}
jmarkel44 0:61364762ee0e 28 ~CompositeAlgorithm() {
jmarkel44 0:61364762ee0e 29 printf("%s invoked", __func__);
jmarkel44 0:61364762ee0e 30 }
jmarkel44 0:61364762ee0e 31
jmarkel44 0:61364762ee0e 32 bool load(const std::string);
jmarkel44 0:61364762ee0e 33
jmarkel44 0:61364762ee0e 34 void display(void);
jmarkel44 0:61364762ee0e 35
jmarkel44 0:61364762ee0e 36 std::string getId(void) const {
jmarkel44 0:61364762ee0e 37 return id;
jmarkel44 0:61364762ee0e 38 }
jmarkel44 0:61364762ee0e 39 std::string getTag(void) const {
jmarkel44 0:61364762ee0e 40 return tag;
jmarkel44 0:61364762ee0e 41 }
jmarkel44 0:61364762ee0e 42 std::string getOpr(void) const { return opr; }
jmarkel44 0:61364762ee0e 43 std::string getOp(void) const { return op; }
jmarkel44 0:61364762ee0e 44 std::string getResultTrue(void) const { return resultTrue; }
jmarkel44 0:61364762ee0e 45 std::string getResultFalse(void) const { return resultFalse; }
jmarkel44 0:61364762ee0e 46 };
jmarkel44 0:61364762ee0e 47
jmarkel44 0:61364762ee0e 48 #endif
jmarkel44 0:61364762ee0e 49