Skip to content

Commit

Permalink
Apply 2.15.0 release update
Browse files Browse the repository at this point in the history
  • Loading branch information
McuxCIBot authored and MichalPrincNXP committed Jan 15, 2024
1 parent 7e1a55b commit cfa48f2
Show file tree
Hide file tree
Showing 94 changed files with 46,647 additions and 274 deletions.
21 changes: 20 additions & 1 deletion ChangeLogKSDK.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,26 @@
@page middleware_log Middleware Change Log

@section multicore Multicore SDK
The current version of Multicore SDK is 2.14.0
The current version of Multicore SDK is 2.15.0
- 2.15.0
- Multicore SDK component versions:
- embedded Remote Procedure Call (eRPC) v1.12.0
- eRPC generator (erpcgen) v.1.12.0
- Multicore Manager (MCMgr) v4.1.5
- RPMsg-Lite v5.1.1
- New features:
- eRPC: Add dynamic/static option for transport init, GitHub PR #361.
- eRPC: Fix receive error value for spidev, GitHub PR #363.
- eRPC: UartTransport::init adaptation to changed driver.
- eRPC: Fix typo in assert, GitHub PR #371.
- eRPC,erpcgen: Move enums to enum classes, GitHub PR #379.
- eRPC: Fixed rpmsg tty transport to work with serial transport, GitHub PR #373.
- eRPC,erpcgen: Winsock2 support, GitHub PR #365.
- eRPC,erpcgen: Feature/support multiple clients, GitHub PR #271.
- eRPC,erpcgen: Feature/buffer head - Framed transport header data stored in MessageBuffer, GitHub PR #378.
- eRPC,erpcgen: Add experimental Java support.
- MCMgr: Added notification into MCMGR_EarlyInit and mcmgr_early_init_internal functions to avoid using uninitialized data in their implementations.
- RPMsg-Lite: Minor changes in platform and env. layers, minor test code updates.
- 2.14.0
- Multicore SDK component versions:
- embedded Remote Procedure Call (eRPC) v1.11.0
Expand Down
Binary file modified docs/Getting Started with Multicore SDK (MCSDK).pdf
Binary file not shown.
Binary file modified docs/Multicore SDK (MCSDK) Release Notes.pdf
Binary file not shown.
106 changes: 106 additions & 0 deletions example/multicore_examples/erpc_common/erpc_error_handler.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
/*
* Copyright (c) 2016, Freescale Semiconductor, Inc.
* Copyright 2016-2020 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/

#include "erpc_error_handler.h"
#include "fsl_debug_console.h"

////////////////////////////////////////////////////////////////////////////////
// Variables
////////////////////////////////////////////////////////////////////////////////

bool g_erpc_error_occurred = false;

////////////////////////////////////////////////////////////////////////////////
// Code
////////////////////////////////////////////////////////////////////////////////

void erpc_error_handler(erpc_status_t err, uint32_t functionID)
{
if (err == (erpc_status_t)kErpcStatus_Success)
{
return;
}

switch (err)
{
case (erpc_status_t)kErpcStatus_Fail:
(void)PRINTF("\r\nGeneric failure.");
break;

case (erpc_status_t)kErpcStatus_InvalidArgument:
(void)PRINTF("\r\nArgument is an invalid value.");
break;

case (erpc_status_t)kErpcStatus_Timeout:
(void)PRINTF("\r\nOperated timed out.");
break;

case (erpc_status_t)kErpcStatus_InvalidMessageVersion:
(void)PRINTF("\r\nMessage header contains an unknown version.");
break;

case (erpc_status_t)kErpcStatus_ExpectedReply:
(void)PRINTF("\r\nExpected a reply message but got another message type.");
break;

case (erpc_status_t)kErpcStatus_CrcCheckFailed:
(void)PRINTF("\r\nMessage is corrupted.");
break;

case (erpc_status_t)kErpcStatus_BufferOverrun:
(void)PRINTF("\r\nAttempt to read or write past the end of a buffer.");
break;

case (erpc_status_t)kErpcStatus_UnknownName:
(void)PRINTF("\r\nCould not find host with given name.");
break;

case (erpc_status_t)kErpcStatus_ConnectionFailure:
(void)PRINTF("\r\nFailed to connect to host.");
break;

case (erpc_status_t)kErpcStatus_ConnectionClosed:
(void)PRINTF("\r\nConnected closed by peer.");
break;

case (erpc_status_t)kErpcStatus_MemoryError:
(void)PRINTF("\r\nMemory allocation error.");
break;

case (erpc_status_t)kErpcStatus_ServerIsDown:
(void)PRINTF("\r\nServer is stopped.");
break;

case (erpc_status_t)kErpcStatus_InitFailed:
(void)PRINTF("\r\nTransport layer initialization failed.");
break;

case (erpc_status_t)kErpcStatus_ReceiveFailed:
(void)PRINTF("\r\nFailed to receive data.");
break;

case (erpc_status_t)kErpcStatus_SendFailed:
(void)PRINTF("\r\nFailed to send data.");
break;

/* unhandled error */
default:
(void)PRINTF("\r\nUnhandled error occurred.");
break;
}

