po_hi_transport.h 1.52 KB
Newer Older
1
2
3
4
5
6
7
8
/*
 * This is a part of PolyORB-HI-C distribution, a minimal
 * middleware written for generated code from AADL models.
 * You should use it with the Ocarina toolsuite.
 *
 * For more informations, please visit http://ocarina.enst.fr
 *
 * Copyright (C) 2007-2008, GET-Telecom Paris.
julien.delange's avatar
julien.delange committed
9
 * Copyright (C) 2010, European Space Agency.
10
11
12
13
14
15
 */

#ifndef __PO_HI_TRANSPORT__
#define __PO_HI_TRANSPORT__

#include <po_hi_messages.h>
16
#include <drivers/po_hi_driver_sockets_common.h>
17
18
19
#include <deployment.h>
#include <request.h>

20
21
#define __PO_HI_BIGENDIAN     0
#define __PO_HI_LITTLEENDIAN  1
22

julien.delange's avatar
julien.delange committed
23
typedef uint8_t __po_hi_queue_id;
24

25
__po_hi_node_t    __po_hi_transport_get_node_from_entity (const __po_hi_entity_t entity);
26
/*
julien.delange's avatar
julien.delange committed
27
 * Returns the node identifier that corresponds to an entity.
28
29
 */

30
31
32
33
34
35
__po_hi_entity_t  __po_hi_get_entity_from_global_port (const __po_hi_port_t port);
/*
 * Return the entity identifier that own the port in parameters.
 */

int               __po_hi_transport_send_default (__po_hi_task_id id, __po_hi_port_t port);
36
/*
julien.delange's avatar
julien.delange committed
37
 * Default transport layer
38
39
 */

40
char* __po_hi_get_port_model_name (const __po_hi_port_t port);
41

42
43
44
char* __po_hi_get_port_name (const __po_hi_port_t port);

__po_hi_local_port_t __po_hi_get_local_port_from_global_port (const __po_hi_port_t global_port);
45

46
47
__po_hi_uint8_t  __po_hi_get_endianness (const __po_hi_node_t node);

48
#if __PO_HI_NB_DEVICES > 0
49
50
__po_hi_device_id __po_hi_get_device_from_port (const __po_hi_port_t port);

51
52
char* __po_hi_get_device_naming (const __po_hi_port_t port);
#endif
53

54
#endif /* __PO_HI_TRANSPORT__ */