aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.h
blob: 2b0a9bff99c76a467f1fb0d957e0c27bff3a3f7b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/*
 * FirmwareUpgrade.h
 *
 *  Created on: Dec 24, 2018
 *      Author: shlomo
 */

#ifndef COMMON_SWUPDATE_FIRMWAREUPGRADE_H_
#define COMMON_SWUPDATE_FIRMWAREUPGRADE_H_

extern int CurrentFileSize;
extern int CurrentRunningFile;

uint32_t    ActivateVersionRequestFunc(MessageContainer* requestContainer);
uint32_t    ValidateVersionRequestFunc(MessageContainer* requestContainer);
bool SwUpgradeActive(void);



#endif /* COMMON_SWUPDATE_FIRMWAREUPGRADE_H_ */
ckground-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 */
/* Generated by the protocol buffer compiler.  DO NOT EDIT! */
/* Generated from: SetDigitalOutRequest.proto */

/* Do not generate deprecated warnings for self */
#ifndef PROTOBUF_C__NO_DEPRECATED
#define PROTOBUF_C__NO_DEPRECATED
#endif

#include "SetDigitalOutRequest.pb-c.h"
void   set_digital_out_request__init
                     (SetDigitalOutRequest         *message)
{
  static const SetDigitalOutRequest init_value = SET_DIGITAL_OUT_REQUEST__INIT;
  *message = init_value;
}
size_t set_digital_out_request__get_packed_size
                     (const SetDigitalOutRequest *message)
{
  assert(message->base.descriptor == &set_digital_out_request__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t set_digital_out_request__pack
                     (const SetDigitalOutRequest *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &set_digital_out_request__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t set_digital_out_request__pack_to_buffer
                     (const SetDigitalOutRequest *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &set_digital_out_request__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
SetDigitalOutRequest *
       set_digital_out_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (SetDigitalOutRequest *)
     protobuf_c_message_unpack (&set_digital_out_request__descriptor,
                                allocator, len, data);
}
void   set_digital_out_request__free_unpacked
                     (SetDigitalOutRequest *message,
                      ProtobufCAllocator *allocator)
{
  if(!message)
    return;
  assert(message->base.descriptor == &set_digital_out_request__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
static const ProtobufCFieldDescriptor set_digital_out_request__field_descriptors[2] =
{
  {
    "Port",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_INT32,
    offsetof(SetDigitalOutRequest, has_port),
    offsetof(SetDigitalOutRequest, port),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "Value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BOOL,
    offsetof(SetDigitalOutRequest, has_value),
    offsetof(SetDigitalOutRequest, value),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned set_digital_out_request__field_indices_by_name[] = {
  0,   /* field[0] = Port */
  1,   /* field[1] = Value */
};
static const ProtobufCIntRange set_digital_out_request__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor set_digital_out_request__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "SetDigitalOutRequest",
  "SetDigitalOutRequest",
  "SetDigitalOutRequest",
  "",
  sizeof(SetDigitalOutRequest),
  2,
  set_digital_out_request__field_descriptors,
  set_digital_out_request__field_indices_by_name,
  1,  set_digital_out_request__number_ranges,
  (ProtobufCMessageInit) set_digital_out_request__init,
  NULL,NULL,NULL    /* reserved[123] */
};