eRPC API Reference  Rev. 1.12.0
NXP Semiconductors
erpc_rpmsg_linux_transport.hpp
1 /*
2  * Copyright 2017 NXP
3  * All rights reserved.
4  *
5  *
6  * SPDX-License-Identifier: BSD-3-Clause
7  */
8 
9 /* Download "rpmsg_linux_endpoint.h/.cpp" from
10  * github.com/EmbeddedRPC/erpc-imx-demos/tree/master/middleware/rpmsg-cpp */
11 #include "erpc_rpmsg_linux_endpoint.hpp"
12 #include "erpc_transport.hpp"
13 
15 // Classes
17 
18 namespace erpc {
19 
27 {
28 public:
32  RPMsgLinuxTransport(RPMsgEndpoint *endPoint, int16_t remote);
33 
34  virtual ~RPMsgLinuxTransport(void);
35 
41  RPMsgEndpoint *getRpmsgEndpoint(void) { return m_endPoint; }
42 
49  erpc_status_t init(void);
50 
59  virtual erpc_status_t receive(MessageBuffer *message) override;
60 
69  virtual erpc_status_t send(MessageBuffer *message) override;
70 
71 private:
72  RPMsgEndpoint *m_endPoint;
73  int16_t m_remote;
74 };
75 } // namespace erpc
Abstract interface for transport layer.
Definition: erpc_transport.hpp:36
erpc_status_t init(void)
This function initializes Linux environment for sending and receiving messages.
Definition: erpc_rpmsg_linux_transport.cpp:27
RPMsgLinuxTransport(RPMsgEndpoint *endPoint, int16_t remote)
Constructor to set RPMsg endpoint and remote address.
Definition: erpc_rpmsg_linux_transport.cpp:20
enum _erpc_status erpc_status_t
Type used for all status and error return values.
Definition: erpc_common.h:85
virtual erpc_status_t receive(MessageBuffer *message) override
This function receives the eRPC messages.
Definition: erpc_rpmsg_linux_transport.cpp:42
virtual erpc_status_t send(MessageBuffer *message) override
This function sends the eRPC messages.
Definition: erpc_rpmsg_linux_transport.cpp:34
Represents a memory buffer containing a message.
Definition: erpc_message_buffer.hpp:37
Definition: erpc_arbitrated_client_manager.hpp:25
RPMSG Linux transport to send/receive messages through RPMSG endpoints based on github.com/nxp-mcuxpresso/rpmsg-sysfs/tree/0aa1817545a765c200b1b2f9b6680a420dcf9171 implementation.
Definition: erpc_rpmsg_linux_transport.hpp:26
RPMsgEndpoint * getRpmsgEndpoint(void)
This function returns rpmsg endpoint object.
Definition: erpc_rpmsg_linux_transport.hpp:41