diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2019-11-19 12:44:05 +0100 |
---|---|---|
committer | Romain Forlot <romain.forlot@iot.bzh> | 2020-01-09 15:55:03 +0100 |
commit | 5178fbebb1b2aa6a25c50259f2545e97502c4248 (patch) | |
tree | 78c67a2ff72a193dba297b8afd33fe2757cb1912 /examples/engine | |
parent | 857547cbdb44eac387bda44c2a61e32ca014e564 (diff) |
examples: Update using new Generator
New generator including new signals capabilities:
- sign
- big_endian frame
- default length
Bug-AGL: SPEC-2988
Change-Id: Icf2e4dd7ef880a73527103c90a8063cf3d042e41
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'examples/engine')
-rw-r--r-- | examples/engine/application-generated.cpp | 38 |
1 files changed, 22 insertions, 16 deletions
diff --git a/examples/engine/application-generated.cpp b/examples/engine/application-generated.cpp index 4f6dd702..ea003109 100644 --- a/examples/engine/application-generated.cpp +++ b/examples/engine/application-generated.cpp @@ -7,7 +7,7 @@ application_t::application_t() , message_set_{ {std::make_shared<message_set_t>(message_set_t{0,"example", { // beginning message_definition_ vector - {std::make_shared<message_definition_t>(message_definition_t{"hs", 0x3D9,"", 0, false, message_format_t::STANDARD, frequency_clock_t(5.00000f), true, + {std::make_shared<message_definition_t>(message_definition_t{"hs",0x3D9,"",8,0,true,frequency_clock_t(5.00000f),true, { // beginning signals vector {std::make_shared<signal_t> (signal_t{ "engine.speed",// generic_name @@ -27,8 +27,9 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })}, {std::make_shared<signal_t> (signal_t{ @@ -49,8 +50,9 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })}, {std::make_shared<signal_t> (signal_t{ @@ -71,13 +73,14 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })} } // end signals vector })} // end message_definition entry -, {std::make_shared<message_definition_t>(message_definition_t{"hs", 0x3E9,"", 0, false, message_format_t::STANDARD, frequency_clock_t(5.00000f), true, +, {std::make_shared<message_definition_t>(message_definition_t{"hs",0x3E9,"",8,0,true,frequency_clock_t(5.00000f),true, { // beginning signals vector {std::make_shared<signal_t> (signal_t{ "vehicle.average.speed",// generic_name @@ -97,13 +100,14 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })} } // end signals vector })} // end message_definition entry -, {std::make_shared<message_definition_t>(message_definition_t{"hs", 0x4D1,"", 0, false, message_format_t::STANDARD, frequency_clock_t(5.00000f), true, +, {std::make_shared<message_definition_t>(message_definition_t{"hs",0x4D1,"",8,0,true,frequency_clock_t(5.00000f),true, { // beginning signals vector {std::make_shared<signal_t> (signal_t{ "engine.oil.temp",// generic_name @@ -123,8 +127,9 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })}, {std::make_shared<signal_t> (signal_t{ @@ -145,8 +150,9 @@ application_t::application_t() nullptr,// encoder false,// received std::make_pair<bool, int>(false, 0),// multiplex - 0,// is_big_endian - 0,// is_signed + false,// is_big_endian + static_cast<sign_t>(0),// signed + -1,// bit_sign_position ""// unit })} } // end signals vector @@ -161,7 +167,7 @@ application_t::application_t() { for(std::shared_ptr<message_set_t> cms: message_set_) { - vect_ptr_msg_def_t messages_definition = cms->get_messages_definition(); + std::vector<std::shared_ptr<message_definition_t>> messages_definition = cms->get_messages_definition(); for(std::shared_ptr<message_definition_t> cmd : messages_definition) { cmd->set_parent(cms); |