12345678910111213141516171819202122232425262728293031323334353637 |
- #ifndef DBCSIGPACKER_H
- #define DBCSIGPACKER_H
- #include <map>
- #include <vector>
- #include "candbc.h"
- namespace iv {
- struct MsgSig
- {
- unsigned int mid; //can message id
- std::string mstrmsgname; //can message name
- std::vector<SignalPackValue> mvectorSPV;
- };
- }
- class dbcsigpacker
- {
- public:
- dbcsigpacker(std::string strdbcname);
- dbcsigpacker(std::string strdbcname,std::istringstream & strsteam);
- private:
- CANPacker * mpPacker;
- const DBC * mpdbc;
- std::map<std::string,iv::MsgSig> mmapMsgSig;
- private:
- void InitSig();
- public:
- void SetMsgSignal(std::string strmsgname,std::string strsigname,const double fvalue);
- std::vector<uint8_t> GetPack(std::string strmsgname);
- };
- #endif // DBCSIGPACKER_H
|