API-FDX Linux Getting Started Manual
29
GmbH
Section 8 – Programming the API-FDX Module
//---IP Header
Dt[14]=0x45;Dt[15]=0x00;Dt[16]=0x00;Dt[17]=0x2d;Dt[18]=0x00;Dt[19]=0x00
;Dt[20]=0x40;Dt[21]=0x00;Dt[22]=0x01;Dt[23]=0x11;Dt[24]=0x6d;Dt[25]=0x5
e;
//---IP Source Address 10.129.33.1
Dt[26]=0x0a;Dt[27]=0x81;Dt[28]=0x21;Dt[29]=0x01;
//---IP Destination Address 224.224.0.60 (VL 60)
Dt[30]=0xe0;Dt[31]=0xe0;Dt[32]=0x00;Dt[33]=0x3c;
//---UDP Source Port = 24
Dt[34]=0x00;Dt[35]=0x18;
//---UDP Dest Port = 23
Dt[36]=0x00;Dt[37]=0x17;
//---UDP Length = 25
Dt[38]=0x00;Dt[39]=0x19;
//---UDP Checksum
Dt[40]=0x00;Dt[41]=0x00;
//---Payload
Dt[42]=0x41;Dt[43]=0x42;Dt[44]=0x43;Dt[45]=0x44;Dt[46]=0x45;
Dt[47]=0x46;Dt[48]=0x47;Dt[49]=0x48;Dt[50]=0x49;Dt[51]=0x4a;
Dt[52]=0x4b;Dt[53]=0x4c;Dt[54]=0x4d;Dt[55]=0x4e;Dt[56]=0x4f;
Dt[57]=0x50;Dt[58]=0x51;
for ( i = 0 ; i<58; i++)
My_Frame.uc_Data[i] = (unsigned char) Dt[i];
//---Write Frame to Queue
FdxCmdTxQueueWrite(g_ulPort1Handle,FDX_TX_FRAME_HEADER_GENERIC,1,
sizeof(My_Frame),&My_Frame);
//--- Frame 2 --- VL 60
for ( i = 0 ; i<1000; i++)
My_Frame.uc_Data[i] = (unsigned char) i;
//---MAC Dst= 0x03000000003c (VL 60)
Dt[
0]=0x03;Dt[
1]=0x00;Dt[
2]=0x00;Dt[
3]=0x00;Dt[
4]=0x00;Dt[
5]=0x3c;
//---MAC Src= 0x020000012120
Dt[
6]=0x02;Dt[
7]=0x00;Dt[
8]=0x00;Dt[
9]=0x01;Dt[10]=0x21;Dt[11]=0x20;
//---MAC Type/Length
Dt[12]=0x08;Dt[13]=0x00;
//---IP Header
Dt[14]=0x45;Dt[15]=0x00;Dt[16]=0x00;Dt[17]=0x2d;Dt[18]=0x00;Dt[19]=0x00
;Dt[20]=0x40;Dt[21]=0x00;Dt[22]=0x01;Dt[23]=0x11;Dt[24]=0x6d;Dt[25]=0x5
e;
Содержание API-FDX-2 V2
Страница 2: ......
Страница 6: ...iv GmbH THIS PAGE IS INTENTIONALLY LEFT BLANK...
Страница 8: ...vi GmbH A DOWNLOADING THE BSP FROM AIM ONLINE 37...
Страница 14: ...6 API FDX Linux Getting Started Manual GmbH Section 2 Requirements THIS PAGE IS INTENTIONALLY LEFT BLANK...
Страница 22: ...14 API FDX Linux Getting Started Manual GmbH Section 2 Requirements THIS PAGE IS INTENTIONALLY LEFT BLANK...
Страница 44: ...36 API FDX Linux Getting Started Manual GmbH Section 9 Notes THIS PAGE INTENTIONALLY LEFT BLANK...
Страница 48: ...40 API FDX Linux Getting Started Manual GmbH Appendix B Cross Compilation THIS PAGE INTENTIONALLY LEFT BLANK...