You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@plc4x.apache.org by sr...@apache.org on 2021/09/28 11:17:40 UTC

[plc4x] branch develop updated: fix(plc4go): fixed issue where ordering was changed after latest refactor

This is an automated email from the ASF dual-hosted git repository.

sruehl pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/plc4x.git


The following commit(s) were added to refs/heads/develop by this push:
     new e0819a8  fix(plc4go): fixed issue where ordering was changed after latest refactor
e0819a8 is described below

commit e0819a89709a48943ec0a4324d156bcc3744a16e
Author: Sebastian Rühl <sr...@apache.org>
AuthorDate: Tue Sep 28 13:16:59 2021 +0200

    fix(plc4go): fixed issue where ordering was changed after latest refactor
---
 plc4c/drivers/s7/test/s7_test.c                    |   8 +-
 plc4c/generated-sources/modbus/src/modbus_pdu.c    | 120 ++++++++++-----------
 .../s7/include/s7_data_alarm_message.h             |   4 +-
 .../s7/include/s7_payload_user_data_item.h         |   8 +-
 plc4c/generated-sources/s7/src/cotp_packet.c       |  12 +--
 plc4c/generated-sources/s7/src/cotp_parameter.c    |   6 +-
 .../s7/src/s7_data_alarm_message.c                 |  14 +--
 plc4c/generated-sources/s7/src/s7_message.c        |   4 +-
 plc4c/generated-sources/s7/src/s7_parameter.c      |  14 +--
 plc4c/generated-sources/s7/src/s7_payload.c        |  12 +--
 .../s7/src/s7_payload_user_data_item.c             |  74 ++++++-------
 11 files changed, 138 insertions(+), 138 deletions(-)

