1 /* -------------------------------- Arctic Core ------------------------------
\r
2 * Arctic Core - the open source AUTOSAR platform http://arccore.com
\r
4 * Copyright (C) 2009 ArcCore AB <contact@arccore.com>
\r
6 * This source code is free software; you can redistribute it and/or modify it
\r
7 * under the terms of the GNU General Public License version 2 as published by the
\r
8 * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.
\r
10 * This program is distributed in the hope that it will be useful, but
\r
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
\r
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
\r
14 * -------------------------------- Arctic Core ------------------------------*/
\r
26 #include "Std_Types.h"
\r
27 #include "ComStack_Types.h"
\r
30 #define COM_SW_MAJOR_VERSION 1
\r
31 #define COM_SW_MINOR_VERSION 2
\r
32 #define COM_SW_PATCH_VERSION 0
\r
34 #include "Com_Cfg.h"
\r
35 #include "Com_Types.h"
\r
36 #include "Com_PbCfg.h"
\r
37 //#include "Com_Internal.h" //TODO: Remove completely?
\r
38 #include "Com_Com.h"
\r
39 #include "Com_Sched.h"
\r
41 //-------------------------------------------------------------------
\r
42 // From OSEK_VDX spec...
\r
44 //typedef uint32 MessageIdentifier;
\r
45 // TODO: Have no idea here..
\r
46 //typedef void * ApplicationDataRef;
\r
53 //-------------------------------------------------------------------
\r
57 /* The service SendMessage updates the message object identified by
\r
58 * <Message> with the application message referenced by the
\r
59 * <DataRef> parameter.
\r
61 * Internal communication:
\r
62 * The message <Message> is routed to the receiving part of the IL.
\r
64 // Update 2008-10-30, SendMessage and ReceiveMessage should not be required. ensured by RTE. COM013
\r
65 //StatusType SendMessage(MessageIdentifier , ApplicationDataRef );
\r
67 // The service ReceiveMessage updates the application message
\r
68 // referenced by <DataRef> with the data in the message object
\r
69 // identified by <Message>. It resets all flags (Notification classes 1 and
\r
70 // 3) associated with <Message>.
\r
71 //StatusType ReceiveMessage ( MessageIdentifier , ApplicationDataRef );
\r
75 void Com_Init(const Com_ConfigType * config);
\r
76 void Com_DeInit(void);
\r
78 void Com_IpduGroupStart(Com_PduGroupIdType IpduGroupId, boolean Initialize);
\r
79 void Com_IpduGroupStop(Com_PduGroupIdType IpduGroupId);
\r
82 BufReq_ReturnType Com_CopyTxData(PduIdType PduId, PduInfoType* PduInfoPtr, RetryInfoType* RetryInfoPtr, PduLengthType* TxDataCntPtr);
\r
83 BufReq_ReturnType Com_CopyRxData(PduIdType PduId, const PduInfoType* PduInfoPtr, PduLengthType* RxBufferSizePtr);
\r
84 BufReq_ReturnType Com_StartOfReception(PduIdType ComRxPduId, PduLengthType TpSduLength, PduLengthType* RxBufferSizePtr);
\r
85 void Com_TpRxIndication(PduIdType PduId, NotifResultType Result);
\r
86 void Com_TpTxConfirmation(PduIdType PduId, NotifResultType Result);
\r
89 extern ComSignalEndianess_type Com_SystemEndianness;
\r
91 #define COM_BUSY 0x81
\r
92 #define COM_SERVICE_NOT_AVAILABLE 0x80
\r