AWS IoT Over-the-air Update v3.0.0
Client library for AWS IoT OTA
ota_http_private.h
Go to the documentation of this file.
1/*
2 * AWS IoT Over-the-air Update v3.0.0
3 * Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
4 *
5 * Permission is hereby granted, free of charge, to any person obtaining a copy of
6 * this software and associated documentation files (the "Software"), to deal in
7 * the Software without restriction, including without limitation the rights to
8 * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9 * the Software, and to permit persons to whom the Software is furnished to do so,
10 * subject to the following conditions:
11 *
12 * The above copyright notice and this permission notice shall be included in all
13 * copies or substantial portions of the Software.
14 *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17 * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18 * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 */
22
28#ifndef OTA_HTTP_H
29#define OTA_HTTP_H
30
31/* OTA includes. */
32#include "ota.h"
33#include "ota_private.h"
34
35
47
48
61
62
80OtaErr_t decodeFileBlock_Http( const uint8_t * pMessageBuffer,
81 size_t messageSize,
82 int32_t * pFileId,
83 int32_t * pBlockId,
84 int32_t * pBlockSize,
85 uint8_t ** pPayload,
86 size_t * pPayloadSize );
87
100
108const char * OTA_HTTP_strerror( OtaHttpStatus_t status );
109
110#endif /* ifndef OTA_HTTP_H */
OtaHttpStatus_t
The OTA HTTP interface return status.
Definition: ota_http_interface.h:80
OtaErr_t
The OTA API return status. OTA agent error codes are in the upper 8 bits of the 32 bit OTA error word...
Definition: ota.h:73
OTA Agent Interface.
OtaErr_t cleanupData_Http(const OtaAgentContext_t *pAgentCtx)
Cleanup related to OTA data plane over HTTP.
Definition: ota_http.c:162
OtaErr_t requestDataBlock_Http(OtaAgentContext_t *pAgentCtx)
Request File block over HTTP.
Definition: ota_http.c:78
OtaErr_t initFileTransfer_Http(OtaAgentContext_t *pAgentCtx)
Initialize file transfer over HTTP.
Definition: ota_http.c:47
const char * OTA_HTTP_strerror(OtaHttpStatus_t status)
Status to string conversion for OTA HTTP interface status.
Definition: ota_http.c:175
OtaErr_t decodeFileBlock_Http(const uint8_t *pMessageBuffer, size_t messageSize, int32_t *pFileId, int32_t *pBlockId, int32_t *pBlockSize, uint8_t **pPayload, size_t *pPayloadSize)
Stub for decoding the file block.
Definition: ota_http.c:122
Macros, enums, variables, and definitions internal to the OTA Agent module and shared by other OTA mo...
The OTA agent is a singleton today. The structure keeps it nice and organized.
Definition: ota.h:290