diff --git a/plc4c/drivers/s7/test/s7_test.c b/plc4c/drivers/s7/test/s7_test.c
index cb0921f..2ec0bd9 100644
--- a/plc4c/drivers/s7/test/s7_test.c
+++ b/plc4c/drivers/s7/test/s7_test.c
@@ -56,26 +56,26 @@ void internal_parse_serialize_test(uint8_t* payload,
   plc4c_return_code return_code =
       plc4c_spi_read_buffer_create(payload, payload_size, &read_buffer);
   if (return_code != OK) {
-    TEST_FAIL_MESSAGE("Error");
+    TEST_FAIL_MESSAGE("Error creating read buffer");
   }
 
   plc4c_s7_read_write_tpkt_packet* message = NULL;
   return_code = plc4c_s7_read_write_tpkt_packet_parse(read_buffer, &message);
   if (return_code != OK) {
-    TEST_FAIL_MESSAGE("Error");
+    TEST_FAIL_MESSAGE("Error error parsing tpkt packet");
   }
 
   plc4c_spi_write_buffer* write_buffer;
   return_code = plc4c_spi_write_buffer_create(payload_size, &write_buffer);
   if (return_code != OK) {
-    TEST_FAIL_MESSAGE("Error");
+    TEST_FAIL_MESSAGE("Error writing to buffer");
   }
 
   return_code =
       plc4c_s7_read_write_tpkt_packet_serialize(write_buffer, message);
 
   if (return_code != OK) {
-    TEST_FAIL_MESSAGE("Error");
+    TEST_FAIL_MESSAGE("Error serializing");
   }
 
   internal_assert_arrays_equal(payload, write_buffer, payload_size);
diff --git a/plc4c/generated-sources/modbus/src/modbus_pdu.c b/plc4c/generated-sources/modbus/src/modbus_pdu.c
index 344a7d8..57e1537 100644
--- a/plc4c/generated-sources/modbus/src/modbus_pdu.c
+++ b/plc4c/generated-sources/modbus/src/modbus_pdu.c
@@ -27,84 +27,84 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_modbus_read_write_modbus_pdu_discriminator plc4c_modbus_read_write_modbus_pdu_discriminators[] = {
-  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_holding_registers_request */
-   .errorFlag = false, .functionFlag = 0x10, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_counter_response */
-   .errorFlag = false, .functionFlag = 0x0B, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_holding_registers_response */
-   .errorFlag = false, .functionFlag = 0x10, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_coils_response */
-   .errorFlag = false, .functionFlag = 0x0F, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_write_multiple_holding_registers_request */
-   .errorFlag = false, .functionFlag = 0x17, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_write_multiple_holding_registers_response */
-   .errorFlag = false, .functionFlag = 0x17, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_exception_status_response */
-   .errorFlag = false, .functionFlag = 0x07, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_error */
+   .errorFlag = true, .functionFlag = -1, .response = -1 },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_discrete_inputs_request */
+   .errorFlag = false, .functionFlag = 0x02, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_discrete_inputs_response */
+   .errorFlag = false, .functionFlag = 0x02, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_coils_request */
+   .errorFlag = false, .functionFlag = 0x01, .response = false },
   {/* plc4c_modbus_read_write_modbus_pdu_read_coils_response */
    .errorFlag = false, .functionFlag = 0x01, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_file_record_request */
-   .errorFlag = false, .functionFlag = 0x14, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_fifo_queue_response */
-   .errorFlag = false, .functionFlag = 0x18, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_report_server_id_request */
-   .errorFlag = false, .functionFlag = 0x11, .response = false },
   {/* plc4c_modbus_read_write_modbus_pdu_write_single_coil_request */
    .errorFlag = false, .functionFlag = 0x05, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_holding_registers_request */
-   .errorFlag = false, .functionFlag = 0x03, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_report_server_id_response */
-   .errorFlag = false, .functionFlag = 0x11, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_coils_request */
-   .errorFlag = false, .functionFlag = 0x01, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_single_coil_response */
+   .errorFlag = false, .functionFlag = 0x05, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_coils_request */
+   .errorFlag = false, .functionFlag = 0x0F, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_coils_response */
+   .errorFlag = false, .functionFlag = 0x0F, .response = true },
   {/* plc4c_modbus_read_write_modbus_pdu_read_input_registers_request */
    .errorFlag = false, .functionFlag = 0x04, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_device_identification_response */
-   .errorFlag = false, .functionFlag = 0x2B, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_input_registers_response */
+   .errorFlag = false, .functionFlag = 0x04, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_holding_registers_request */
+   .errorFlag = false, .functionFlag = 0x03, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_holding_registers_response */
+   .errorFlag = false, .functionFlag = 0x03, .response = true },
   {/* plc4c_modbus_read_write_modbus_pdu_write_single_register_request */
    .errorFlag = false, .functionFlag = 0x06, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_counter_request */
-   .errorFlag = false, .functionFlag = 0x0B, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_single_register_response */
+   .errorFlag = false, .functionFlag = 0x06, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_holding_registers_request */
+   .errorFlag = false, .functionFlag = 0x10, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_holding_registers_response */
+   .errorFlag = false, .functionFlag = 0x10, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_write_multiple_holding_registers_request */
+   .errorFlag = false, .functionFlag = 0x17, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_write_multiple_holding_registers_response */
+   .errorFlag = false, .functionFlag = 0x17, .response = true },
   {/* plc4c_modbus_read_write_modbus_pdu_mask_write_holding_register_request */
    .errorFlag = false, .functionFlag = 0x16, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_error */
-   .errorFlag = true, .functionFlag = -1, .response = -1 },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_holding_registers_response */
-   .errorFlag = false, .functionFlag = 0x03, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_single_coil_response */
-   .errorFlag = false, .functionFlag = 0x05, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_device_identification_request */
-   .errorFlag = false, .functionFlag = 0x2B, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_input_registers_response */
-   .errorFlag = false, .functionFlag = 0x04, .response = true },
   {/* plc4c_modbus_read_write_modbus_pdu_mask_write_holding_register_response */
    .errorFlag = false, .functionFlag = 0x16, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_discrete_inputs_request */
-   .errorFlag = false, .functionFlag = 0x02, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_multiple_coils_request */
-   .errorFlag = false, .functionFlag = 0x0F, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_exception_status_request */
-   .errorFlag = false, .functionFlag = 0x07, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_file_record_response */
-   .errorFlag = false, .functionFlag = 0x15, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_discrete_inputs_response */
-   .errorFlag = false, .functionFlag = 0x02, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_fifo_queue_request */
+   .errorFlag = false, .functionFlag = 0x18, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_fifo_queue_response */
+   .errorFlag = false, .functionFlag = 0x18, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_file_record_request */
+   .errorFlag = false, .functionFlag = 0x14, .response = false },
   {/* plc4c_modbus_read_write_modbus_pdu_read_file_record_response */
    .errorFlag = false, .functionFlag = 0x14, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_file_record_request */
+   .errorFlag = false, .functionFlag = 0x15, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_write_file_record_response */
+   .errorFlag = false, .functionFlag = 0x15, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_exception_status_request */
+   .errorFlag = false, .functionFlag = 0x07, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_exception_status_response */
+   .errorFlag = false, .functionFlag = 0x07, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_diagnostic_request */
+   .errorFlag = false, .functionFlag = 0x08, .response = false },
   {/* plc4c_modbus_read_write_modbus_pdu_diagnostic_response */
    .errorFlag = false, .functionFlag = 0x08, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_log_response */
-   .errorFlag = false, .functionFlag = 0x0C, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_counter_request */
+   .errorFlag = false, .functionFlag = 0x0B, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_counter_response */
+   .errorFlag = false, .functionFlag = 0x0B, .response = true },
   {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_log_request */
    .errorFlag = false, .functionFlag = 0x0C, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_read_fifo_queue_request */
-   .errorFlag = false, .functionFlag = 0x18, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_single_register_response */
-   .errorFlag = false, .functionFlag = 0x06, .response = true },
-  {/* plc4c_modbus_read_write_modbus_pdu_write_file_record_request */
-   .errorFlag = false, .functionFlag = 0x15, .response = false },
-  {/* plc4c_modbus_read_write_modbus_pdu_diagnostic_request */
-   .errorFlag = false, .functionFlag = 0x08, .response = false }
+  {/* plc4c_modbus_read_write_modbus_pdu_get_com_event_log_response */
+   .errorFlag = false, .functionFlag = 0x0C, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_report_server_id_request */
+   .errorFlag = false, .functionFlag = 0x11, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_report_server_id_response */
+   .errorFlag = false, .functionFlag = 0x11, .response = true },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_device_identification_request */
+   .errorFlag = false, .functionFlag = 0x2B, .response = false },
+  {/* plc4c_modbus_read_write_modbus_pdu_read_device_identification_response */
+   .errorFlag = false, .functionFlag = 0x2B, .response = true }
 
 };
 
