Hi. Sorry for posting questions so often.
I'm posting a question because I'm getting an error while trying to build the example files from PFE into a make file.
This is the version of the file I'm using. Version compatibility seems to be fine.
PFE-FW_S32G_1.7.1
PFE-DRV_S32G_M7_MCAL_1.3.0
SW32G_RTD_4.4_4.0.2
Tresos 27.1.0
$ make build HW=RDB3
mkdir -p output_RDB3
CC C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/src/isa.c
CC C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/src/Eth_PFE_LLD.c
CC C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/src/fci.c
....
....
CC src/sample_app_ethswt_eth.c
src/sample_app_ethswt_eth.c: In function 'Tst_Pfe_SendDummyFrame':
src/sample_app_ethswt_eth.c:214:26: error: 'RTABLE_IPV4_SRC_IP_ADDR' undeclared (first use in this function)
214 | pSrcIpAddr = RTABLE_IPV4_SRC_IP_ADDR;
| ^~~~~~~~~~~~~~~~~~~~~~~
src/sample_app_ethswt_eth.c:214:26: note: each undeclared identifier is reported only once for each function it appears in
src/sample_app_ethswt_eth.c:215:26: error: 'RTABLE_IPV4_DES_IP_ADDR' undeclared (first use in this function); did you mean 'RTABLE_IPV4_DES_PORT'?
215 | pDstIpAddr = RTABLE_IPV4_DES_IP_ADDR;
| ^~~~~~~~~~~~~~~~~~~~~~~
| RTABLE_IPV4_DES_PORT
<command-line>: error: stray '\' in program
src/sample_app_ethswt_eth.c:223:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
223 | pSrcIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: too many decimal points in number
src/sample_app_ethswt_eth.c:223:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
223 | pSrcIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: stray '\' in program
src/sample_app_ethswt_eth.c:223:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
223 | pSrcIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: 'DIPV4_LOCAL_IP_ADDR_1' undeclared (first use in this function); did you mean 'IPV4_LOCAL_IP_ADDR_0'?
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: 'DRTABLE_IPV4_SRC_IP_ADDR' undeclared (first use in this function)
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: 'DRTABLE_IPV4_DES_IP_ADDR' undeclared (first use in this function); did you mean 'RTABLE_IPV4_DES_PORT'?
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: 'DRTABLE_IPV4_SRC_PORT' undeclared (first use in this function); did you mean 'RTABLE_IPV4_DES_PORT'?
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
src/sample_app_ethswt_eth.c:224:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
224 | pDstIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: too many decimal points in number
src/sample_app_ethswt_eth.c:224:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
224 | pDstIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: stray '\' in program
src/sample_app_ethswt_eth.c:224:30: note: in expansion of macro 'IPV4_LOCAL_IP_ADDR_0'
224 | pDstIpAddr = IPV4_LOCAL_IP_ADDR_0;
| ^~~~~~~~~~~~~~~~~~~~
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: too many decimal points in number
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
<command-line>: error: stray '\' in program
<command-line>: note: in definition of macro 'IPV4_LOCAL_IP_ADDR_0'
src/sample_app_ethswt_eth.c:228:30: error: 'IPV4_LOCAL_IP_ADDR_1' undeclared (first use in this function); did you mean 'IPV4_LOCAL_IP_ADDR_0'?
228 | pSrcIpAddr = IPV4_LOCAL_IP_ADDR_1;
| ^~~~~~~~~~~~~~~~~~~~
| IPV4_LOCAL_IP_ADDR_0
In file included from C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/include/oal_types.h:62,
from C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/include/Eth_43_PFE.h:63,
from include/EthIf_Cbk.h:28,
from include/sample_app_ethswt_data_definition.h:46,
from include/sample_app_ethswt_eth.h:32,
from src/sample_app_ethswt_eth.c:26:
src/sample_app_ethswt_eth.c:243:36: error: 'RTABLE_IPV4_SRC_PORT' undeclared (first use in this function); did you mean 'RTABLE_IPV4_DES_PORT'?
243 | u16SrcPort = oal_htons(RTABLE_IPV4_SRC_PORT);
| ^~~~~~~~~~~~~~~~~~~~
C:/NXP/SW32G_RTD_4.4_4.0.2/eclipse/plugins/Eth_43_PFE_TS_T40D11M13I0R0/include/oal_types_autosar.h:245:51: note: in definition of macro
oal_htons'
245 | #define oal_htons(a) ((uint16_t)((((uint16_t)(a) & 0xFF00U) >>
| ^
Makefile:672: recipe for target 'output_RDB3/sample_app_ethswt_eth.o' failed
make: *** [output_RDB3/sample_app_ethswt_eth.o] Error 1
To summarise, I am getting an error related to RTABLE_IPV4_SRC_IP_ADDR in this c file.
src/sample_app_ethswt_eth.c:214:26: error: 'RTABLE_IPV4_SRC_IP_ADDR' undeclared (first use in this function)
Hi,
Are you compiling the examples available under PFE?
From our side, we seem to be unable to reproduce the outcome you are seeing with the available examples:
...
Have you generated the configuration prior to compiling the example?
Please, let us know.