File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -354,7 +354,7 @@ void iperf_server(void *thread_param)
354354 data = recvlen * RT_TICK_PER_SECOND / 125 / (tick2 - tick1 );
355355 integer = data /1000 ;
356356 decimal = data %1000 ;
357- LOG_I ("%s: %d.%03d0 Mbps!" , tid -> name , integer , decimal );
357+ LOG_I ("%s: %d.%03d0 Mbps!" , IPERF_GET_THREAD_NAME ( tid ) , integer , decimal );
358358 tick1 = tick2 ;
359359 recvlen = 0 ;
360360 }
Original file line number Diff line number Diff line change @@ -89,6 +89,17 @@ extern int closesocket(int s);
8989#define VN (packet ) (rt_uint8_t) ((packet.li_vn_mode & 0x38) >> 3) /* (vn & 00 111 000) >> 3 */
9090#define MODE (packet ) (rt_uint8_t) ((packet.li_vn_mode & 0x07) >> 0) /* (mode & 00 000 111) >> 0 */
9191
92+
93+ #if (RT_VER_NUM >= 0x50000 )
94+ #define NTP_RTT_VER_MAJOR RT_VERSION_MAJOR
95+ #define NTP_RTT_VER_MINOR RT_VERSION_MINOR
96+ #define NTP_RTT_VER_PATCH RT_VERSION_PATCH
97+ #else
98+ #define NTP_RTT_VER_MAJOR RT_VERSION
99+ #define NTP_RTT_VER_MINOR RT_SUBVERSION
100+ #define NTP_RTT_VER_PATCH RT_REVISION
101+ #endif
102+
92103/* Structure that defines the 48 byte NTP packet protocol */
93104typedef struct {
94105
@@ -230,9 +241,9 @@ time_t ntp_get_time(const char *host_name)
230241 }
231242 }
232243
233- send_data [9 ] = RT_VERSION ;
234- send_data [10 ] = RT_SUBVERSION ;
235- send_data [11 ] = RT_REVISION ;
244+ send_data [9 ] = NTP_RTT_VER_MAJOR ;
245+ send_data [10 ] = NTP_RTT_VER_MINOR ;
246+ send_data [11 ] = NTP_RTT_VER_PATCH ;
236247 send_data [12 ] = (uint8_t )(SW_VER_NUM >> 24 );
237248 send_data [13 ] = (uint8_t )(SW_VER_NUM >> 16 );
238249 send_data [14 ] = (uint8_t )(SW_VER_NUM >> 8 );
You can’t perform that action at this time.
0 commit comments