LoginSignup
1
0

More than 5 years have passed since last update.

RTCM3とかを保存する

Last updated at Posted at 2019-02-07

後処理RTK

せっかくmy基地局を手に入れたら、リアルタイムRTKだけではなくて、後処理もしたくなりますよね?国土地理院の電子基準点データでもいいのだけれど、やっぱmy基地局使いたいじゃないですか。また、その他の評価のためにubxを保存したいとか。
そうなるとRTCM3とかを時間毎ぐらいのファイルサイズで保存しておく必要があります。

そうだ、cronを使おう

折角なのでRaspberryPiで作ってみました。RTKLIBはインストール済みで、str2strは/home/pi/str2strに配置されてるものとします。

$ crontab -e
0 * * * * /home/pi/RTCM3.sh 
"/home/pi/RTCM3.sh"

#!/bin/sh

timeout 3600s /home/pi/str2str -in serial://ttyACM0 -out file:///mnt/sda1/`date +%s`.rtcm3 > /home/pi/crontab-errors.log > /dev/null 2>&1

ファイル名

`date +%s`

の部分は好みが分かれる所でしょうか。このままだとunixタイムとなります。
http://www.atmarkit.co.jp/flinux/rensai/linuxtips/240datefilename.html

1
0
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
1
0