aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Embedded_SW/Embedded')
-rw-r--r--Software/Embedded_SW/Embedded/.cproject2
-rw-r--r--Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.c4
-rw-r--r--Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.h12
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Connection.c70
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Connection.h15
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Container.c16
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Container.h2
-rw-r--r--Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.c92
-rw-r--r--Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.h71pre { line-height: 125%; } td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } .highlight .hll { background-color: #ffffcc } .highlight .c { color: #888888 } /* Comment */ .highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */ .highlight .k { color: #008800; font-weight: bold } /* Keyword */ .highlight .ch { color: #888888 } /* Comment.Hashbang */ .highlight .cm { color: #888888 } /* Comment.Multiline */ .highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */ .highlight .cpf { color: #888888 } /* Comment.PreprocFile */ .highlight .c1 { color: #888888 } /* Comment.Single */ .highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */ .highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */ .highlight .ge { font-style: italic } /* Generic.Emph */ .highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */ .highlight .gr { color: #aa0000 } /* Generic.Error */ .highlight .gh { color: #333333 } /* Generic.Heading */ .highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */ .highlight .go { color: #888888 } /* Generic.Output */ .highlight .gp { color: #555555 } /* Generic.Prompt */ .highlight .gs { font-weight: bold } /* Generic.Strong */ .highlight .gu { color: #666666 } /* Generic.Subheading */ .highlight .gt { color: #aa0000 } /* Generic.Traceback */ .highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */ .highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */ .highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */ .highlight .kp { color: #008800 } /* Keyword.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
using Microsoft.Win32;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Tango.BL.Entities;
using Tango.Core.Commands;
using Tango.MachineStudio.Common.Notifications;
using Tango.MachineStudio.Common.Tup;
using Tango.SharedUI;

namespace Tango.MachineStudio.MachineDesigner.ViewModels
{
    public class TupViewVM : ViewModel
    {
        private INotificationProvider _notification;

        private String _latestVersion;
        public String LatestVersion
        {
            get { return _latestVersion; }
            set { _latestVersion = value; RaisePropertyChangedAuto(); }
        }

        private Machine _machine;
        public Machine Machine
        {
            get { return _machine; }
            set { _machine = value; RaisePropertyChangedAuto(); }
        }

        private String _filePath;
        public String FilePath
        {
            get { return _filePath; }
            set { _filePath = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
        }

        private TupFileBuilderProgressEventArgs _progress;
        public TupFileBuilderProgressEventArgs Progress
        {
            get { return _progress; }
            set { _progress = value; RaisePropertyChangedAuto(); }
        }

        public RelayCommand CreateTupFileCommand { get; set; }

        public RelayCommand SelectFileCommand { get; set; }

        public TupViewVM()
        {

        }

        public TupViewVM(INotificationProvider notification) : this()
        {
            _notification = notification;
            CreateTupFileCommand = new RelayCommand(CreateTupFile, () => FilePath != null && IsFree);
            SelectFileCommand = new RelayCommand(SelectFile);
        }

        public void Init(Machine machine)
        {
            Machine = machine;
            DisplayLatestPPCVersion();
        }

        private async void DisplayLatestPPCVersion()
        {
            TupFileBuilder builder = new TupFileBuilder();

            try
            {
                LatestVersion = await builder.GetLatestPPCVersion(Machine.SerialNumber);
            }
            catch (Exception ex)
            {
                LogManager.Log(ex, "Error retrieving latest PPC version.");
                await Task.Delay(5000);
                DisplayLatestPPCVersion();
            }
        }

        private void SelectFile()
        {
            SaveFileDialog dlg = new SaveFileDialog();
            dlg.Title = "Select package location";
            dlg.Filter = "Tango Update Package Files|*.tup";
            dlg.DefaultExt = ".tup";
            dlg.FileName = LatestVersion == null ? $"{Machine.SerialNumber}_Update_{DateTime.Now.Date.ToFileName()}.tup" : $"{Machine.SerialNumber}_Update_{DateTime.Now.Date.ToFileName()}_v{LatestVersion}.tup";

            if (dlg.ShowDialog().Value)
            {
                FilePath = dlg.FileName;
            }
        }

        private async void CreateTupFile()
        {
            try
            {
                LogManager.Log($"Generating TUP file to '{FilePath}'...");

                IsFree = false;
                TupFileBuilder builder = new TupFileBuilder();
                builder.Progress += Builder_Progress;
                await builder.Build(Machine.SerialNumber, FilePath);

                LogManager.Log("TUP file generated successfully.");
                _notification.ShowInfo("Tango update package created successfuly.");
            }
            catch (Exception ex)
            {
                LogManager.Log(ex, "Error generating tup file.");
                _notification.ShowError($"An error occurred while generating the .tup file.\n{ex.FlattenMessage()}");
            }
            finally
            {
                IsFree = true;
            }
        }

        private void Builder_Progress(object sender, TupFileBuilderProgressEventArgs e)
        {
            Progress = e;
        }
    }
}
ars(char* buffer,size_t length);
+
#endif //CONTAINER_H
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.c
new file mode 100644
index 000000000..127b22ef3
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.c
@@ -0,0 +1,92 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: ConnectRequest.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "ConnectRequest.pb-c.h"
+void connect_request__init
+ (ConnectRequest *message)
+{
+ static const ConnectRequest init_value = CONNECT_REQUEST__INIT;
+ *message = init_value;
+}
+size_t connect_request__get_packed_size
+ (const ConnectRequest *message)
+{
+ assert(message->base.descriptor == &connect_request__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t connect_request__pack
+ (const ConnectRequest *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &connect_request__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t connect_request__pack_to_buffer
+ (const ConnectRequest *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &connect_request__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+ConnectRequest *
+ connect_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (ConnectRequest *)
+ protobuf_c_message_unpack (&connect_request__descriptor,
+ allocator, len, data);
+}
+void connect_request__free_unpacked
+ (ConnectRequest *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &connect_request__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+static const ProtobufCFieldDescriptor connect_request__field_descriptors[1] =
+{
+ {
+ "Password",
+ 1,
+ PROTOBUF_C_LABEL_OPTIONAL,
+ PROTOBUF_C_TYPE_STRING,
+ 0, /* quantifier_offset */
+ offsetof(ConnectRequest, password),
+ NULL,
+ NULL,
+ 0, /* flags */
+ 0,NULL,NULL /* reserved1,reserved2, etc */
+ },
+};
+static const unsigned connect_request__field_indices_by_name[] = {
+ 0, /* field[0] = Password */
+};
+static const ProtobufCIntRange connect_request__number_ranges[1 + 1] =
+{
+ { 1, 0 },
+ { 0, 1 }
+};
+const ProtobufCMessageDescriptor connect_request__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "ConnectRequest",
+ "ConnectRequest",
+ "ConnectRequest",
+ "",
+ sizeof(ConnectRequest),
+ 1,
+ connect_request__field_descriptors,
+ connect_request__field_indices_by_name,
+ 1, connect_request__number_ranges,
+ (ProtobufCMessageInit) connect_request__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.h
new file mode 100644
index 000000000..6e6be56e5
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectRequest.pb-c.h
@@ -0,0 +1,71 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: ConnectRequest.proto */
+
+#ifndef PROTOBUF_C_ConnectRequest_2eproto__INCLUDED
+#define PROTOBUF_C_ConnectRequest_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _ConnectRequest ConnectRequest;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _ConnectRequest
+{
+ ProtobufCMessage base;
+ char *password;
+};
+#define CONNECT_REQUEST__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&connect_request__descriptor) \
+ , NULL }
+
+
+/* ConnectRequest methods */
+void connect_request__init
+ (ConnectRequest *message);
+size_t connect_request__get_packed_size
+ (const ConnectRequest *message);
+size_t connect_request__pack
+ (const ConnectRequest *message,
+ uint8_t *out);
+size_t connect_request__pack_to_buffer
+ (const ConnectRequest *message,
+ ProtobufCBuffer *buffer);
+ConnectRequest *
+ connect_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void connect_request__free_unpacked
+ (ConnectRequest *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*ConnectRequest_Closure)
+ (const ConnectRequest *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor connect_request__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_ConnectRequest_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.c
new file mode 100644
index 000000000..ce449266e
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.c
@@ -0,0 +1,92 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: ConnectResponse.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "ConnectResponse.pb-c.h"
+void connect_response__init
+ (ConnectResponse *message)
+{
+ static const ConnectResponse init_value = CONNECT_RESPONSE__INIT;
+ *message = init_value;
+}
+size_t connect_response__get_packed_size
+ (const ConnectResponse *message)
+{
+ assert(message->base.descriptor == &connect_response__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t connect_response__pack
+ (const ConnectResponse *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &connect_response__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t connect_response__pack_to_buffer
+ (const ConnectResponse *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &connect_response__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+ConnectResponse *
+ connect_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (ConnectResponse *)
+ protobuf_c_message_unpack (&connect_response__descriptor,
+ allocator, len, data);
+}
+void connect_response__free_unpacked
+ (ConnectResponse *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &connect_response__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+static const ProtobufCFieldDescriptor connect_response__field_descriptors[1] =
+{
+ {
+ "DeviceInformation",
+ 1,
+ PROTOBUF_C_LABEL_OPTIONAL,
+ PROTOBUF_C_TYPE_MESSAGE,
+ 0, /* quantifier_offset */
+ offsetof(ConnectResponse, deviceinformation),
+ &device_information__descriptor,
+ NULL,
+ 0, /* flags */
+ 0,NULL,NULL /* reserved1,reserved2, etc */
+ },
+};
+static const unsigned connect_response__field_indices_by_name[] = {
+ 0, /* field[0] = DeviceInformation */
+};
+static const ProtobufCIntRange connect_response__number_ranges[1 + 1] =
+{
+ { 1, 0 },
+ { 0, 1 }
+};
+const ProtobufCMessageDescriptor connect_response__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "ConnectResponse",
+ "ConnectResponse",
+ "ConnectResponse",
+ "",
+ sizeof(ConnectResponse),
+ 1,
+ connect_response__field_descriptors,
+ connect_response__field_indices_by_name,
+ 1, connect_response__number_ranges,
+ (ProtobufCMessageInit) connect_response__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.h
new file mode 100644
index 000000000..85a15995c
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/ConnectResponse.pb-c.h
@@ -0,0 +1,72 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: ConnectResponse.proto */
+
+#ifndef PROTOBUF_C_ConnectResponse_2eproto__INCLUDED
+#define PROTOBUF_C_ConnectResponse_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+#include "DeviceInformation.pb-c.h"
+
+typedef struct _ConnectResponse ConnectResponse;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _ConnectResponse
+{
+ ProtobufCMessage base;
+ DeviceInformation *deviceinformation;
+};
+#define CONNECT_RESPONSE__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&connect_response__descriptor) \
+ , NULL }
+
+
+/* ConnectResponse methods */
+void connect_response__init
+ (ConnectResponse *message);
+size_t connect_response__get_packed_size
+ (const ConnectResponse *message);
+size_t connect_response__pack
+ (const ConnectResponse *message,
+ uint8_t *out);
+size_t connect_response__pack_to_buffer
+ (const ConnectResponse *message,
+ ProtobufCBuffer *buffer);
+ConnectResponse *
+ connect_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void connect_response__free_unpacked
+ (ConnectResponse *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*ConnectResponse_Closure)
+ (const ConnectResponse *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor connect_response__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_ConnectResponse_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.c
new file mode 100644
index 000000000..2ecae726e
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.c
@@ -0,0 +1,118 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DeviceInformation.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "DeviceInformation.pb-c.h"
+void device_information__init
+ (DeviceInformation *message)
+{
+ static const DeviceInformation init_value = DEVICE_INFORMATION__INIT;
+ *message = init_value;
+}
+size_t device_information__get_packed_size
+ (const DeviceInformation *message)
+{
+ assert(message->base.descriptor == &device_information__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t device_information__pack
+ (const DeviceInformation *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &device_information__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t device_information__pack_to_buffer
+ (const DeviceInformation *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &device_information__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+DeviceInformation *
+ device_information__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (DeviceInformation *)
+ protobuf_c_message_unpack (&device_information__descriptor,
+ allocator, len, data);
+}
+void device_information__free_unpacked
+ (DeviceInformation *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &device_information__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+static const ProtobufCFieldDescriptor device_information__field_descriptors[3] =
+{
+ {
+ "Name",
+ 1,
+ PROTOBUF_C_LABEL_OPTIONAL,
+ PROTOBUF_C_TYPE_STRING,
+ 0, /* quantifier_offset */
+ offsetof(DeviceInformation, name),
+ NULL,
+ NULL,
+ 0, /* flags */
+ 0,NULL,NULL /* reserved1,reserved2, etc */
+ },
+ {
+ "Version",
+ 2,
+ PROTOBUF_C_LABEL_OPTIONAL,
+ PROTOBUF_C_TYPE_STRING,
+ 0, /* quantifier_offset */
+ offsetof(DeviceInformation, version),
+ NULL,
+ NULL,
+ 0, /* flags */
+ 0,NULL,NULL /* reserved1,reserved2, etc */
+ },
+ {
+ "BuildDate",
+ 3,
+ PROTOBUF_C_LABEL_OPTIONAL,
+ PROTOBUF_C_TYPE_STRING,
+ 0, /* quantifier_offset */
+ offsetof(DeviceInformation, builddate),
+ NULL,
+ NULL,
+ 0, /* flags */
+ 0,NULL,NULL /* reserved1,reserved2, etc */
+ },
+};
+static const unsigned device_information__field_indices_by_name[] = {
+ 2, /* field[2] = BuildDate */
+ 0, /* field[0] = Name */
+ 1, /* field[1] = Version */
+};
+static const ProtobufCIntRange device_information__number_ranges[1 + 1] =
+{
+ { 1, 0 },
+ { 0, 3 }
+};
+const ProtobufCMessageDescriptor device_information__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "DeviceInformation",
+ "DeviceInformation",
+ "DeviceInformation",
+ "",
+ sizeof(DeviceInformation),
+ 3,
+ device_information__field_descriptors,
+ device_information__field_indices_by_name,
+ 1, device_information__number_ranges,
+ (ProtobufCMessageInit) device_information__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.h
new file mode 100644
index 000000000..521c77424
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DeviceInformation.pb-c.h
@@ -0,0 +1,73 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DeviceInformation.proto */
+
+#ifndef PROTOBUF_C_DeviceInformation_2eproto__INCLUDED
+#define PROTOBUF_C_DeviceInformation_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _DeviceInformation DeviceInformation;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _DeviceInformation
+{
+ ProtobufCMessage base;
+ char *name;
+ char *version;
+ char *builddate;
+};
+#define DEVICE_INFORMATION__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&device_information__descriptor) \
+ , NULL, NULL, NULL }
+
+
+/* DeviceInformation methods */
+void device_information__init
+ (DeviceInformation *message);
+size_t device_information__get_packed_size
+ (const DeviceInformation *message);
+size_t device_information__pack
+ (const DeviceInformation *message,
+ uint8_t *out);
+size_t device_information__pack_to_buffer
+ (const DeviceInformation *message,
+ ProtobufCBuffer *buffer);
+DeviceInformation *
+ device_information__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void device_information__free_unpacked
+ (DeviceInformation *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*DeviceInformation_Closure)
+ (const DeviceInformation *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor device_information__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_DeviceInformation_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.c
new file mode 100644
index 000000000..39e442cbe
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.c
@@ -0,0 +1,72 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DisconnectRequest.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "DisconnectRequest.pb-c.h"
+void disconnect_request__init
+ (DisconnectRequest *message)
+{
+ static const DisconnectRequest init_value = DISCONNECT_REQUEST__INIT;
+ *message = init_value;
+}
+size_t disconnect_request__get_packed_size
+ (const DisconnectRequest *message)
+{
+ assert(message->base.descriptor == &disconnect_request__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t disconnect_request__pack
+ (const DisconnectRequest *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &disconnect_request__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t disconnect_request__pack_to_buffer
+ (const DisconnectRequest *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &disconnect_request__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+DisconnectRequest *
+ disconnect_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (DisconnectRequest *)
+ protobuf_c_message_unpack (&disconnect_request__descriptor,
+ allocator, len, data);
+}
+void disconnect_request__free_unpacked
+ (DisconnectRequest *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &disconnect_request__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+#define disconnect_request__field_descriptors NULL
+#define disconnect_request__field_indices_by_name NULL
+#define disconnect_request__number_ranges NULL
+const ProtobufCMessageDescriptor disconnect_request__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "DisconnectRequest",
+ "DisconnectRequest",
+ "DisconnectRequest",
+ "",
+ sizeof(DisconnectRequest),
+ 0,
+ disconnect_request__field_descriptors,
+ disconnect_request__field_indices_by_name,
+ 0, disconnect_request__number_ranges,
+ (ProtobufCMessageInit) disconnect_request__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.h
new file mode 100644
index 000000000..1f7fa145b
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectRequest.pb-c.h
@@ -0,0 +1,70 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DisconnectRequest.proto */
+
+#ifndef PROTOBUF_C_DisconnectRequest_2eproto__INCLUDED
+#define PROTOBUF_C_DisconnectRequest_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _DisconnectRequest DisconnectRequest;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _DisconnectRequest
+{
+ ProtobufCMessage base;
+};
+#define DISCONNECT_REQUEST__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&disconnect_request__descriptor) \
+ }
+
+
+/* DisconnectRequest methods */
+void disconnect_request__init
+ (DisconnectRequest *message);
+size_t disconnect_request__get_packed_size
+ (const DisconnectRequest *message);
+size_t disconnect_request__pack
+ (const DisconnectRequest *message,
+ uint8_t *out);
+size_t disconnect_request__pack_to_buffer
+ (const DisconnectRequest *message,
+ ProtobufCBuffer *buffer);
+DisconnectRequest *
+ disconnect_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void disconnect_request__free_unpacked
+ (DisconnectRequest *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*DisconnectRequest_Closure)
+ (const DisconnectRequest *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor disconnect_request__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_DisconnectRequest_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.c
new file mode 100644
index 000000000..e17f48d2b
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.c
@@ -0,0 +1,72 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DisconnectResponse.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "DisconnectResponse.pb-c.h"
+void disconnect_response__init
+ (DisconnectResponse *message)
+{
+ static const DisconnectResponse init_value = DISCONNECT_RESPONSE__INIT;
+ *message = init_value;
+}
+size_t disconnect_response__get_packed_size
+ (const DisconnectResponse *message)
+{
+ assert(message->base.descriptor == &disconnect_response__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t disconnect_response__pack
+ (const DisconnectResponse *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &disconnect_response__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t disconnect_response__pack_to_buffer
+ (const DisconnectResponse *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &disconnect_response__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+DisconnectResponse *
+ disconnect_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (DisconnectResponse *)
+ protobuf_c_message_unpack (&disconnect_response__descriptor,
+ allocator, len, data);
+}
+void disconnect_response__free_unpacked
+ (DisconnectResponse *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &disconnect_response__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+#define disconnect_response__field_descriptors NULL
+#define disconnect_response__field_indices_by_name NULL
+#define disconnect_response__number_ranges NULL
+const ProtobufCMessageDescriptor disconnect_response__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "DisconnectResponse",
+ "DisconnectResponse",
+ "DisconnectResponse",
+ "",
+ sizeof(DisconnectResponse),
+ 0,
+ disconnect_response__field_descriptors,
+ disconnect_response__field_indices_by_name,
+ 0, disconnect_response__number_ranges,
+ (ProtobufCMessageInit) disconnect_response__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.h
new file mode 100644
index 000000000..3518f360f
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/DisconnectResponse.pb-c.h
@@ -0,0 +1,70 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: DisconnectResponse.proto */
+
+#ifndef PROTOBUF_C_DisconnectResponse_2eproto__INCLUDED
+#define PROTOBUF_C_DisconnectResponse_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _DisconnectResponse DisconnectResponse;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _DisconnectResponse
+{
+ ProtobufCMessage base;
+};
+#define DISCONNECT_RESPONSE__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&disconnect_response__descriptor) \
+ }
+
+
+/* DisconnectResponse methods */
+void disconnect_response__init
+ (DisconnectResponse *message);
+size_t disconnect_response__get_packed_size
+ (const DisconnectResponse *message);
+size_t disconnect_response__pack
+ (const DisconnectResponse *message,
+ uint8_t *out);
+size_t disconnect_response__pack_to_buffer
+ (const DisconnectResponse *message,
+ ProtobufCBuffer *buffer);
+DisconnectResponse *
+ disconnect_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void disconnect_response__free_unpacked
+ (DisconnectResponse *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*DisconnectResponse_Closure)
+ (const DisconnectResponse *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor disconnect_response__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_DisconnectResponse_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.c
new file mode 100644
index 000000000..70fca2425
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.c
@@ -0,0 +1,72 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: KeepAliveRequest.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "KeepAliveRequest.pb-c.h"
+void keep_alive_request__init
+ (KeepAliveRequest *message)
+{
+ static const KeepAliveRequest init_value = KEEP_ALIVE_REQUEST__INIT;
+ *message = init_value;
+}
+size_t keep_alive_request__get_packed_size
+ (const KeepAliveRequest *message)
+{
+ assert(message->base.descriptor == &keep_alive_request__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t keep_alive_request__pack
+ (const KeepAliveRequest *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &keep_alive_request__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t keep_alive_request__pack_to_buffer
+ (const KeepAliveRequest *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &keep_alive_request__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+KeepAliveRequest *
+ keep_alive_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (KeepAliveRequest *)
+ protobuf_c_message_unpack (&keep_alive_request__descriptor,
+ allocator, len, data);
+}
+void keep_alive_request__free_unpacked
+ (KeepAliveRequest *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &keep_alive_request__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+#define keep_alive_request__field_descriptors NULL
+#define keep_alive_request__field_indices_by_name NULL
+#define keep_alive_request__number_ranges NULL
+const ProtobufCMessageDescriptor keep_alive_request__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "KeepAliveRequest",
+ "KeepAliveRequest",
+ "KeepAliveRequest",
+ "",
+ sizeof(KeepAliveRequest),
+ 0,
+ keep_alive_request__field_descriptors,
+ keep_alive_request__field_indices_by_name,
+ 0, keep_alive_request__number_ranges,
+ (ProtobufCMessageInit) keep_alive_request__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.h
new file mode 100644
index 000000000..379aa6caa
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveRequest.pb-c.h
@@ -0,0 +1,70 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: KeepAliveRequest.proto */
+
+#ifndef PROTOBUF_C_KeepAliveRequest_2eproto__INCLUDED
+#define PROTOBUF_C_KeepAliveRequest_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _KeepAliveRequest KeepAliveRequest;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _KeepAliveRequest
+{
+ ProtobufCMessage base;
+};
+#define KEEP_ALIVE_REQUEST__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&keep_alive_request__descriptor) \
+ }
+
+
+/* KeepAliveRequest methods */
+void keep_alive_request__init
+ (KeepAliveRequest *message);
+size_t keep_alive_request__get_packed_size
+ (const KeepAliveRequest *message);
+size_t keep_alive_request__pack
+ (const KeepAliveRequest *message,
+ uint8_t *out);
+size_t keep_alive_request__pack_to_buffer
+ (const KeepAliveRequest *message,
+ ProtobufCBuffer *buffer);
+KeepAliveRequest *
+ keep_alive_request__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void keep_alive_request__free_unpacked
+ (KeepAliveRequest *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*KeepAliveRequest_Closure)
+ (const KeepAliveRequest *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor keep_alive_request__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_KeepAliveRequest_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.c
new file mode 100644
index 000000000..9bae1f119
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.c
@@ -0,0 +1,72 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: KeepAliveResponse.proto */
+
+/* Do not generate deprecated warnings for self */
+#ifndef PROTOBUF_C__NO_DEPRECATED
+#define PROTOBUF_C__NO_DEPRECATED
+#endif
+
+#include "KeepAliveResponse.pb-c.h"
+void keep_alive_response__init
+ (KeepAliveResponse *message)
+{
+ static const KeepAliveResponse init_value = KEEP_ALIVE_RESPONSE__INIT;
+ *message = init_value;
+}
+size_t keep_alive_response__get_packed_size
+ (const KeepAliveResponse *message)
+{
+ assert(message->base.descriptor == &keep_alive_response__descriptor);
+ return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
+}
+size_t keep_alive_response__pack
+ (const KeepAliveResponse *message,
+ uint8_t *out)
+{
+ assert(message->base.descriptor == &keep_alive_response__descriptor);
+ return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
+}
+size_t keep_alive_response__pack_to_buffer
+ (const KeepAliveResponse *message,
+ ProtobufCBuffer *buffer)
+{
+ assert(message->base.descriptor == &keep_alive_response__descriptor);
+ return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
+}
+KeepAliveResponse *
+ keep_alive_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data)
+{
+ return (KeepAliveResponse *)
+ protobuf_c_message_unpack (&keep_alive_response__descriptor,
+ allocator, len, data);
+}
+void keep_alive_response__free_unpacked
+ (KeepAliveResponse *message,
+ ProtobufCAllocator *allocator)
+{
+ if(!message)
+ return;
+ assert(message->base.descriptor == &keep_alive_response__descriptor);
+ protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
+}
+#define keep_alive_response__field_descriptors NULL
+#define keep_alive_response__field_indices_by_name NULL
+#define keep_alive_response__number_ranges NULL
+const ProtobufCMessageDescriptor keep_alive_response__descriptor =
+{
+ PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
+ "KeepAliveResponse",
+ "KeepAliveResponse",
+ "KeepAliveResponse",
+ "",
+ sizeof(KeepAliveResponse),
+ 0,
+ keep_alive_response__field_descriptors,
+ keep_alive_response__field_indices_by_name,
+ 0, keep_alive_response__number_ranges,
+ (ProtobufCMessageInit) keep_alive_response__init,
+ NULL,NULL,NULL /* reserved[123] */
+};
diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.h
new file mode 100644
index 000000000..a29f79c99
--- /dev/null
+++ b/Software/Embedded_SW/Embedded/Communication/PMR/Connection/KeepAliveResponse.pb-c.h
@@ -0,0 +1,70 @@
+/* Generated by the protocol buffer compiler. DO NOT EDIT! */
+/* Generated from: KeepAliveResponse.proto */
+
+#ifndef PROTOBUF_C_KeepAliveResponse_2eproto__INCLUDED
+#define PROTOBUF_C_KeepAliveResponse_2eproto__INCLUDED
+
+#include <protobuf-c/protobuf-c.h>
+
+PROTOBUF_C__BEGIN_DECLS
+
+#if PROTOBUF_C_VERSION_NUMBER < 1003000
+# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
+#elif 1003000 < PROTOBUF_C_MIN_COMPILER_VERSION
+# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
+#endif
+
+
+typedef struct _KeepAliveResponse KeepAliveResponse;
+
+
+/* --- enums --- */
+
+
+/* --- messages --- */
+
+struct _KeepAliveResponse
+{
+ ProtobufCMessage base;
+};
+#define KEEP_ALIVE_RESPONSE__INIT \
+ { PROTOBUF_C_MESSAGE_INIT (&keep_alive_response__descriptor) \
+ }
+
+
+/* KeepAliveResponse methods */
+void keep_alive_response__init
+ (KeepAliveResponse *message);
+size_t keep_alive_response__get_packed_size
+ (const KeepAliveResponse *message);
+size_t keep_alive_response__pack
+ (const KeepAliveResponse *message,
+ uint8_t *out);
+size_t keep_alive_response__pack_to_buffer
+ (const KeepAliveResponse *message,
+ ProtobufCBuffer *buffer);
+KeepAliveResponse *
+ keep_alive_response__unpack
+ (ProtobufCAllocator *allocator,
+ size_t len,
+ const uint8_t *data);
+void keep_alive_response__free_unpacked
+ (KeepAliveResponse *message,
+ ProtobufCAllocator *allocator);
+/* --- per-message closures --- */
+
+typedef void (*KeepAliveResponse_Closure)
+ (const KeepAliveResponse *message,
+ void *closure_data);
+
+/* --- services --- */
+
+
+/* --- descriptors --- */
+
+extern const ProtobufCMessageDescriptor keep_alive_response__descriptor;
+
+PROTOBUF_C__END_DECLS
+
+
+#endif /* PROTOBUF_C_KeepAliveResponse_2eproto__INCLUDED */
diff --git a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c
index ca40ea259..1dfcfbfad 100644
--- a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c
+++ b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c
@@ -260,10 +260,6 @@ static tUSBDCDCDevice g_sCDCDevice =
//};
-uint32_t SendChars(char* buffer,size_t length)
-{
- return CommunicationTaskSendMessage(buffer, length);
-}
//*****************************************************************************
//
//! Waits for a character from the USB port.
diff --git a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.h b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.h
index c2bedce72..b1fb14f08 100644
--- a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.h
+++ b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.h
@@ -65,7 +65,6 @@ unsigned int USBCDCD_sendData(const unsigned char *_pBuff,
unsigned int USBCDCD_receiveData(unsigned char *_pBuff, unsigned int _length, unsigned int _timeout);
-uint32_t SendChars(char* buffer,size_t length);
/**********************************************************
* ======== USBCDCD_waitForConnect ========
diff --git a/Software/Embedded_SW/Embedded/Modules/Control/MillisecTask.c b/Software/Embedded_SW/Embedded/Modules/Control/MillisecTask.c
index c2cba7a4f..a1de29b08 100644
--- a/Software/Embedded_SW/Embedded/Modules/Control/MillisecTask.c
+++ b/Software/Embedded_SW/Embedded/Modules/Control/MillisecTask.c
@@ -233,6 +233,7 @@ uint32_t MillisecLoop(uint32_t tick)
//gather Motor data from FPGA
#ifndef EVALUATION_BOARD
FPGA_GetBusy(); //load the busy motor information to all motors
+ FPGA_Read_limit_Switches_Registers();
//Read_FPGA_GPI_Rgisters();//FPGA_Read_limit_Switches();
#endif
diff --git a/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c b/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c
index 6f5c609cb..ff9acdb94 100644
--- a/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c
+++ b/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c
@@ -394,7 +394,7 @@ Data, 428, 80, 2641, False, False, 3, 4000, Standard DC
t++;
if (t >=11)
{
- HeatingTestSendResonse(0,false,GetHeaterState(index),DCInitialHeating[index],HeaterCmd[index].targettemperatue, readValue,DCTimeSliceAllocation[index],
+ HeatingTestSendResonse(0,false,GetHeaterState(index), DCInitialHeating[index],index, readValue,DCTimeSliceAllocation[index],
HeaterPIDConfig[index].m_calculatedError,"Standard DC");
t=0;
}
diff --git a/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Stub_Heater.c b/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Stub_Heater.c
index 8864776e0..a9c61a882 100644
--- a/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Stub_Heater.c
+++ b/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Stub_Heater.c
@@ -15,7 +15,6 @@
#include "inc/hw_uart.h"
#include "driverlib/gpio.h"
-#include "Drivers/USB_Communication/USBCDCD.h"
#include "drivers/twine_graphicslib/graphics_adapter.h"
diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
index cc3e317fe..40f5bfd7c 100644
--- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
+++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
@@ -133,15 +133,15 @@ uint32_t ThreadLengthCBFunction(uint32_t IfIndex, uint32_t ReadValue)
}
index = IfIndex&0xFF;
if (CurrentRequestedLength == 0.0)
- return;
+ return OK;
if (index != FEEDER_MOTOR)
{
LOG_ERROR (IfIndex, "Wrong Motor");
return 0xFFFFFFFF;
}
- CurrentPosition = MotorGetPositionFromFPGA_Res(ThreadMotorIdToMotorId[index]);
+ CurrentPosition = MotorGetPosition(ThreadMotorIdToMotorId[index]);
if (CurrentPosition == 0)
- return; //unusable data
+ return OK; //unusable data
if (initialpos == 0xFFFF)
initialpos = CurrentPosition;
positionDiff = Control_Delta_Position_Pass(CurrentPosition,PreviousPosition);