”Build your own ADS-B receiver”という事で。。。
Flightradar24 Data feeds用 Raspberry Pi 再構築手順 備忘録
ページ中段以降に作成手順が書かれている
1.RaspberryPi 用イメージのダウンロード
https://repo-feed.flightradar24.com/rpi_images/fr24-raspberry-pi-latest.img.zip
2.事前に SD card を format して異常無いか確認
使用ソフト例:SD Card Formatter
3.SD card に、ダウンロードした Pi24 img-file を書き込む
使用ソフト例:balenaEtcher <-- これはZIPファイルのままで処理可能
又は Win32DiskImager
4.write 終わったら一旦SD card 抜いて再度差し込む
PC で下記二つのファイルを編集しておく
1) SD card 内の "fr24key.txt" に
以前割り当てられた sharing key を記入
例 123abcd456789012
2) WiFi 接続の場合、SD card 内の
"wpa_supplicant.conf"の内容を使用環境に合わせて修正しておく
最初は、wpa_supplicant.conf.template になっているので Rename する事
無線LAN親機の、SSID/パスワードを設定
5.SD card , DVBT Stick(USB) を、RaspberryPiに装着し電源オン
今回は、RaspberryPi 3b を使用
6. 2~3分後、PCから DHCPで割り振られた IP-address を調べて
使用ソフト例:netenum5
PCから "teraterm" で SSH ログインする
SSH LOGIN pi/raspberry <--- 初期値
#パスワードを自分用に変更しておく
pi@pi24-bookworm:~ $ passwd
#タイムゾーンを合わせておく
pi@pi24-bookworm:~ $ sudo raspi-config
5 Localisation Option --> L2 Timezone を、Asia/Tokyo に設定
7.IPアドレスの固定
#新OS bookworm 以降 以前の dhcpcd.conf の変更は使えない!!
ネット検索で見つかった一番簡単と思われる方法
networkmanger を使ったネットワーク変更
接続設定一覧取得
pi@pi24-bookworm:~ $ nmcli connection ( nmcli c で良い )
NAME UUID TYPE DEVICE
preconfigured xxxx 内容は非表示 xxxx wifi wlan0
lo xxxx 内容は非表示 xxxx loopback lo
Wired connection 1 xxxx 内容は非表示 xxxx ethernet --
参考:ネットワークインターフェイスの状態を取得
pi@pi24-bookworm:~ $ sudo nmcli device
DEVICE TYPE STATE CONNECTION
wlan0 wifi connected preconfigured
lo loopback connected (externally) lo
p2p-dev-wlan0 wifi-p2p disconnected --
eth0 ethernet unavailable --
wifi接続を固定IPにする (今回は"192.168.10.40"を使用)
pi@pi24-bookworm:~ $ sudo nano /etc/NetworkManager/system-connections/preconfigured.nmconnection
++++++++++++ファイル内容++++++++++++
[connection]
id=preconfigured
uuid=xxxx 内容は非表示 xxxx
type=wifi
[wifi]
mode=infrastructure
ssid=xx 内容は非表示 xx
hidden=false
[ipv4]
method=auto
[ipv6]
addr-gen-mode=default
method=auto
[proxy]
[wifi-security]
key-mgmt=wpa-psk
psk=xxxx 内容は非表示 xxxx
+++++++ファイル内容 終わり+++++++
上記のうち[ipv4]部分を下記に変更
[ipv4]
method=manual
address1=192.168.10.40/24,192.168.10.1
dns=192.168.10.1
NANO エディタ操作
保存 : CTRL+O , 終了 : CTRL+X
pi@pi24-bookworm:~ $
8.再起動
pi@pi24-bookworm:~ $ sudo shutdown -r now
1~2分後、PCから "teraterm" で SSH ログインする
192.168.10.40 にSSHログイン出来るのを確認
pi/変更したパスワード
9.PCのWeb画面に従ってアクティベーションする
問題なければココに表示されるので、右の”Activate”をクリックして終了
”No device found”の場合は下へ続く
インストールをやり直したりすると、上手く認識できない様子
10.Web画面で認識出来なかった場合
Teraterm SSH 接続から下記を実行
wget -qO- https://fr24.com/install.sh | sudo bash -s
pi@pi24-bookworm:~ $ wget -qO- https://fr24.com/install.sh | sudo bash -s
11.インストールスタート
途中メッセージ省略
[main][i]FR24 Feeder/Decoder
[main][i]Version: 1.0.48-0/generic
[main][i]Built on Apr 10 2024 08:37:23 (T202404100820/Linux/static_arm64)
[main][i]Running on: pi24-debian="12"
[main][i]Local IP(s): 192.168.10.40,fe80::51e0:f161:c68e:5033
[main][i]Copyright 2012-2024 Flightradar24 AB
[main][i]https://www.flightradar24.com
[main][i]DNS mode: PING
Welcome to the FR24 Decoder/Feeder sign up wizard!
Before you continue please make sure that:
1 - Your ADS-B receiver is connected to this computer or is accessible over network
2 - You know your antenna's latitude/longitude up to 4 decimal points and the altitude in feet
3 - You have a working email address that will be used to contact you
4 - fr24feed service is stopped. If not, please run: sudo systemctl stop fr24feed
To terminate - press Ctrl+C at any point
***ここから設定するデータを入力***
Step 1.1 - Enter your email address (username@domain.tld)
$:xxxx@yyy.zzz <--- email address (使用する sharing key 登録時と同じもの)
Step 1.2 - If you used to feed FR24 with ADS-B data before, enter your sharing key.
If you don't remember your sharing key, you can find it in your account on the website under "My data sharing".
https://www.flightradar24.com/account/data-sharing
Enter your sharing key or press ENTER/RETURN to continue.
$:xxx内容は非表示xxx <--- 以前割り当てられた sharing key を記入
Verifying sharing key...OK
Step 1.3 - Would you like to participate in MLAT calculations? (yes/no)$:no <--- "no"
Step 4.1 - Receiver selection:
1 - DVBT Stick (USB)
-----------------------------------------------------
2 - SBS1/SBS1er (USB/Network)
3 - SBS3 (USB/Network)
4 - ModeS Beast (USB/Network)
5 - AVR Compatible (DVBT over network, etc)
6 - microADSB (USB/Network)
Enter your receiver type (1-6)$:1 <--- "1"
Checking for dump1090...FOUND
Step 4.3 - Enter your additional dump1090 arguments or leave empty
$: <--- エンターのみ
Step 5.1 - Would you like to enable RAW data feed on port 30002 (yes/*no*)$:no <--- "no"
Step 5.2 - Would you like to enable Basestation data feed on port 30003 (yes/no)$:no <--- "no"
Saving settings to /etc/fr24feed.ini...OK
Settings saved, please restart the application by running the command(s) below to use new configuration!
sudo systemctl restart fr24feed
12. fr24feed スタート
pi@pi24-bookworm:~ $ sudo systemctl restart fr24feed
fr24feed 動作確認
pi@pi24-bookworm:~ $ systemctl status fr24feed.service
● fr24feed.service - Flightradar24 Decoder & Feeder
Loaded: loaded (/etc/systemd/system/fr24feed.service; enabled; preset: enabled)
Active: active (running) since Tue 2024-12-17 06:17:33 UTC; 3 days ago
Process: 2089 ExecStartPre=/usr/lib/fr24/install_dump1090.sh (code=exited, status=0/SUCCESS)
Process: 2098 ExecStartPre=/usr/lib/fr24/unregister_kernel_modules.sh (code=exited, status=0/SUCCESS)
Process: 2102 ExecStartPre=/usr/lib/fr24/create_missing_directories.sh (code=exited, status=1/FAILURE)
Process: 2109 ExecStartPre=/usr/bin/fr24feed --validate-config --config-file=/etc/fr24feed.ini (code=exited, status=0/SUCCE>
Main PID: 2110 (fr24feed)
Tasks: 19 (limit: 765)
CPU: 12h 3min 59.361s
CGroup: /system.slice/fr24feed.service
tq 2110 /usr/bin/fr24feed
mq234675 /usr/bin/dump1090-mutability --raw --write-json /run/dump1090-mutability/
Dec 20 13:50:38 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:50:45 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:50:50 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:50:55 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:51:02 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:51:07 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:51:14 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
Dec 20 13:51:14 pi24-bookworm fr24feed[2110]: [feed][n]syncing stream async: 1
Dec 20 13:51:15 pi24-bookworm fr24feed[2110]: [feed][n]syncing stream result: 1
Dec 20 13:51:19 pi24-bookworm fr24feed[2110]: [feed][i]sent 1,0 AC
pi@pi24-bookworm:~ $
Process: 2102 がエラーしているみたいだけど、動いている様子 ???
以上
参考情報
新規に構築する場合(内容が古いかもしれない)
Step 1.1 - Enter your email address (username@domain.tld)
$: <--- email address
Step 1.2 - If you used to feed FR24 with ADS-B data before enter your sharing key.
If you don't remember your sharing key, pelase use the retrival form:
https://feed.flightradar24.com/forgotten_key.php
Otherwise leave this field empty and continue.
$: <--- エンターのみ
Verifying sharing key...OK
Step 1.3 - Would you like to participate in MLAT calculations? (yes/no)$:no
IMPORTANT: For MLAT calculations the antenna's location should be entered very precise!
Step 3.A - Enter antenna's latitude (DD.DDDD)
$:
Step 3.B - Enter antenna's longitude (DDD.DDDD)
$:
Step 3.C - Enter antenna's altitude above the sea level (in feet)
$:
Step 4.1 - Receiver selection (in order to run MLAT please use DVB-T stick with dump1090 utility bundled with fr24feed):
1 - DVBT Stick (USB)
-----------------------------------------------------
2 - SBS1/SBS1er (USB/Network)
3 - SBS3 (USB/Network)
4 - ModeS Beast (USB/Network)
5 - AVR Compatible (DVBT over network, etc)
6 - microADSB (USB/Network)
7 - SBSx via Basestation (localhost:30006)
Enter your receiver type (1-7)$:1
Checking for dump1090...FOUND
Step 4.3 - Enter your additional dump1090 arguments or leave empty
$: <--- エンターのみ
Step 5.1 - Would you like to enable RAW data feed on port 30002 (yes/no)$:no
Step 5.2 - Would you like to enable Basestation data feed on port 30003 (yes/no)$:no
Step 6 - Please select desired logfile mode:
0 - Disabled
1 - 48 hour, 24h rotation
2 - 72 hour, 24h rotation
Select logfile mode (0-2)$:1
Saving settings to /etc/fr24feed.ini...OK
Settings saved, please run "sudo systemctl restart fr24feed" to use new configuration.
Installation and configuration completed!
pi@raspberrypi:~ $
fr24feed スタート
pi@raspberrypi:~ $ sudo systemctl restart fr24feed
0 件のコメント:
コメントを投稿