-
QT获取网络时间
基本过程如下:
1. 利用ntp服务器获取网络时间
QUdpSocket udp_sock;
udp_sock.connectToHost("time.windows.com",123);
2. 阻塞等待连接成功
if(udp_sock.waitForConnected(60000))
{
...
}
3. 发送时间请求
udp_sock.write(time_req);
udp_sock.flush();
4. 阻塞等待消息返回
if(udp_sock.waitForReadyRead(120000))
{
...
}
说明:此过程等待时间可能较长,出现连接失败的情况也比较常见。
- 2022-03-21 22:20:09下载
- 积分:1
-
jsp成绩管理系统
jsp成绩管理系统-jsp performance management system
- 2022-03-20 12:54:42下载
- 积分:1
-
HPSocket UDP简单测试代码
HPSocket UDP简单测试代码实现了udp server 和 udp client的简单通讯例子
- 2022-01-25 15:58:37下载
- 积分:1
-
一个用VC编写的网络电话例程
一个用VC编写的网络电话例程-a VC prepared by the telephone network routines
- 2022-08-16 20:04:56下载
- 积分:1
-
flatmenuform
FlatMenuForm
- 2023-07-31 23:45:03下载
- 积分:1
-
a UDP penetrate NAT example, compliance with RFC3489
一个UDP穿透NAT的例子,遵守RFC3489-a UDP penetrate NAT example, compliance with RFC3489
- 2023-03-10 15:25:03下载
- 积分:1
-
website produced the voice players, examples of the implementation of the cases,...
制作网页中的声音播放器,执行本例实例后,将创建一个带有1个下拉框和3个按钮的运行界面。鼠标单击下拉框可以选择要播放的声音文件(*.au),按下播放按钮可以播放当前的声音文件,按下循环按钮可以循环播放当前声音文件,按下停止按钮可以停止播放当前声音文件。-website produced the voice players, examples of the implementation of the cases, will create a with a drop-down box and three button operation interface. Mouse click the drop-down box can choose to play the sound files (*. au), press the button player can play current audio files, press the circle button on the current cycle of broadcast sound files, press the stop button to stop the current broadcast sound files.
- 2022-02-20 06:00:09下载
- 积分:1
-
网络监控系统 vc++开发 支持winRoute,Winxp带的ics共享,isa Server, 不支持sygate.对网卡无限制....
网络监控系统 vc++开发 支持winRoute,Winxp带的ics共享,isa Server, 不支持sygate.对网卡无限制.-Network monitoring system vc++ development support winRoute, Winxp belt ics share, isa Server, does not support sygate. Right card unlimited.
- 2022-02-05 22:39:27下载
- 积分:1
-
FTP Client
用java实现FTP客户机。执行ls、cd、pwd和get功能;
- 2022-04-07 10:12:13下载
- 积分:1
-
A tcp/ip protocol stack, including the realization of the arp, tcp, udp, http, f...
一个tcp/ip协议栈,实现了包括arp、tcp、udp、http、ftp、动态分配IP等协议-A tcp/ip protocol stack, including the realization of the arp, tcp, udp, http, ftp, such as dynamic allocation of IP agreements
- 2022-06-17 19:32:42下载
- 积分:1