diff --git a/plc4c/generated-sources/s7/include/s7_data_alarm_message.h b/plc4c/generated-sources/s7/include/s7_data_alarm_message.h
index 1f08ca7..779c068 100644
--- a/plc4c/generated-sources/s7/include/s7_data_alarm_message.h
+++ b/plc4c/generated-sources/s7/include/s7_data_alarm_message.h
@@ -55,10 +55,10 @@ typedef enum plc4c_s7_read_write_s7_data_alarm_message_type plc4c_s7_read_write_
 plc4c_s7_read_write_s7_data_alarm_message_discriminator plc4c_s7_read_write_s7_data_alarm_message_get_discriminator(plc4c_s7_read_write_s7_data_alarm_message_type type);
 
 // Constant values.
-uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID();
 uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_VARIABLE_SPEC();
-uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ();
+uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID();
 uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_LENGTH();
+uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ();
 
 struct plc4c_s7_read_write_s7_data_alarm_message {
   /* This is an abstract type so this property saves the type of this typed union */
diff --git a/plc4c/generated-sources/s7/include/s7_payload_user_data_item.h b/plc4c/generated-sources/s7/include/s7_payload_user_data_item.h
index 8d45c4b..e498a08 100644
--- a/plc4c/generated-sources/s7/include/s7_payload_user_data_item.h
+++ b/plc4c/generated-sources/s7/include/s7_payload_user_data_item.h
@@ -80,13 +80,13 @@ typedef enum plc4c_s7_read_write_s7_payload_user_data_item_type plc4c_s7_read_wr
 plc4c_s7_read_write_s7_payload_user_data_item_discriminator plc4c_s7_read_write_s7_payload_user_data_item_get_discriminator(plc4c_s7_read_write_s7_payload_user_data_item_type type);
 
 // Constant values.
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_LENGTH();
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID();
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_NUMBER_MESSAGE_OBJ();
-uint16_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_READ_SZL_RESPONSE_SZL_ITEM_LENGTH();
 uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC();
 uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ();
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_LENGTH();
 uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID();
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_NUMBER_MESSAGE_OBJ();
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID();
+uint16_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_READ_SZL_RESPONSE_SZL_ITEM_LENGTH();
 
 struct plc4c_s7_read_write_s7_payload_user_data_item {
   /* This is an abstract type so this property saves the type of this typed union */
diff --git a/plc4c/generated-sources/s7/src/cotp_packet.c b/plc4c/generated-sources/s7/src/cotp_packet.c
index a57924f..8bef8c4 100644
--- a/plc4c/generated-sources/s7/src/cotp_packet.c
+++ b/plc4c/generated-sources/s7/src/cotp_packet.c
@@ -27,16 +27,16 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_s7_read_write_cotp_packet_discriminator plc4c_s7_read_write_cotp_packet_discriminators[] = {
-  {/* plc4c_s7_read_write_cotp_packet_connection_response */
-   .tpduCode = 0xD0 },
   {/* plc4c_s7_read_write_cotp_packet_data */
    .tpduCode = 0xF0 },
-  {/* plc4c_s7_read_write_cotp_packet_disconnect_response */
-   .tpduCode = 0xC0 },
-  {/* plc4c_s7_read_write_cotp_packet_disconnect_request */
-   .tpduCode = 0x80 },
   {/* plc4c_s7_read_write_cotp_packet_connection_request */
    .tpduCode = 0xE0 },
+  {/* plc4c_s7_read_write_cotp_packet_connection_response */
+   .tpduCode = 0xD0 },
+  {/* plc4c_s7_read_write_cotp_packet_disconnect_request */
+   .tpduCode = 0x80 },
+  {/* plc4c_s7_read_write_cotp_packet_disconnect_response */
+   .tpduCode = 0xC0 },
   {/* plc4c_s7_read_write_cotp_packet_tpdu_error */
    .tpduCode = 0x70 }
 
diff --git a/plc4c/generated-sources/s7/src/cotp_parameter.c b/plc4c/generated-sources/s7/src/cotp_parameter.c
index 6975c52..bca8fc5 100644
--- a/plc4c/generated-sources/s7/src/cotp_parameter.c
+++ b/plc4c/generated-sources/s7/src/cotp_parameter.c
@@ -29,14 +29,14 @@
 const plc4c_s7_read_write_cotp_parameter_discriminator plc4c_s7_read_write_cotp_parameter_discriminators[] = {
   {/* plc4c_s7_read_write_cotp_parameter_tpdu_size */
    .parameterType = 0xC0 },
-  {/* plc4c_s7_read_write_cotp_parameter_disconnect_additional_information */
-   .parameterType = 0xE0 },
   {/* plc4c_s7_read_write_cotp_parameter_calling_tsap */
    .parameterType = 0xC1 },
   {/* plc4c_s7_read_write_cotp_parameter_called_tsap */
    .parameterType = 0xC2 },
   {/* plc4c_s7_read_write_cotp_parameter_checksum */
-   .parameterType = 0xC3 }
+   .parameterType = 0xC3 },
+  {/* plc4c_s7_read_write_cotp_parameter_disconnect_additional_information */
+   .parameterType = 0xE0 }
 
 };
 
diff --git a/plc4c/generated-sources/s7/src/s7_data_alarm_message.c b/plc4c/generated-sources/s7/src/s7_data_alarm_message.c
index ae74ce9..91e9662 100644
--- a/plc4c/generated-sources/s7/src/s7_data_alarm_message.c
+++ b/plc4c/generated-sources/s7/src/s7_data_alarm_message.c
@@ -48,22 +48,22 @@ plc4c_s7_read_write_s7_data_alarm_message plc4c_s7_read_write_s7_data_alarm_mess
 
 
 // Constant values.
-static const uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID_const = 0x00;
-uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID() {
-  return PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID_const;
-}
 static const uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_VARIABLE_SPEC_const = 0x12;
 uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_VARIABLE_SPEC() {
   return PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_VARIABLE_SPEC_const;
 }
-static const uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ_const = 0x01;
-uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ() {
-  return PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ_const;
+static const uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID_const = 0x00;
+uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID() {
+  return PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_FUNCTION_ID_const;
 }
 static const uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_LENGTH_const = 0x08;
 uint8_t PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_LENGTH() {
   return PLC4C_S7_READ_WRITE_S7_MESSAGE_OBJECT_REQUEST_LENGTH_const;
 }
+static const uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ_const = 0x01;
+uint8_t PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ() {
+  return PLC4C_S7_READ_WRITE_S7_DATA_ALARM_MESSAGE_NUMBER_MESSAGE_OBJ_const;
+}
 
 // Parse function.
 plc4c_return_code plc4c_s7_read_write_s7_data_alarm_message_parse(plc4c_spi_read_buffer* readBuffer, uint8_t cpuFunctionType, plc4c_s7_read_write_s7_data_alarm_message** _message) {
diff --git a/plc4c/generated-sources/s7/src/s7_message.c b/plc4c/generated-sources/s7/src/s7_message.c
index c33711a..438120a 100644
--- a/plc4c/generated-sources/s7/src/s7_message.c
+++ b/plc4c/generated-sources/s7/src/s7_message.c
@@ -27,12 +27,12 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_s7_read_write_s7_message_discriminator plc4c_s7_read_write_s7_message_discriminators[] = {
+  {/* plc4c_s7_read_write_s7_message_request */
+   .messageType = 0x01 },
   {/* plc4c_s7_read_write_s7_message_response */
    .messageType = 0x02 },
   {/* plc4c_s7_read_write_s7_message_response_data */
    .messageType = 0x03 },
-  {/* plc4c_s7_read_write_s7_message_request */
-   .messageType = 0x01 },
   {/* plc4c_s7_read_write_s7_message_user_data */
    .messageType = 0x07 }
 
diff --git a/plc4c/generated-sources/s7/src/s7_parameter.c b/plc4c/generated-sources/s7/src/s7_parameter.c
index 9e642ca..c86fa98 100644
--- a/plc4c/generated-sources/s7/src/s7_parameter.c
+++ b/plc4c/generated-sources/s7/src/s7_parameter.c
@@ -27,20 +27,20 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_s7_read_write_s7_parameter_discriminator plc4c_s7_read_write_s7_parameter_discriminators[] = {
-  {/* plc4c_s7_read_write_s7_parameter_mode_transition */
-   .parameterType = 0x01, .messageType = 0x07 },
+  {/* plc4c_s7_read_write_s7_parameter_setup_communication */
+   .parameterType = 0xF0, .messageType = -1 },
   {/* plc4c_s7_read_write_s7_parameter_read_var_request */
    .parameterType = 0x04, .messageType = 0x01 },
   {/* plc4c_s7_read_write_s7_parameter_read_var_response */
    .parameterType = 0x04, .messageType = 0x03 },
-  {/* plc4c_s7_read_write_s7_parameter_user_data */
-   .parameterType = 0x00, .messageType = 0x07 },
   {/* plc4c_s7_read_write_s7_parameter_write_var_request */
    .parameterType = 0x05, .messageType = 0x01 },
-  {/* plc4c_s7_read_write_s7_parameter_setup_communication */
-   .parameterType = 0xF0, .messageType = -1 },
   {/* plc4c_s7_read_write_s7_parameter_write_var_response */
-   .parameterType = 0x05, .messageType = 0x03 }
+   .parameterType = 0x05, .messageType = 0x03 },
+  {/* plc4c_s7_read_write_s7_parameter_user_data */
+   .parameterType = 0x00, .messageType = 0x07 },
+  {/* plc4c_s7_read_write_s7_parameter_mode_transition */
+   .parameterType = 0x01, .messageType = 0x07 }
 
 };
 
diff --git a/plc4c/generated-sources/s7/src/s7_payload.c b/plc4c/generated-sources/s7/src/s7_payload.c
index 02e3a49..7c8ad7c 100644
--- a/plc4c/generated-sources/s7/src/s7_payload.c
+++ b/plc4c/generated-sources/s7/src/s7_payload.c
@@ -27,14 +27,14 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_s7_read_write_s7_payload_discriminator plc4c_s7_read_write_s7_payload_discriminators[] = {
-  {/* plc4c_s7_read_write_s7_payload_user_data */
-   .parameterParameterType = 0x00, .messageType = 0x07 },
-  {/* plc4c_s7_read_write_s7_payload_write_var_response */
-   .parameterParameterType = 0x05, .messageType = 0x03 },
+  {/* plc4c_s7_read_write_s7_payload_read_var_response */
+   .parameterParameterType = 0x04, .messageType = 0x03 },
   {/* plc4c_s7_read_write_s7_payload_write_var_request */
    .parameterParameterType = 0x05, .messageType = 0x01 },
-  {/* plc4c_s7_read_write_s7_payload_read_var_response */
-   .parameterParameterType = 0x04, .messageType = 0x03 }
+  {/* plc4c_s7_read_write_s7_payload_write_var_response */
+   .parameterParameterType = 0x05, .messageType = 0x03 },
+  {/* plc4c_s7_read_write_s7_payload_user_data */
+   .parameterParameterType = 0x00, .messageType = 0x07 }
 
 };
 
diff --git a/plc4c/generated-sources/s7/src/s7_payload_user_data_item.c b/plc4c/generated-sources/s7/src/s7_payload_user_data_item.c
index e1eeb47..829c5e0 100644
--- a/plc4c/generated-sources/s7/src/s7_payload_user_data_item.c
+++ b/plc4c/generated-sources/s7/src/s7_payload_user_data_item.c
@@ -27,42 +27,42 @@
 // (The order is identical to the enum constants so we can use the
 // enum constant to directly access a given types discriminator values)
 const plc4c_s7_read_write_s7_payload_user_data_item_discriminator plc4c_s7_read_write_s7_payload_user_data_item_discriminators[] = {
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_response */
-   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x00 },
+  {/* plc4c_s7_read_write_s7_payload_diagnostic_message */
+   .cpuFunctionType = 0x00, .cpuSubfunction = 0x03, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_alarm8 */
    .cpuFunctionType = 0x00, .cpuSubfunction = 0x05, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_alarm_sc */
-   .cpuFunctionType = 0x00, .cpuSubfunction = 0x13, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_notify */
    .cpuFunctionType = 0x00, .cpuSubfunction = 0x06, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_alarm_ack_ind */
    .cpuFunctionType = 0x00, .cpuSubfunction = 0x0c, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_sys_response */
-   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x02 },
+  {/* plc4c_s7_read_write_s7_payload_alarm_sq */
+   .cpuFunctionType = 0x00, .cpuSubfunction = 0x11, .dataLength = -1 },
+  {/* plc4c_s7_read_write_s7_payload_alarm_s */
+   .cpuFunctionType = 0x00, .cpuSubfunction = 0x12, .dataLength = -1 },
+  {/* plc4c_s7_read_write_s7_payload_alarm_sc */
+   .cpuFunctionType = 0x00, .cpuSubfunction = 0x13, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_notify8 */
    .cpuFunctionType = 0x00, .cpuSubfunction = 0x16, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_ack_response */
-   .cpuFunctionType = 0x08, .cpuSubfunction = 0x0b, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_diagnostic_message */
-   .cpuFunctionType = 0x00, .cpuSubfunction = 0x03, .dataLength = -1 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_read_szl_request */
+   .cpuFunctionType = 0x04, .cpuSubfunction = 0x01, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_read_szl_response */
    .cpuFunctionType = 0x08, .cpuSubfunction = 0x01, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_alarm_response */
-   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x05 },
   {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription */
    .cpuFunctionType = 0x04, .cpuSubfunction = 0x02, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_alarm_sq */
-   .cpuFunctionType = 0x00, .cpuSubfunction = 0x11, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_alarm_s */
-   .cpuFunctionType = 0x00, .cpuSubfunction = 0x12, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_query_response */
-   .cpuFunctionType = 0x08, .cpuSubfunction = 0x13, .dataLength = -1 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_response */
+   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x00 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_sys_response */
+   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x02 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_msg_subscription_alarm_response */
+   .cpuFunctionType = 0x08, .cpuSubfunction = 0x02, .dataLength = 0x05 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_ack */
+   .cpuFunctionType = 0x04, .cpuSubfunction = 0x0b, .dataLength = -1 },
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_ack_response */
+   .cpuFunctionType = 0x08, .cpuSubfunction = 0x0b, .dataLength = -1 },
   {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_query */
    .cpuFunctionType = 0x04, .cpuSubfunction = 0x13, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_read_szl_request */
-   .cpuFunctionType = 0x04, .cpuSubfunction = 0x01, .dataLength = -1 },
-  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_ack */
-   .cpuFunctionType = 0x04, .cpuSubfunction = 0x0b, .dataLength = -1 }
+  {/* plc4c_s7_read_write_s7_payload_user_data_item_cpu_function_alarm_query_response */
+   .cpuFunctionType = 0x08, .cpuSubfunction = 0x13, .dataLength = -1 }
 
 };
 
@@ -80,34 +80,34 @@ plc4c_s7_read_write_s7_payload_user_data_item plc4c_s7_read_write_s7_payload_use
 
 
 // Constant values.
+static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC_const = 0x12;
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC() {
+  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC_const;
+}
+static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ_const = 0x01;
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ() {
+  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ_const;
+}
 static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_LENGTH_const = 0x08;
 uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_LENGTH() {
   return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_LENGTH_const;
 }
-static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID_const = 0x00;
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID() {
-  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID_const;
+static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID_const = 0x00;
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID() {
+  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID_const;
 }
 static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_NUMBER_MESSAGE_OBJ_const = 0x01;
 uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_NUMBER_MESSAGE_OBJ() {
   return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_NUMBER_MESSAGE_OBJ_const;
 }
+static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID_const = 0x00;
+uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID() {
+  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_FUNCTION_ID_const;
+}
 static const uint16_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_READ_SZL_RESPONSE_SZL_ITEM_LENGTH_const = 28;
 uint16_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_READ_SZL_RESPONSE_SZL_ITEM_LENGTH() {
   return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_READ_SZL_RESPONSE_SZL_ITEM_LENGTH_const;
 }
-static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC_const = 0x12;
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC() {
-  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_VARIABLE_SPEC_const;
-}
-static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ_const = 0x01;
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ() {
-  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_RESPONSE_NUMBER_MESSAGE_OBJ_const;
-}
-static const uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID_const = 0x00;
-uint8_t PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID() {
-  return PLC4C_S7_READ_WRITE_S7_PAYLOAD_USER_DATA_ITEM_CPU_FUNCTION_ALARM_QUERY_FUNCTION_ID_const;
-}
 
 // Parse function.
 plc4c_return_code plc4c_s7_read_write_s7_payload_user_data_item_parse(plc4c_spi_read_buffer* readBuffer, uint8_t cpuFunctionType, uint8_t cpuSubfunction, plc4c_s7_read_write_s7_payload_user_data_item** _message) {