/* When error occurred on client side. */
if (functionID != 0U)
{
(void)PRINTF("Function id '%u'.", (unsigned int)functionID);
}
(void)PRINTF("\r\n");

/* error occurred */
g_erpc_error_occurred = true;
}
47 changes: 47 additions & 0 deletions example/multicore_examples/erpc_common/erpc_error_handler.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/*
* Copyright (c) 2016, Freescale Semiconductor, Inc.
* Copyright 2016-2022 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/

#ifndef _EMBEDDED_RPC__ERROR_HANDLER_H_
#define _EMBEDDED_RPC__ERROR_HANDLER_H_

#include "erpc_common.h"
#include <stdint.h>

/*!
* @addtogroup error_handler
* @{
* @file
*/

////////////////////////////////////////////////////////////////////////////////
// API
////////////////////////////////////////////////////////////////////////////////

#ifdef __cplusplus
extern "C" {
#endif

//! @name Error handler
//@{

/*!
* @brief This function handles eRPC errors.
*
* This function prints a description of occurred error and sets bool variable g_erpc_error_occurred which is used for
* determining if error occurred in user application on client side.
*/
void erpc_error_handler(erpc_status_t err, uint32_t functionID);

//@}

#ifdef __cplusplus
}
#endif

/*! @} */
#endif // _EMBEDDED_RPC__ERROR_HANDLER_H_
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
/*
* Copyright (c) 2014-2016, Freescale Semiconductor, Inc.
* Copyright 2016 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/

/*
* Generated by erpcgen 1.12.0 on Wed Oct 25 10:00:57 2023.
*
* AUTOGENERATED - DO NOT EDIT
*/


#include "c_erpc_matrix_multiply_client.h"
#include "erpc_matrix_multiply_client.hpp"
#include "erpc_manually_constructed.hpp"

using namespace erpc;
using namespace std;
using namespace erpcShim;


#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
MatrixMultiplyService_client *s_MatrixMultiplyService_client = nullptr;
#else
ERPC_MANUALLY_CONSTRUCTED_STATIC(MatrixMultiplyService_client, s_MatrixMultiplyService_client);
#endif

void erpcMatrixMultiply(Matrix matrix1, Matrix matrix2, Matrix result_matrix)
{
s_MatrixMultiplyService_client->erpcMatrixMultiply(matrix1, matrix2, result_matrix);
}

void initMatrixMultiplyService_client(erpc_client_t client)
{
#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
erpc_assert(s_MatrixMultiplyService_client == nullptr);
s_MatrixMultiplyService_client = new MatrixMultiplyService_client(reinterpret_cast<ClientManager *>(client));
#else
erpc_assert(!s_MatrixMultiplyService_client.isUsed());
s_MatrixMultiplyService_client.construct(reinterpret_cast<ClientManager *>(client));
#endif
}

