- toolkit V2.8.0.1@14806 - BSL V1.8.0.0@14590 - tcpserver: V1.4.3.0@14676 (marshaller V2.4.0.1@14551)
61 lines
2.6 KiB
C
61 lines
2.6 KiB
C
/* SPDX-License-Identifier: MIT */
|
|
/**************************************************************************************
|
|
*
|
|
* Copyright (c) 2024, Hilscher Gesellschaft fuer Systemautomation mbH. All Rights Reserved.
|
|
*
|
|
* Changes:
|
|
*
|
|
* Version Date Author Description
|
|
* ----------------------------------------------------------------------------------
|
|
* 1 02.01.24 SD changed licensing terms
|
|
*
|
|
**************************************************************************************/
|
|
|
|
#ifndef __CIFXDOWNLOAD__H
|
|
#define __CIFXDOWNLOAD__H
|
|
|
|
/*****************************************************************************/
|
|
/*! \addtogroup CIFXDOWNLOADHOOK
|
|
* \{ */
|
|
/*****************************************************************************/
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif /* __cplusplus */
|
|
|
|
#include "cifXAPI_Wrapper.h"
|
|
|
|
/*****************************************************************************/
|
|
/*! Definition of the file storage callback
|
|
* \param ptBoardInfo Board information
|
|
* \param pszFileName Name of file to download
|
|
* \param ulFileSize Size of file buffer (pabFileData)
|
|
* \param pabFileData File buffer
|
|
* \param ulChannel Destination channel
|
|
* \param ulDownloadMode Download mode (DOWNLOAD_MODE_FIRMWARE,
|
|
DOWNLOAD_MODE_MODULE, DOWNLOAD_MODE_CONFIG)
|
|
* \param pvUser User pointer
|
|
* \return CIFX_NO_ERROR on success */
|
|
/*****************************************************************************/
|
|
typedef int32_t(*PFN_FILESTORAGE_CBK) ( BOARD_INFORMATION* ptBoardInfo,
|
|
char* pszFileName, uint32_t ulFileSize, uint8_t* pabFileData,
|
|
uint32_t ulChannel, uint32_t ulDownloadMode, void* pvUser);
|
|
|
|
/***************************************************************************
|
|
* Functions to install and remove download hook
|
|
***************************************************************************/
|
|
int32_t xDownloadHook_Install ( PDRIVER_FUNCTIONS ptDRVFunctions,
|
|
PFN_FILESTORAGE_CBK pfnFileStorageCbk, void* pvUser);
|
|
|
|
int32_t xDownloadHook_Remove ( void);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif /* __cplusplus */
|
|
|
|
/*****************************************************************************/
|
|
/* \} */
|
|
/*****************************************************************************/
|
|
|
|
#endif /* __CIFXDOWNLOAD__H */
|