Go to the documentation of this file.
3 #include <unordered_set>
5 #include <boost/exception/diagnostic_information.hpp>
16 std::cout <<
"E " << std::hex << f.
id << std::dec;
18 std::cout <<
"e " << std::hex << f.
id << std::dec;
20 std::cout <<
"s " << std::hex << f.
id << std::dec;
28 std::cout << (int) f.
dlc << std::hex;
30 for(
int i=0; i < f.
dlc; ++i){
31 std::cout << std::hex <<
" " << (int) f.
data[i];
35 std::cout << std::dec << std::endl;
39 std::shared_ptr<class_loader::ClassLoader>
g_loader;
49 int main(
int argc,
char *argv[]){
51 if(argc != 2 && argc != 4){
52 std::cout <<
"usage: "<< argv[0] <<
" DEVICE [PLUGIN_PATH PLUGIN_NAME]" << std::endl;
59 g_loader = std::make_shared<class_loader::ClassLoader>(argv[2]);
63 catch(std::exception& ex)
65 std::cerr << boost::diagnostic_information(ex) << std::endl;;
69 g_driver = std::make_shared<SocketCANInterface>();
static SettingsConstSharedPtr create()
StateInterface::StateListenerConstSharedPtr StateListenerConstSharedPtr
std::shared_ptr< class_loader::ClassLoader > g_loader
unsigned char dlc
len of data
void print_frame(const Frame &f)
std::shared_ptr< DriverInterface > DriverInterfaceSharedPtr
int main(int argc, char *argv[])
boost::system::error_code error_code
device access error
std::array< value_type, 8 > data
array for 8 data bytes with bounds checking
CommInterface::FrameListenerConstSharedPtr FrameListenerConstSharedPtr
void print_state(const State &s)
DriverInterfaceSharedPtr g_driver
enum can::State::DriverState driver_state
unsigned int internal_error
driver specific error