|
DbcLib 1.0
CAN DBC C++ library.
|
Main user object that is an interface against a DBC file. More...
#include <dbcfile.h>
Public Member Functions | |
| void | Filename (const std::string &filename) |
| Sets the file name. Full path required. | |
| const std::string & | Filename () const |
| Returns the file name with full path. | |
| std::string | Name () const |
| Returns the File name without path and extension. | |
| const std::string & | LastError () const |
| Returns the last (parser) error text. | |
| Network * | GetNetwork () |
| Returns the network object. | |
| const Network * | GetNetwork () const |
| Returns the network object. | |
| bool | ParseFile () |
| Parses the DBC file. Returns true on success. | |
| void | BaseTime (uint64_t ns1970) |
| Start time of messages. | |
| uint64_t | BaseTime () const |
| Returns the base (start) time of first message. | |
| void | SetMessageSize (size_t nof_messages) |
| Sets the maximum message queue size. | |
| void | AddMessage (size_t index, const DbcMessage &message) |
| Adds q message to the message queue. | |
| bool | ParseMessage (const DbcMessage &message) |
| Parses the message into signal values. | |
| void | ResetSampleCounter () const |
| Resets the sample counter for all signals. | |
| void | ReparseMessageList () |
| Reparse the message queue. | |
The DBC file is the only object the user shall create. It handle the parsing of the file. A DBC file defines nodes, messages and signals for one CAN network.
|
inline |
The base time is the time of the first message. If not set, the AddMessage will set it to the first DBCMessage.
| ns1970 | Nano-seconds since 1970. |
| void dbc::DbcFile::ReparseMessageList | ( | ) |
This function is used to reparse the message queue. This function is used when the first parse message round just count number of samples while the next round, the user selects signals (SignalObserver) and reparse the message queue.