Help us understand the problem. What is going on with this article?

Raspberry Piに秋月GPSロガーをつなぐ

More than 3 years have passed since last update.

数年前に買った通称秋月GPSロガー(GT-730F/L)をRaspberry Piにつないでみました。

手順

  1. screenのインストール
  2. Raspberry PiのUSBポートに挿す
  3. dmesgで探す
  4. screenでつなぐ
  5. 切断する

screenのインストール

$sudo apt-get install screen

USBポートに挿す

USBポートにGPSロガーを挿す

dmesgで探す

$dmesg

[ 6828.424303] usb 1-1.2: new full-speed USB device number 7 using dwc_otg
[ 6828.527314] usb 1-1.2: New USB device found, idVendor=067b, idProduct=2303
[ 6828.527352] usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 6828.527372] usb 1-1.2: Product: USB-Serial Controller D
[ 6828.527389] usb 1-1.2: Manufacturer: Prolific Technology Inc.
[ 6828.543211] pl2303 1-1.2:1.0: pl2303 converter detected
[ 6828.549512] usb 1-1.2: pl2303 converter now attached to ttyUSB0

今回はttyUSB0にアタッチされた模様。
手っ取り早いのは
$dmesg |grep tty

様子を見守る

$ screen /dev/ttyUSB0 38400

$GPGGA,134059.915,41xx.xxxx,N,140xx.xxxx,E,1,07,1.2,24.5,M,31.9,M,,0000*60
$GPRMC,134059.915,A,41xx.xxxx,N,140xx.xxxx,E,000.0,205.3,110816,,,A*65

いろいろ出てくるのでRubyのIOとかで変換して楽しむ。
このサイトが参考になる。
GPSのNMEAフォーマット

切断する

ctrl+aを押してkを押すとscreen消すよみたいなメッセージが下に出るのでyを押す。

a_halka
羽田空港第2ターミナル50番台スポットから手荷物受け取りカウンターまでウォーキングの会主宰
https://cf6.in/
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
No comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
ユーザーは見つかりませんでした