void deinitMatrixMultiplyService_client(void)
{
#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
if (s_MatrixMultiplyService_client != nullptr)
{
delete s_MatrixMultiplyService_client;
s_MatrixMultiplyService_client = nullptr;
}
#else
s_MatrixMultiplyService_client.destroy();
#endif
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* Copyright (c) 2014-2016, Freescale Semiconductor, Inc.
* Copyright 2016 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/

/*
* Generated by erpcgen 1.12.0 on Wed Oct 25 10:00:57 2023.
*
* AUTOGENERATED - DO NOT EDIT
*/


#if !defined(_c_erpc_matrix_multiply_client_h_)
#define _c_erpc_matrix_multiply_client_h_

#include "erpc_matrix_multiply_common.h"
#include "erpc_client_manager.h"

#if defined(__cplusplus)
extern "C"
{
#endif

#if !defined(ERPC_FUNCTIONS_DEFINITIONS)
#define ERPC_FUNCTIONS_DEFINITIONS


/*! @brief MatrixMultiplyService identifiers */
enum _MatrixMultiplyService_ids
{
kMatrixMultiplyService_service_id = 1,
kMatrixMultiplyService_erpcMatrixMultiply_id = 1,
};

//! @name MatrixMultiplyService
//@{
void erpcMatrixMultiply(Matrix matrix1, Matrix matrix2, Matrix result_matrix);
//@}

#endif // ERPC_FUNCTIONS_DEFINITIONS

void initMatrixMultiplyService_client(erpc_client_t client);

void deinitMatrixMultiplyService_client(void);

#if defined(__cplusplus)
}
#endif

#endif // _c_erpc_matrix_multiply_client_h_
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
/*
* Copyright (c) 2014-2016, Freescale Semiconductor, Inc.
* Copyright 2016 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/

/*
* Generated by erpcgen 1.12.0 on Wed Oct 25 10:00:57 2023.
*
* AUTOGENERATED - DO NOT EDIT
*/


#include <new>
#include "c_erpc_matrix_multiply_server.h"
#include "erpc_matrix_multiply_server.hpp"
#include "erpc_manually_constructed.hpp"

using namespace erpc;
using namespace std;
using namespace erpcShim;


class MatrixMultiplyService_server: public MatrixMultiplyService_interface
{
public:
virtual ~MatrixMultiplyService_server() {};


void erpcMatrixMultiply(Matrix matrix1, Matrix matrix2, Matrix result_matrix)
{
::erpcMatrixMultiply(matrix1, matrix2, result_matrix);
}
};

ERPC_MANUALLY_CONSTRUCTED_STATIC(MatrixMultiplyService_service, s_MatrixMultiplyService_service);
ERPC_MANUALLY_CONSTRUCTED_STATIC(MatrixMultiplyService_server, s_MatrixMultiplyService_server);

erpc_service_t create_MatrixMultiplyService_service(void)
{
erpc_service_t service;

#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
service = new (nothrow) MatrixMultiplyService_service(new (nothrow)MatrixMultiplyService_server());
#else
if (s_MatrixMultiplyService_service.isUsed())
{
service = NULL;
}
else
{
s_MatrixMultiplyService_server.construct();
s_MatrixMultiplyService_service.construct(s_MatrixMultiplyService_server.get());
service = s_MatrixMultiplyService_service.get();
}
#endif

return service;
}

void destroy_MatrixMultiplyService_service(erpc_service_t service)
{
#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
if (service)
{
delete (MatrixMultiplyService_server *)(((MatrixMultiplyService_service *)service)->getHandler());
delete (MatrixMultiplyService_service *)service;
}
#else
(void)service;
erpc_assert(service == s_MatrixMultiplyService_service.get());
s_MatrixMultiplyService_service.destroy();
s_MatrixMultiplyService_server.destroy();
#endif
}

Loading

0 comments on commit cfa48f2

Please sign in to comment.