LoginSignup
6
5

More than 5 years have passed since last update.

Windows IoTで時刻を同期する

Posted at

Windows IoTではw32tmというコマンドで時刻同期ができる。

確認した環境は次の通り。

  • デバイス:Raspberry Pi 2 Model B
  • Windows IoT バージョン:10.0.10586

また、デバイスのIPアドレスは"192.168.0.1"とする。

PowerShellでWindows IoTに入る

PowerShellのコンソールを開き、次のコマンドを実行してWindows IoTが動いているデバイスに接続する。

> Set-Item WSMan:\localhost\Client\TrustedHosts -Value 192.168.0.1
> Enter-PSSession -ComputerName 192.168.0.1 -Credential 192.168.0.1\Administrator

時刻を同期する

まずは時刻同期先を設定する。同期先はtime.windows.comにした。

> w32tm /config /update /manualpeerlist:time.windows.com /syncfromflags:manual

設定したらサービスを再起動する

> net stop w32time
> net start w32time

時刻同期を実行する。

> w32tm /resync

参考

6
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
5