Industrial Networking Protocols Knowledge Base

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Industrial Networking Protocols Knowledge Base

ディスカッション

ソート順:
Note: From ART v2.44 ETS(Embedded Test System) is not necessary for conformance testing of Profinet IO-devices. This document shows you how to perform testing with ETS. Preparation of testing   Requirements   ART tool and details about ETS HW is part of Profinet Test Bundle. It can be downloaded at https://www.profibus.com/download/profinet-test-bundle 24 V power supply for ETS HW IDK board SD card as boot medium for ETS: at least 8 GB ANEL power outlet Two Ethernet interfaces: one for connecting to ETS, the other for connecting to power outlet Ethernet cable(s) to connect between DUT ETS: by default 10 m, at least 2 m Windows Machine Suggestion   Micro-USB cable for ETS output   Please note that the ART v2.44 does not officially support Windows 11. Windows 11 will be supported from ART 2.45. It is suggested that for ART v2.44 and v2.45 you take a Machine on which Windows 10 professional 64 bit 22H2 is installed. If on the machine 'WinPCap' is installed, please uninstall it. There is corresponding firmware for each ART version. The firmware can be found in the following path: C:\Program Files (x86)\Automated RT-Tester\EtsFirmware\ets.2.xx.y.z.img.xz The firmware has to be written on a SD card by using 'balenaEtcher' or a similar tool. The following diagram shows how to connect between DUT and test system.   Figure 1. Connection of DUT and test system The IP address of the ethernet interface which is connected to ETS shall be set to 192.168.5.2 and the netmask 255.255.255.0. To open a terminal emulator, the baud rate has to be set to 115200, data bits to 8, stop bits to 1 and parity to none. If DUT has 3 ports or more, the last port of DUT has to be connected to the Ethernet interface 3 of ETS. Creating a ETS Device Project   Turn on DUT and ETS and wait until booting is complete.   Figure2. Terminal Emulator: when booting of ETS is complete Open the ART tool and create a ETS Device project.   Figure 3. select menu item to create a ETS device project   Project Settings: Set name and path of the ETS device project. Figure 4. Project Settings Power Outlet Settings: Select the ethernet interface to the power outlet and set up the both IP addresses   Figure 5. Power Outlet Settings Set up the DUT’s MAC address. It is suggested that you give here an arbitrary valid MAC address instead of pressing the button ‘Get Mac Address' to find the DUT’s MAC address.   Figure 6. Device Under Test Settings Select the GSDML file for DUT and insert modules into DUT.   Figure 7. setting up Slots and Modules Select the menu ‘Tools > Options' and press the button 'Get all Mac Address’ to find the MAC addresses of the device and all ports. If not all MAC addresses were detected, press the button again. When the MAC addresses were still not recognizable or the MAC addresses could not be detected, restart the ART-tool and try detecting the MAC addresses again.     Figure 8. Detection of MAC addresses for 2-port-device Execution of test   When an ETS device project was created and set up, please check the indicator 'ETS Board'. If the indicator looks like a green check, the conformance test is ready. Please choose necessary testcases and push the start button. Caution: According to ETS HW manual, after 4 hours of operation, the interface clock can jump. Therefore ETS should be restarted before 4 hours have passed. On the manual, it is strongly recommended to restart ETS before each use.
記事全体を表示
Note-1 : Using this callback routine can have a massive influence to the real time behavior of the stack! Note-2 : This feature is unavailable for multicore projects until GOAL v2.23.0. The example below shows the use of the callback function: Create the following local prototype and variables Add the callback function to the callback handler /****************************************************************************/ /* Local Prototypes */ /****************************************************************************/ static GOAL_STATUS_T appl_pnioCb( GOAL_PNIO_T *pHdlPnio, /**< PROFINET instance */ GOAL_PNIO_CB_ID_T id, /**< callback id */ GOAL_PNIO_CB_DATA_T *pCb /**< callback parameters */ ); /****************************************************************************/ /* Local Variables */ /****************************************************************************/ static GOAL_BOOL_T flgAppReady = GOAL_FALSE; /**< app ready flag */ static GOAL_PNIO_AR_ID_T idAr = 0; /**< AR ID */ static GOAL_PNIO_T *pPnio; /**< PROFINET instance */ static char targetData[APPL_MOD_SIZE]; /**< dummy where data is copied to */ /****************************************************************************/ /** Profinet Callback Handler * * This function collects all callbacks from the stack and decides if the * callback must be handled. */ static GOAL_STATUS_T appl_pnioCb( GOAL_PNIO_T *pHdlPnio, /**< PROFINET instance */ GOAL_PNIO_CB_ID_T id, /**< callback id */ GOAL_PNIO_CB_DATA_T *pCb /**< callback parameters */ ) { GOAL_STATUS_T res = GOAL_OK; /* return value */ UNUSEDARG(pHdlPnio); /* handle callback IDs */ switch (id) { case GOAL_PNIO_CB_ID_APPL_READY: /* application ready was confirmed, start data handling if not * already running */ if (GOAL_TRUE != flgAppReady) { flgAppReady = GOAL_TRUE; idAr = pCb->data[0].idAr; } break; case GOAL_PNIO_CB_ID_RELEASE_AR: /* AR was released, stop data handling if it was the first AR */ if (idAr == pCb->data[0].idAr) { flgAppReady = GOAL_FALSE; idAr = 0; } break; case GOAL_PNIO_CB_ID_BLINK: goal_targetSetLeds((pCb->data[1].stateDcpLight) ? UINT32_MAX : 0); break; case GOAL_PNIO_CB_ID_NEW_IO_DATA: /* New I/O data received. * Be careful: this call will block the PNIO stack * so just do the copying here and nothing else. * If not fast enough, just set a flag and retrieve the data * later in appl_loop if required. **/ memcpy(targetData, pCb->data[2].pCu8, pCb->data[1].u16); break; default: break; } return res; }   To use the cb function GOAL_PNIO_CB_ID_NEW_IO_DATA , the following functions have to be called exactly in the order described below before and after function goal_pnioNew(...) : goal_pnioCfgNewIoDataCbSet(GOAL_TRUE); → configure stack to feature the GOAL_PNIO_CB_ID_NEW_IO_DATA callback goal_pnioCyclicCtrl(pPnio,GOAL_TRUE); → enable GOAL_PNIO_CB_ID_NEW_IO_DATA callback for each arrived cyclic frame /****************************************************************************/ /** Application Setup * * Setup the application. */ GOAL_STATUS_T appl_setup( void ) { GOAL_STATUS_T res; /* result */ /* configure stack to feature the GOAL_PNIO_CB_ID_NEW_IO_DATA callback */ goal_pnioCfgNewIoDataCbSet(GOAL_TRUE); /* create new PROFINET instance */ res = goal_pnioNew(&pPnio, APPL_PNIO_ID, appl_pnioCb); if (GOAL_RES_ERR(res)) { goal_logErr("failed to create a new PROFINET instance"); return res; } /* enable GOAL_PNIO_CB_ID_NEW_IO_DATA callback for each arrived cyclic frame */ goal_pnioCyclicCtrl(pPnio,GOAL_TRUE); goal_logInfo("Initializing device structure"); /* from here create the device configuration */ ... /* PROFINET configuration succesful */ goal_logInfo("PROFINET ready"); return GOAL_OK; }
記事全体を表示
The memory footprint depends on aspects such as the size of the application, the used submodule(s), number of slots. An example of the memory footprint is described below: ARM Cortex-M3 Platform with GOAL 2.12   Memory Footprint (01_simple_io) 220 058 bytes of readonly code memory 69 079 bytes of readonly data memory 375 422 bytes of readwrite data memory (contains GOAL HEAP, thus not used 100%) Memory Footprint (13_pnio_snmp) 275 816 bytes of readonly code memory 78 228 bytes of readonly data memory 420 413 bytes of readwrite data memory (contains GOAL HEAP, thus not used 100%) GOAL heap (01_simple_io / 13_pnio_snmp) heap usage id(GOAL_ID_TASK): 252 Bytes heap usage id(GOAL_ID_TGT): 17004 Bytes heap usage id(GOAL_ID_INSTANCE): 148 Bytes heap usage id(GOAL_ID_MA_NVS): 88 Bytes heap usage id(GOAL_ID_MI_NVS): 16867 Bytes heap usage id(GOAL_ID_MAIN): 124 Bytes heap usage id(GOAL_ID_DRV_NVS): 12 Bytes heap usage id(GOAL_ID_MA_SECTION): 64 Bytes heap usage id(GOAL_ID_DRV_SPI): 12 Bytes heap usage id(GOAL_ID_MA_SPI): 100 Bytes heap usage id(GOAL_ID_DRV_WD): 4 Bytes heap usage id(GOAL_ID_LOCK): 624 Bytes heap usage id(GOAL_ID_LOG): 5164 Bytes heap usage id(GOAL_ID_CM): 8284 Bytes heap usage id(GOAL_ID_QUEUE): 49960 Bytes heap usage id(GOAL_ID_LM): 60 Bytes heap usage id(GOAL_ID_STAT): 2388 Bytes heap usage id(GOAL_ID_ETH): 120 Bytes heap usage id(GOAL_ID_NET): 16 Bytes heap usage id(GOAL_ID_TMR): 1280 Bytes heap usage id(GOAL_ID_PNIO): 49368 Bytes heap usage id(GOAL_ID_DD): 4 Bytes memory allocation number: 568 memory allocation alignment overhead: 12 memory usage: 156964/259072 bytes memory usage: (61%)  
記事全体を表示