void OSEKTL_DataInd(long rxCount) { int i; // Print message to write window writeDbgLevel(2,"%NODE_NAME%: data indicativoid oncalled,RxCount=%d(Network'%NETWORK_NAME%',Channel%CHANNEL%)",rxCount);() // Get received data OSEKTL_GetRxData( gRxDataBuffer, elcount(gRxDataBuffer) ); SysSetVariableData(sysvar::ComfortBus::TPConsoleMessage, gRxDataBuffer, rxCount); }
static void ctl_draw( LWControl *ectl, void *edata, DrMode mode ) { int x, y, w, h, dx, dy, npts, npols; char buf[ 24 ]; elcount( &npts, &npols ); x = CON_HOTX( ectl ); y = CON_HOTY( ectl ); w = CON_HOTW( ectl ); h = CON_HOTH( ectl ); panf->drawFuncs->drawBox( panel, LWP_INFO_BG, x, y, w, h ); dy = ( h - 2 * dmet->textHeight ) / 3; dx = w / 2 - panf->drawFuncs->textWidth( panel, "Points:" ); sprintf( buf, "Points: %d", npts ); panf->drawFuncs->drawText( panel, buf, LWP_INFO_IMG, x + dx, y + dy ); dy += dy + dmet->textHeight; dx = w / 2 - panf->drawFuncs->textWidth( panel, "Polygons:" ); sprintf( buf, "Polygons: %d", npols ); panf->drawFuncs->drawText( panel, buf, LWP_INFO_IMG, x + dx, y + dy ); }