Staging: epl: run Lindent on *.c files

It's a start, still a mess...

Cc: Daniel Krueger <daniel.krueger@systec-electronic.com>
Cc: Ronald Sieber <Ronald.Sieber@systec-electronic.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
Greg Kroah-Hartman
2008-12-19 17:11:52 -08:00
parent e0ca059588
commit 833dfbe746
41 changed files with 23128 additions and 23337 deletions
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+117 -144
View File
@@ -75,7 +75,6 @@
#include <asm/uaccess.h>
#endif
/***************************************************************************/
/* */
/* */
@@ -100,7 +99,6 @@
// local function prototypes
//---------------------------------------------------------------------------
/***************************************************************************/
/* */
/* */
@@ -114,7 +112,6 @@
//
/***************************************************************************/
//=========================================================================//
// //
// P R I V A T E D E F I N I T I O N S //
@@ -130,36 +127,33 @@
//---------------------------------------------------------------------------
#if ((EPL_API_PROCESS_IMAGE_SIZE_IN > 0) || (EPL_API_PROCESS_IMAGE_SIZE_OUT > 0))
typedef struct
{
#if EPL_API_PROCESS_IMAGE_SIZE_IN > 0
BYTE m_abProcessImageInput[EPL_API_PROCESS_IMAGE_SIZE_IN];
#endif
#if EPL_API_PROCESS_IMAGE_SIZE_OUT > 0
BYTE m_abProcessImageOutput[EPL_API_PROCESS_IMAGE_SIZE_OUT];
#endif
typedef struct {
#if EPL_API_PROCESS_IMAGE_SIZE_IN > 0
BYTE m_abProcessImageInput[EPL_API_PROCESS_IMAGE_SIZE_IN];
#endif
#if EPL_API_PROCESS_IMAGE_SIZE_OUT > 0
BYTE m_abProcessImageOutput[EPL_API_PROCESS_IMAGE_SIZE_OUT];
#endif
} tEplApiProcessImageInstance;
} tEplApiProcessImageInstance;
//---------------------------------------------------------------------------
// local vars
//---------------------------------------------------------------------------
static tEplApiProcessImageInstance EplApiProcessImageInstance_g;
static tEplApiProcessImageInstance EplApiProcessImageInstance_g;
#endif
//---------------------------------------------------------------------------
// local function prototypes
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P U B L I C F U N C T I O N S //
// //
//=========================================================================//
//---------------------------------------------------------------------------
//
// Function: EplApiProcessImageSetup()
@@ -177,125 +171,101 @@ static tEplApiProcessImageInstance EplApiProcessImageInstance_g;
tEplKernel PUBLIC EplApiProcessImageSetup(void)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
#if ((EPL_API_PROCESS_IMAGE_SIZE_IN > 0) || (EPL_API_PROCESS_IMAGE_SIZE_OUT > 0))
unsigned int uiVarEntries;
tEplObdSize ObdSize;
unsigned int uiVarEntries;
tEplObdSize ObdSize;
#endif
#if EPL_API_PROCESS_IMAGE_SIZE_IN > 0
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN;
ObdSize = 1;
Ret = EplApiLinkObject(
0x2000,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN;
ObdSize = 1;
Ret = EplApiLinkObject(0x2000,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN;
ObdSize = 1;
Ret = EplApiLinkObject(
0x2001,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN;
ObdSize = 1;
Ret = EplApiLinkObject(0x2001,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(
0x2010,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(0x2010,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(
0x2011,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(0x2011,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(
0x2020,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(0x2020,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(
0x2021,
EplApiProcessImageInstance_g.m_abProcessImageInput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_IN / ObdSize;
Ret = EplApiLinkObject(0x2021,
EplApiProcessImageInstance_g.
m_abProcessImageInput, &uiVarEntries, &ObdSize,
1);
#endif
#if EPL_API_PROCESS_IMAGE_SIZE_OUT > 0
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT;
ObdSize = 1;
Ret = EplApiLinkObject(
0x2030,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT;
ObdSize = 1;
Ret = EplApiLinkObject(0x2030,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT;
ObdSize = 1;
Ret = EplApiLinkObject(
0x2031,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT;
ObdSize = 1;
Ret = EplApiLinkObject(0x2031,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(
0x2040,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(0x2040,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(
0x2041,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 2;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(0x2041,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(
0x2050,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(0x2050,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(
0x2051,
EplApiProcessImageInstance_g.m_abProcessImageOutput,
&uiVarEntries,
&ObdSize,
1);
ObdSize = 4;
uiVarEntries = EPL_API_PROCESS_IMAGE_SIZE_OUT / ObdSize;
Ret = EplApiLinkObject(0x2051,
EplApiProcessImageInstance_g.
m_abProcessImageOutput, &uiVarEntries, &ObdSize,
1);
#endif
return Ret;
return Ret;
}
//----------------------------------------------------------------------------
@@ -310,26 +280,29 @@ tEplObdSize ObdSize;
// State:
//----------------------------------------------------------------------------
tEplKernel PUBLIC EplApiProcessImageExchangeIn(tEplApiProcessImage* pPI_p)
tEplKernel PUBLIC EplApiProcessImageExchangeIn(tEplApiProcessImage * pPI_p)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
#if EPL_API_PROCESS_IMAGE_SIZE_IN > 0
#if (TARGET_SYSTEM == _LINUX_) && defined(__KERNEL__)
copy_to_user(pPI_p->m_pImage,
EplApiProcessImageInstance_g.m_abProcessImageInput,
min(pPI_p->m_uiSize, sizeof (EplApiProcessImageInstance_g.m_abProcessImageInput)));
#else
EPL_MEMCPY(pPI_p->m_pImage,
EplApiProcessImageInstance_g.m_abProcessImageInput,
min(pPI_p->m_uiSize, sizeof (EplApiProcessImageInstance_g.m_abProcessImageInput)));
#endif
#if (TARGET_SYSTEM == _LINUX_) && defined(__KERNEL__)
copy_to_user(pPI_p->m_pImage,
EplApiProcessImageInstance_g.m_abProcessImageInput,
min(pPI_p->m_uiSize,
sizeof(EplApiProcessImageInstance_g.
m_abProcessImageInput)));
#else
EPL_MEMCPY(pPI_p->m_pImage,
EplApiProcessImageInstance_g.m_abProcessImageInput,
min(pPI_p->m_uiSize,
sizeof(EplApiProcessImageInstance_g.
m_abProcessImageInput)));
#endif
#endif
return Ret;
return Ret;
}
//----------------------------------------------------------------------------
// Function: EplApiProcessImageExchangeOut()
//
@@ -342,33 +315,33 @@ tEplKernel Ret = kEplSuccessful;
// State:
//----------------------------------------------------------------------------
tEplKernel PUBLIC EplApiProcessImageExchangeOut(tEplApiProcessImage* pPI_p)
tEplKernel PUBLIC EplApiProcessImageExchangeOut(tEplApiProcessImage * pPI_p)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
#if EPL_API_PROCESS_IMAGE_SIZE_OUT > 0
#if (TARGET_SYSTEM == _LINUX_) && defined(__KERNEL__)
copy_from_user(EplApiProcessImageInstance_g.m_abProcessImageOutput,
pPI_p->m_pImage,
min(pPI_p->m_uiSize, sizeof (EplApiProcessImageInstance_g.m_abProcessImageOutput)));
#else
EPL_MEMCPY(EplApiProcessImageInstance_g.m_abProcessImageOutput,
pPI_p->m_pImage,
min(pPI_p->m_uiSize, sizeof (EplApiProcessImageInstance_g.m_abProcessImageOutput)));
#endif
#if (TARGET_SYSTEM == _LINUX_) && defined(__KERNEL__)
copy_from_user(EplApiProcessImageInstance_g.m_abProcessImageOutput,
pPI_p->m_pImage,
min(pPI_p->m_uiSize,
sizeof(EplApiProcessImageInstance_g.
m_abProcessImageOutput)));
#else
EPL_MEMCPY(EplApiProcessImageInstance_g.m_abProcessImageOutput,
pPI_p->m_pImage,
min(pPI_p->m_uiSize,
sizeof(EplApiProcessImageInstance_g.
m_abProcessImageOutput)));
#endif
#endif
return Ret;
return Ret;
}
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
// //
//=========================================================================//
// EOF
+2827 -2556
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+132 -137
View File
@@ -78,7 +78,6 @@
#include "kernel/EplDllkCal.h"
#endif
#if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_DLLU)) != 0)
/***************************************************************************/
@@ -105,7 +104,6 @@
// local function prototypes
//---------------------------------------------------------------------------
/***************************************************************************/
/* */
/* */
@@ -119,7 +117,6 @@
//
/***************************************************************************/
//=========================================================================//
// //
// P R I V A T E D E F I N I T I O N S //
@@ -134,9 +131,8 @@
// local types
//---------------------------------------------------------------------------
typedef struct
{
tEplDlluCbAsnd m_apfnDlluCbAsnd[EPL_DLL_MAX_ASND_SERVICE_ID];
typedef struct {
tEplDlluCbAsnd m_apfnDlluCbAsnd[EPL_DLL_MAX_ASND_SERVICE_ID];
} tEplDlluCalInstance;
@@ -146,13 +142,15 @@ typedef struct
// if no dynamic memory allocation shall be used
// define structures statically
static tEplDlluCalInstance EplDlluCalInstance_g;
static tEplDlluCalInstance EplDlluCalInstance_g;
//---------------------------------------------------------------------------
// local function prototypes
//---------------------------------------------------------------------------
static tEplKernel EplDlluCalSetAsndServiceIdFilter(tEplDllAsndServiceId ServiceId_p, tEplDllAsndFilter Filter_p);
static tEplKernel EplDlluCalSetAsndServiceIdFilter(tEplDllAsndServiceId
ServiceId_p,
tEplDllAsndFilter Filter_p);
//=========================================================================//
// //
@@ -177,12 +175,12 @@ static tEplKernel EplDlluCalSetAsndServiceIdFilter(tEplDllAsndServiceId ServiceI
tEplKernel EplDlluCalAddInstance()
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
// reset instance structure
EPL_MEMSET(&EplDlluCalInstance_g, 0, sizeof (EplDlluCalInstance_g));
// reset instance structure
EPL_MEMSET(&EplDlluCalInstance_g, 0, sizeof(EplDlluCalInstance_g));
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -202,15 +200,14 @@ tEplKernel Ret = kEplSuccessful;
tEplKernel EplDlluCalDelInstance()
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
// reset instance structure
EPL_MEMSET(&EplDlluCalInstance_g, 0, sizeof (EplDlluCalInstance_g));
// reset instance structure
EPL_MEMSET(&EplDlluCalInstance_g, 0, sizeof(EplDlluCalInstance_g));
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplDlluCalProcess
@@ -228,37 +225,40 @@ tEplKernel Ret = kEplSuccessful;
tEplKernel EplDlluCalProcess(tEplEvent * pEvent_p)
{
tEplKernel Ret = kEplSuccessful;
tEplMsgType MsgType;
unsigned int uiAsndServiceId;
tEplFrameInfo FrameInfo;
tEplKernel Ret = kEplSuccessful;
tEplMsgType MsgType;
unsigned int uiAsndServiceId;
tEplFrameInfo FrameInfo;
if (pEvent_p->m_EventType == kEplEventTypeAsndRx)
{
FrameInfo.m_pFrame = (tEplFrame*) pEvent_p->m_pArg;
FrameInfo.m_uiFrameSize = pEvent_p->m_uiSize;
// extract NetTime
FrameInfo.m_NetTime = pEvent_p->m_NetTime;
if (pEvent_p->m_EventType == kEplEventTypeAsndRx) {
FrameInfo.m_pFrame = (tEplFrame *) pEvent_p->m_pArg;
FrameInfo.m_uiFrameSize = pEvent_p->m_uiSize;
// extract NetTime
FrameInfo.m_NetTime = pEvent_p->m_NetTime;
MsgType = (tEplMsgType)AmiGetByteFromLe(&FrameInfo.m_pFrame->m_le_bMessageType);
if (MsgType != kEplMsgTypeAsnd)
{
Ret = kEplInvalidOperation;
goto Exit;
}
MsgType =
(tEplMsgType) AmiGetByteFromLe(&FrameInfo.m_pFrame->
m_le_bMessageType);
if (MsgType != kEplMsgTypeAsnd) {
Ret = kEplInvalidOperation;
goto Exit;
}
uiAsndServiceId = (unsigned int) AmiGetByteFromLe(&FrameInfo.m_pFrame->m_Data.m_Asnd.m_le_bServiceId);
if (uiAsndServiceId < EPL_DLL_MAX_ASND_SERVICE_ID)
{ // ASnd service ID is valid
if (EplDlluCalInstance_g.m_apfnDlluCbAsnd[uiAsndServiceId] != NULL)
{ // handler was registered
Ret = EplDlluCalInstance_g.m_apfnDlluCbAsnd[uiAsndServiceId](&FrameInfo);
}
}
}
uiAsndServiceId =
(unsigned int)AmiGetByteFromLe(&FrameInfo.m_pFrame->m_Data.
m_Asnd.m_le_bServiceId);
if (uiAsndServiceId < EPL_DLL_MAX_ASND_SERVICE_ID) { // ASnd service ID is valid
if (EplDlluCalInstance_g.m_apfnDlluCbAsnd[uiAsndServiceId] != NULL) { // handler was registered
Ret =
EplDlluCalInstance_g.
m_apfnDlluCbAsnd[uiAsndServiceId]
(&FrameInfo);
}
}
}
Exit:
return Ret;
Exit:
return Ret;
}
//---------------------------------------------------------------------------
@@ -279,26 +279,26 @@ Exit:
//
//---------------------------------------------------------------------------
tEplKernel EplDlluCalRegAsndService(tEplDllAsndServiceId ServiceId_p, tEplDlluCbAsnd pfnDlluCbAsnd_p, tEplDllAsndFilter Filter_p)
tEplKernel EplDlluCalRegAsndService(tEplDllAsndServiceId ServiceId_p,
tEplDlluCbAsnd pfnDlluCbAsnd_p,
tEplDllAsndFilter Filter_p)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
if (ServiceId_p < tabentries (EplDlluCalInstance_g.m_apfnDlluCbAsnd))
{
// memorize function pointer
EplDlluCalInstance_g.m_apfnDlluCbAsnd[ServiceId_p] = pfnDlluCbAsnd_p;
if (ServiceId_p < tabentries(EplDlluCalInstance_g.m_apfnDlluCbAsnd)) {
// memorize function pointer
EplDlluCalInstance_g.m_apfnDlluCbAsnd[ServiceId_p] =
pfnDlluCbAsnd_p;
if (pfnDlluCbAsnd_p == NULL)
{ // close filter
Filter_p = kEplDllAsndFilterNone;
}
if (pfnDlluCbAsnd_p == NULL) { // close filter
Filter_p = kEplDllAsndFilterNone;
}
// set filter in DLL module in kernel part
Ret = EplDlluCalSetAsndServiceIdFilter(ServiceId_p, Filter_p);
// set filter in DLL module in kernel part
Ret = EplDlluCalSetAsndServiceIdFilter(ServiceId_p, Filter_p);
}
}
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -319,21 +319,21 @@ tEplKernel Ret = kEplSuccessful;
//
//---------------------------------------------------------------------------
tEplKernel EplDlluCalAsyncSend(tEplFrameInfo * pFrameInfo_p, tEplDllAsyncReqPriority Priority_p)
tEplKernel EplDlluCalAsyncSend(tEplFrameInfo * pFrameInfo_p,
tEplDllAsyncReqPriority Priority_p)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
#if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_DLLK)) != 0)
pFrameInfo_p->m_uiFrameSize += 14; // add size of ethernet header
Ret = EplDllkCalAsyncSend(pFrameInfo_p, Priority_p);
pFrameInfo_p->m_uiFrameSize += 14; // add size of ethernet header
Ret = EplDllkCalAsyncSend(pFrameInfo_p, Priority_p);
#else
Ret = kEplSuccessful;
Ret = kEplSuccessful;
#endif
return Ret;
return Ret;
}
#if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_NMT_MN)) != 0)
//---------------------------------------------------------------------------
@@ -354,43 +354,42 @@ tEplKernel Ret = kEplSuccessful;
//
//---------------------------------------------------------------------------
tEplKernel EplDlluCalIssueRequest(tEplDllReqServiceId Service_p, unsigned int uiNodeId_p, BYTE bSoaFlag1_p)
tEplKernel EplDlluCalIssueRequest(tEplDllReqServiceId Service_p,
unsigned int uiNodeId_p, BYTE bSoaFlag1_p)
{
tEplKernel Ret = kEplSuccessful;
tEplKernel Ret = kEplSuccessful;
// add node to appropriate request queue
switch (Service_p)
{
case kEplDllReqServiceIdent:
case kEplDllReqServiceStatus:
{
tEplEvent Event;
tEplDllCalIssueRequest IssueReq;
// add node to appropriate request queue
switch (Service_p) {
case kEplDllReqServiceIdent:
case kEplDllReqServiceStatus:
{
tEplEvent Event;
tEplDllCalIssueRequest IssueReq;
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkIssueReq;
IssueReq.m_Service = Service_p;
IssueReq.m_uiNodeId = uiNodeId_p;
IssueReq.m_bSoaFlag1 = bSoaFlag1_p;
Event.m_pArg = &IssueReq;
Event.m_uiSize = sizeof (IssueReq);
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkIssueReq;
IssueReq.m_Service = Service_p;
IssueReq.m_uiNodeId = uiNodeId_p;
IssueReq.m_bSoaFlag1 = bSoaFlag1_p;
Event.m_pArg = &IssueReq;
Event.m_uiSize = sizeof(IssueReq);
Ret = EplEventuPost(&Event);
break;
}
Ret = EplEventuPost(&Event);
break;
}
default:
{
Ret = kEplDllInvalidParam;
goto Exit;
}
}
default:
{
Ret = kEplDllInvalidParam;
goto Exit;
}
}
Exit:
return Ret;
Exit:
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplDlluCalAddNode()
@@ -408,20 +407,19 @@ Exit:
tEplKernel EplDlluCalAddNode(tEplDllNodeInfo * pNodeInfo_p)
{
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkAddNode;
Event.m_pArg = pNodeInfo_p;
Event.m_uiSize = sizeof (tEplDllNodeInfo);
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkAddNode;
Event.m_pArg = pNodeInfo_p;
Event.m_uiSize = sizeof(tEplDllNodeInfo);
Ret = EplEventuPost(&Event);
Ret = EplEventuPost(&Event);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplDlluCalDeleteNode()
@@ -439,20 +437,19 @@ tEplEvent Event;
tEplKernel EplDlluCalDeleteNode(unsigned int uiNodeId_p)
{
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkDelNode;
Event.m_pArg = &uiNodeId_p;
Event.m_uiSize = sizeof (uiNodeId_p);
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkDelNode;
Event.m_pArg = &uiNodeId_p;
Event.m_uiSize = sizeof(uiNodeId_p);
Ret = EplEventuPost(&Event);
Ret = EplEventuPost(&Event);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplDlluCalSoftDeleteNode()
@@ -470,23 +467,21 @@ tEplEvent Event;
tEplKernel EplDlluCalSoftDeleteNode(unsigned int uiNodeId_p)
{
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkSoftDelNode;
Event.m_pArg = &uiNodeId_p;
Event.m_uiSize = sizeof (uiNodeId_p);
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkSoftDelNode;
Event.m_pArg = &uiNodeId_p;
Event.m_uiSize = sizeof(uiNodeId_p);
Ret = EplEventuPost(&Event);
Ret = EplEventuPost(&Event);
return Ret;
return Ret;
}
#endif // (((EPL_MODULE_INTEGRATION) & (EPL_MODULE_NMT_MN)) != 0)
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
@@ -509,26 +504,26 @@ tEplEvent Event;
//
//---------------------------------------------------------------------------
static tEplKernel EplDlluCalSetAsndServiceIdFilter(tEplDllAsndServiceId ServiceId_p, tEplDllAsndFilter Filter_p)
static tEplKernel EplDlluCalSetAsndServiceIdFilter(tEplDllAsndServiceId
ServiceId_p,
tEplDllAsndFilter Filter_p)
{
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
tEplDllCalAsndServiceIdFilter ServFilter;
tEplKernel Ret = kEplSuccessful;
tEplEvent Event;
tEplDllCalAsndServiceIdFilter ServFilter;
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkServFilter;
ServFilter.m_ServiceId = ServiceId_p;
ServFilter.m_Filter = Filter_p;
Event.m_pArg = &ServFilter;
Event.m_uiSize = sizeof (ServFilter);
Event.m_EventSink = kEplEventSinkDllkCal;
Event.m_EventType = kEplEventTypeDllkServFilter;
ServFilter.m_ServiceId = ServiceId_p;
ServFilter.m_Filter = Filter_p;
Event.m_pArg = &ServFilter;
Event.m_uiSize = sizeof(ServFilter);
Ret = EplEventuPost(&Event);
Ret = EplEventuPost(&Event);
return Ret;
return Ret;
}
#endif // (((EPL_MODULE_INTEGRATION) & (EPL_MODULE_DLLU)) != 0)
// EOF
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+132 -141
View File
@@ -95,7 +95,6 @@
// local function prototypes
//---------------------------------------------------------------------------
/***************************************************************************/
/* */
/* */
@@ -109,7 +108,6 @@
//
/***************************************************************************/
//=========================================================================//
// //
// P R I V A T E D E F I N I T I O N S //
@@ -124,10 +122,9 @@
// local types
//---------------------------------------------------------------------------
typedef struct
{
tEplIdentResponse* m_apIdentResponse[254]; // the IdentResponse are managed dynamically
tEplIdentuCbResponse m_apfnCbResponse[254];
typedef struct {
tEplIdentResponse *m_apIdentResponse[254]; // the IdentResponse are managed dynamically
tEplIdentuCbResponse m_apfnCbResponse[254];
} tEplIdentuInstance;
@@ -135,7 +132,7 @@ typedef struct
// local vars
//---------------------------------------------------------------------------
static tEplIdentuInstance EplIdentuInstance_g;
static tEplIdentuInstance EplIdentuInstance_g;
//---------------------------------------------------------------------------
// local function prototypes
@@ -169,14 +166,13 @@ static tEplKernel PUBLIC EplIdentuCbIdentResponse(tEplFrameInfo * pFrameInfo_p);
EPLDLLEXPORT tEplKernel PUBLIC EplIdentuInit()
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplIdentuAddInstance();
Ret = EplIdentuAddInstance();
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuAddInstance
@@ -197,21 +193,23 @@ tEplKernel Ret;
EPLDLLEXPORT tEplKernel PUBLIC EplIdentuAddInstance()
{
tEplKernel Ret;
tEplKernel Ret;
Ret = kEplSuccessful;
Ret = kEplSuccessful;
// reset instance structure
EPL_MEMSET(&EplIdentuInstance_g, 0, sizeof (EplIdentuInstance_g));
// reset instance structure
EPL_MEMSET(&EplIdentuInstance_g, 0, sizeof(EplIdentuInstance_g));
// register IdentResponse callback function
Ret = EplDlluCalRegAsndService(kEplDllAsndIdentResponse, EplIdentuCbIdentResponse, kEplDllAsndFilterAny);
// register IdentResponse callback function
Ret =
EplDlluCalRegAsndService(kEplDllAsndIdentResponse,
EplIdentuCbIdentResponse,
kEplDllAsndFilterAny);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuDelInstance
@@ -232,20 +230,21 @@ tEplKernel Ret;
EPLDLLEXPORT tEplKernel PUBLIC EplIdentuDelInstance()
{
tEplKernel Ret;
tEplKernel Ret;
Ret = kEplSuccessful;
Ret = kEplSuccessful;
// deregister IdentResponse callback function
Ret = EplDlluCalRegAsndService(kEplDllAsndIdentResponse, NULL, kEplDllAsndFilterNone);
// deregister IdentResponse callback function
Ret =
EplDlluCalRegAsndService(kEplDllAsndIdentResponse, NULL,
kEplDllAsndFilterNone);
Ret = EplIdentuReset();
Ret = EplIdentuReset();
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuReset
@@ -266,26 +265,25 @@ tEplKernel Ret;
EPLDLLEXPORT tEplKernel PUBLIC EplIdentuReset()
{
tEplKernel Ret;
int iIndex;
tEplKernel Ret;
int iIndex;
Ret = kEplSuccessful;
Ret = kEplSuccessful;
for (iIndex = 0; iIndex < tabentries (EplIdentuInstance_g.m_apIdentResponse); iIndex++)
{
if (EplIdentuInstance_g.m_apIdentResponse[iIndex] != NULL)
{ // free memory
EPL_FREE(EplIdentuInstance_g.m_apIdentResponse[iIndex]);
}
}
for (iIndex = 0;
iIndex < tabentries(EplIdentuInstance_g.m_apIdentResponse);
iIndex++) {
if (EplIdentuInstance_g.m_apIdentResponse[iIndex] != NULL) { // free memory
EPL_FREE(EplIdentuInstance_g.m_apIdentResponse[iIndex]);
}
}
EPL_MEMSET(&EplIdentuInstance_g, 0, sizeof (EplIdentuInstance_g));
EPL_MEMSET(&EplIdentuInstance_g, 0, sizeof(EplIdentuInstance_g));
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuGetIdentResponse
@@ -302,31 +300,28 @@ int iIndex;
//
//---------------------------------------------------------------------------
tEplKernel PUBLIC EplIdentuGetIdentResponse(
unsigned int uiNodeId_p,
tEplIdentResponse** ppIdentResponse_p)
tEplKernel PUBLIC EplIdentuGetIdentResponse(unsigned int uiNodeId_p,
tEplIdentResponse **
ppIdentResponse_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = kEplSuccessful;
Ret = kEplSuccessful;
// decrement node ID, because array is zero based
uiNodeId_p--;
if (uiNodeId_p < tabentries (EplIdentuInstance_g.m_apIdentResponse))
{
*ppIdentResponse_p = EplIdentuInstance_g.m_apIdentResponse[uiNodeId_p];
}
else
{ // invalid node ID specified
*ppIdentResponse_p = NULL;
Ret = kEplInvalidNodeId;
}
// decrement node ID, because array is zero based
uiNodeId_p--;
if (uiNodeId_p < tabentries(EplIdentuInstance_g.m_apIdentResponse)) {
*ppIdentResponse_p =
EplIdentuInstance_g.m_apIdentResponse[uiNodeId_p];
} else { // invalid node ID specified
*ppIdentResponse_p = NULL;
Ret = kEplInvalidNodeId;
}
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuRequestIdentResponse
@@ -343,42 +338,38 @@ tEplKernel Ret;
//
//---------------------------------------------------------------------------
tEplKernel PUBLIC EplIdentuRequestIdentResponse(
unsigned int uiNodeId_p,
tEplIdentuCbResponse pfnCbResponse_p)
tEplKernel PUBLIC EplIdentuRequestIdentResponse(unsigned int uiNodeId_p,
tEplIdentuCbResponse
pfnCbResponse_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = kEplSuccessful;
Ret = kEplSuccessful;
// decrement node ID, because array is zero based
uiNodeId_p--;
if (uiNodeId_p < tabentries (EplIdentuInstance_g.m_apfnCbResponse))
{
// decrement node ID, because array is zero based
uiNodeId_p--;
if (uiNodeId_p < tabentries(EplIdentuInstance_g.m_apfnCbResponse)) {
#if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_NMT_MN)) != 0)
if (EplIdentuInstance_g.m_apfnCbResponse[uiNodeId_p] != NULL)
{ // request already issued (maybe by someone else)
Ret = kEplInvalidOperation;
}
else
{
EplIdentuInstance_g.m_apfnCbResponse[uiNodeId_p] = pfnCbResponse_p;
Ret = EplDlluCalIssueRequest(kEplDllReqServiceIdent, (uiNodeId_p + 1), 0xFF);
}
if (EplIdentuInstance_g.m_apfnCbResponse[uiNodeId_p] != NULL) { // request already issued (maybe by someone else)
Ret = kEplInvalidOperation;
} else {
EplIdentuInstance_g.m_apfnCbResponse[uiNodeId_p] =
pfnCbResponse_p;
Ret =
EplDlluCalIssueRequest(kEplDllReqServiceIdent,
(uiNodeId_p + 1), 0xFF);
}
#else
Ret = kEplInvalidOperation;
Ret = kEplInvalidOperation;
#endif
}
else
{ // invalid node ID specified
Ret = kEplInvalidNodeId;
}
} else { // invalid node ID specified
Ret = kEplInvalidNodeId;
}
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplIdentuGetRunningRequests
@@ -399,21 +390,18 @@ tEplKernel Ret;
EPLDLLEXPORT DWORD PUBLIC EplIdentuGetRunningRequests(void)
{
DWORD dwReqs = 0;
unsigned int uiIndex;
DWORD dwReqs = 0;
unsigned int uiIndex;
for (uiIndex = 0; uiIndex < 32; uiIndex++)
{
if (EplIdentuInstance_g.m_apfnCbResponse[uiIndex] != NULL)
{
dwReqs |= (1 << uiIndex);
}
}
for (uiIndex = 0; uiIndex < 32; uiIndex++) {
if (EplIdentuInstance_g.m_apfnCbResponse[uiIndex] != NULL) {
dwReqs |= (1 << uiIndex);
}
}
return dwReqs;
return dwReqs;
}
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
@@ -440,58 +428,61 @@ unsigned int uiIndex;
static tEplKernel PUBLIC EplIdentuCbIdentResponse(tEplFrameInfo * pFrameInfo_p)
{
tEplKernel Ret = kEplSuccessful;
unsigned int uiNodeId;
unsigned int uiIndex;
tEplIdentuCbResponse pfnCbResponse;
tEplKernel Ret = kEplSuccessful;
unsigned int uiNodeId;
unsigned int uiIndex;
tEplIdentuCbResponse pfnCbResponse;
uiNodeId = AmiGetByteFromLe(&pFrameInfo_p->m_pFrame->m_le_bSrcNodeId);
uiNodeId = AmiGetByteFromLe(&pFrameInfo_p->m_pFrame->m_le_bSrcNodeId);
uiIndex = uiNodeId - 1;
uiIndex = uiNodeId - 1;
if (uiIndex < tabentries (EplIdentuInstance_g.m_apfnCbResponse))
{
// memorize pointer to callback function
pfnCbResponse = EplIdentuInstance_g.m_apfnCbResponse[uiIndex];
// reset callback function pointer so that caller may issue next request immediately
EplIdentuInstance_g.m_apfnCbResponse[uiIndex] = NULL;
if (uiIndex < tabentries(EplIdentuInstance_g.m_apfnCbResponse)) {
// memorize pointer to callback function
pfnCbResponse = EplIdentuInstance_g.m_apfnCbResponse[uiIndex];
// reset callback function pointer so that caller may issue next request immediately
EplIdentuInstance_g.m_apfnCbResponse[uiIndex] = NULL;
if (pFrameInfo_p->m_uiFrameSize < EPL_C_DLL_MINSIZE_IDENTRES)
{ // IdentResponse not received or it has invalid size
if (pfnCbResponse == NULL)
{ // response was not requested
goto Exit;
}
Ret = pfnCbResponse(uiNodeId, NULL);
}
else
{ // IdentResponse received
if (EplIdentuInstance_g.m_apIdentResponse[uiIndex] == NULL)
{ // memory for IdentResponse must be allocated
EplIdentuInstance_g.m_apIdentResponse[uiIndex] = EPL_MALLOC(sizeof (tEplIdentResponse));
if (EplIdentuInstance_g.m_apIdentResponse[uiIndex] == NULL)
{ // malloc failed
if (pfnCbResponse == NULL)
{ // response was not requested
goto Exit;
}
Ret = pfnCbResponse(uiNodeId, &pFrameInfo_p->m_pFrame->m_Data.m_Asnd.m_Payload.m_IdentResponse);
goto Exit;
}
}
// copy IdentResponse to instance structure
EPL_MEMCPY(EplIdentuInstance_g.m_apIdentResponse[uiIndex], &pFrameInfo_p->m_pFrame->m_Data.m_Asnd.m_Payload.m_IdentResponse, sizeof(tEplIdentResponse));
if (pfnCbResponse == NULL)
{ // response was not requested
goto Exit;
}
Ret = pfnCbResponse(uiNodeId, EplIdentuInstance_g.m_apIdentResponse[uiIndex]);
}
}
if (pFrameInfo_p->m_uiFrameSize < EPL_C_DLL_MINSIZE_IDENTRES) { // IdentResponse not received or it has invalid size
if (pfnCbResponse == NULL) { // response was not requested
goto Exit;
}
Ret = pfnCbResponse(uiNodeId, NULL);
} else { // IdentResponse received
if (EplIdentuInstance_g.m_apIdentResponse[uiIndex] == NULL) { // memory for IdentResponse must be allocated
EplIdentuInstance_g.m_apIdentResponse[uiIndex] =
EPL_MALLOC(sizeof(tEplIdentResponse));
if (EplIdentuInstance_g.m_apIdentResponse[uiIndex] == NULL) { // malloc failed
if (pfnCbResponse == NULL) { // response was not requested
goto Exit;
}
Ret =
pfnCbResponse(uiNodeId,
&pFrameInfo_p->
m_pFrame->m_Data.
m_Asnd.m_Payload.
m_IdentResponse);
goto Exit;
}
}
// copy IdentResponse to instance structure
EPL_MEMCPY(EplIdentuInstance_g.
m_apIdentResponse[uiIndex],
&pFrameInfo_p->m_pFrame->m_Data.m_Asnd.
m_Payload.m_IdentResponse,
sizeof(tEplIdentResponse));
if (pfnCbResponse == NULL) { // response was not requested
goto Exit;
}
Ret =
pfnCbResponse(uiNodeId,
EplIdentuInstance_g.
m_apIdentResponse[uiIndex]);
}
}
Exit:
return Ret;
Exit:
return Ret;
}
// EOF
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+1343 -1251
View File
File diff suppressed because it is too large Load Diff
-8
View File
@@ -71,11 +71,9 @@
#include "kernel/EplNmtkCal.h"
// TODO: init function needed to prepare EplNmtkGetNmtState for
// io-controll-call from EplNmtuCal-Modul
/***************************************************************************/
/* */
/* */
@@ -100,8 +98,6 @@
// local function prototypes
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P U B L I C F U N C T I O N S //
@@ -126,7 +122,6 @@
//
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
@@ -151,7 +146,4 @@
//
//---------------------------------------------------------------------------
// EOF
File diff suppressed because it is too large Load Diff
+5 -11
View File
@@ -95,9 +95,6 @@
// local function prototypes
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P U B L I C F U N C T I O N S //
@@ -124,14 +121,14 @@
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplNmtState PUBLIC EplNmtkCalGetNmtState()
{
tEplNmtState NmtState;
// for test direkt call for EplNmtkGetNmtState()
tEplNmtState NmtState;
// for test direkt call for EplNmtkGetNmtState()
#if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_NMTK)) != 0)
NmtState = EplNmtkGetNmtState();
NmtState = EplNmtkGetNmtState();
#else
NmtState = 0;
NmtState = 0;
#endif
return NmtState;
return NmtState;
}
//=========================================================================//
@@ -158,7 +155,4 @@ return NmtState;
//
//---------------------------------------------------------------------------
// EOF
+1971 -2214
View File
File diff suppressed because it is too large Load Diff
-7
View File
@@ -96,9 +96,6 @@
// local function prototypes
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P U B L I C F U N C T I O N S //
@@ -123,7 +120,6 @@
//
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
@@ -148,7 +144,4 @@
//
//---------------------------------------------------------------------------
// EOF
+82 -77
View File
@@ -97,8 +97,6 @@
// local function prototypes
//---------------------------------------------------------------------------
//=========================================================================//
// //
// P U B L I C F U N C T I O N S //
@@ -123,19 +121,18 @@
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduWriteEntry (unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void * pSrcData_p,
tEplObdSize Size_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduWriteEntry(unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void *pSrcData_p,
tEplObdSize Size_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalWriteEntry(uiIndex_p, uiSubIndex_p, pSrcData_p, Size_p);
Ret = EplObduCalWriteEntry(uiIndex_p, uiSubIndex_p, pSrcData_p, Size_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplObduReadEntry()
@@ -156,19 +153,18 @@ tEplKernel Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduReadEntry (unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void * pDstData_p,
tEplObdSize* pSize_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduReadEntry(unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void *pDstData_p,
tEplObdSize * pSize_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalReadEntry(uiIndex_p, uiSubIndex_p, pDstData_p, pSize_p);
Ret = EplObduCalReadEntry(uiIndex_p, uiSubIndex_p, pDstData_p, pSize_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
//
// Function: EplObdAccessOdPart()
@@ -183,14 +179,14 @@ tEplKernel Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduAccessOdPart (tEplObdPart ObdPart_p,
tEplObdDir Direction_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduAccessOdPart(tEplObdPart ObdPart_p,
tEplObdDir Direction_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalAccessOdPart(ObdPart_p, Direction_p);
Ret = EplObduCalAccessOdPart(ObdPart_p, Direction_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -206,13 +202,13 @@ tEplKernel Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduDefineVar (tEplVarParam MEM* pVarParam_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduDefineVar(tEplVarParam MEM * pVarParam_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalDefineVar(pVarParam_p);
Ret = EplObduCalDefineVar(pVarParam_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -230,14 +226,14 @@ tEplKernel Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT void* PUBLIC EplObduGetObjectDataPtr (unsigned int uiIndex_p,
unsigned int uiSubIndex_p)
EPLDLLEXPORT void *PUBLIC EplObduGetObjectDataPtr(unsigned int uiIndex_p,
unsigned int uiSubIndex_p)
{
void* pData;
void *pData;
pData = EplObduCalGetObjectDataPtr(uiIndex_p, uiSubIndex_p);
pData = EplObduCalGetObjectDataPtr(uiIndex_p, uiSubIndex_p);
return pData;
return pData;
}
//---------------------------------------------------------------------------
@@ -254,13 +250,13 @@ void* pData;
//
//---------------------------------------------------------------------------
#if (defined (EPL_OBD_USER_OD) && (EPL_OBD_USER_OD != FALSE))
EPLDLLEXPORT tEplKernel PUBLIC EplObduRegisterUserOd (tEplObdEntryPtr pUserOd_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduRegisterUserOd(tEplObdEntryPtr pUserOd_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalRegisterUserOd(pUserOd_p);
Ret = EplObduCalRegisterUserOd(pUserOd_p);
return Ret;
return Ret;
}
#endif
@@ -279,10 +275,11 @@ tEplKernel Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT void PUBLIC EplObduInitVarEntry (tEplObdVarEntry MEM* pVarEntry_p,
BYTE bType_p, tEplObdSize ObdSize_p)
EPLDLLEXPORT void PUBLIC EplObduInitVarEntry(tEplObdVarEntry MEM * pVarEntry_p,
BYTE bType_p,
tEplObdSize ObdSize_p)
{
EplObduCalInitVarEntry(pVarEntry_p, bType_p, ObdSize_p);
EplObduCalInitVarEntry(pVarEntry_p, bType_p, ObdSize_p);
}
//---------------------------------------------------------------------------
@@ -303,13 +300,13 @@ EPLDLLEXPORT void PUBLIC EplObduInitVarEntry (tEplObdVarEntry MEM* pVarEntry_p,
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplObdSize PUBLIC EplObduGetDataSize(unsigned int uiIndex_p,
unsigned int uiSubIndex_p)
unsigned int uiSubIndex_p)
{
tEplObdSize Size;
tEplObdSize Size;
Size = EplObduCalGetDataSize(uiIndex_p, uiSubIndex_p);
Size = EplObduCalGetDataSize(uiIndex_p, uiSubIndex_p);
return Size;
return Size;
}
//---------------------------------------------------------------------------
@@ -328,11 +325,11 @@ tEplObdSize Size;
//---------------------------------------------------------------------------
EPLDLLEXPORT unsigned int PUBLIC EplObduGetNodeId()
{
unsigned int uiNodeId;
unsigned int uiNodeId;
uiNodeId = EplObduCalGetNodeId();
uiNodeId = EplObduCalGetNodeId();
return uiNodeId;
return uiNodeId;
}
//---------------------------------------------------------------------------
@@ -351,13 +348,13 @@ unsigned int uiNodeId;
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduSetNodeId(unsigned int uiNodeId_p,
tEplObdNodeIdType NodeIdType_p)
tEplObdNodeIdType NodeIdType_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalSetNodeId(uiNodeId_p, NodeIdType_p);
Ret = EplObduCalSetNodeId(uiNodeId_p, NodeIdType_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -377,14 +374,16 @@ tEplKernel Ret;
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduGetAccessType(unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
tEplObdAccess* pAccessTyp_p)
unsigned int uiSubIndex_p,
tEplObdAccess *
pAccessTyp_p)
{
tEplObdAccess AccessType;
tEplObdAccess AccessType;
AccessType = EplObduCalGetAccessType(uiIndex_p, uiSubIndex_p, pAccessTyp_p);
AccessType =
EplObduCalGetAccessType(uiIndex_p, uiSubIndex_p, pAccessTyp_p);
return AccessType;
return AccessType;
}
//---------------------------------------------------------------------------
@@ -411,16 +410,18 @@ tEplObdAccess AccessType;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduReadEntryToLe (unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void * pDstData_p,
tEplObdSize * pSize_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduReadEntryToLe(unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void *pDstData_p,
tEplObdSize * pSize_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalReadEntryToLe(uiIndex_p, uiSubIndex_p, pDstData_p, pSize_p);
Ret =
EplObduCalReadEntryToLe(uiIndex_p, uiSubIndex_p, pDstData_p,
pSize_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -444,16 +445,19 @@ return Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduWriteEntryFromLe (unsigned int uiIndex_p,
unsigned int uiSubIndex_p,
void * pSrcData_p,
tEplObdSize Size_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduWriteEntryFromLe(unsigned int uiIndex_p,
unsigned int
uiSubIndex_p,
void *pSrcData_p,
tEplObdSize Size_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalWriteEntryFromLe(uiIndex_p, uiSubIndex_p, pSrcData_p, Size_p);
Ret =
EplObduCalWriteEntryFromLe(uiIndex_p, uiSubIndex_p, pSrcData_p,
Size_p);
return Ret;
return Ret;
}
//---------------------------------------------------------------------------
@@ -471,17 +475,19 @@ return Ret;
// State:
//
//---------------------------------------------------------------------------
EPLDLLEXPORT tEplKernel PUBLIC EplObduSearchVarEntry (EPL_MCO_DECL_INSTANCE_PTR_
unsigned int uiIndex_p,
unsigned int uiSubindex_p,
tEplObdVarEntry MEM** ppVarEntry_p)
EPLDLLEXPORT tEplKernel PUBLIC EplObduSearchVarEntry(EPL_MCO_DECL_INSTANCE_PTR_
unsigned int uiIndex_p,
unsigned int uiSubindex_p,
tEplObdVarEntry MEM **
ppVarEntry_p)
{
tEplKernel Ret;
tEplKernel Ret;
Ret = EplObduCalSearchVarEntry(uiIndex_p, uiSubindex_p, ppVarEntry_p);
Ret = EplObduCalSearchVarEntry(uiIndex_p, uiSubindex_p, ppVarEntry_p);
return Ret;
return Ret;
}
//=========================================================================//
// //
// P R I V A T E F U N C T I O N S //
@@ -509,4 +515,3 @@ return Ret;
#endif // #if(((EPL_MODULE_INTEGRATION) & (EPL_MODULE_OBDU)) != 0)
// EOF

Some files were not shown because too many files have changed in this diff Show More