Skip to content

oliverrees/jetscreen

Repository files navigation

Jetscreen

If you live on a flight path or often have planes flying overhead, you might wonder where in the world they've come from. Jetscreen uses live ADS-B data to identify planes flying overhead, and then looks up the origin via the adsbdb API.

Requirements

To run Jetscreen, you'll need the following hardware:

1. Set up the Raspberry Pi

Ensure your Raspberry Pi is configured with an operating system like Raspbian, and connected to a monitor and keyboard. You'll also need an internet connection via Wi-Fi or Ethernet.

First, update the system by running:

sudo apt update && sudo apt upgrade -y

2. Setup ADS-B Receiver

Follow the instructions for your specific USB ADS-B receiver (like the FlightAware Pro Stick Plus) to install the required software. This should expose a local URL where you can access the live ADS-B data stream (for the FlightAware Pro Stick Plus, it's http://[local IP]:8080/data/aircraft.json).

3. Install Node.js and npm

Jetscreen is built on Next.js, which requires Node.js and npm to run. Install them using the following commands:

sudo apt install nodejs npm -y

To verify the installation:

node -v
npm -v

Ensure you have the latest versions.

4. Clone the Jetscreen Repository

Clone the Jetscreen repository from GitHub:

git clone https://github.com/oliverrees/jetscreen.git

Navigate into the project folder:

cd jetscreen

5. Install Dependencies

Run the following command to install the necessary packages:

npm install

6. Create the .env.local File

Inside the root directory of the project, create a .env.local file to store environment variables:

touch .env.local

Edit this file to include the following variables:

LOCAL_ADSB_URL=http://192.168.1.100:8080/data/aircraft.json
NEXT_PUBLIC_FLIGHT_DETAILS_URL=https://api.adsbdb.com/v0/callsign/
NEXT_PUBLIC_CENTER_LAT=51.47674088740635
NEXT_PUBLIC_CENTER_LON=-0.23339838187103154
NEXT_PUBLIC_RADIUS_KM=2

Explanation of Environment Variables:

  • LOCAL_ADSB_URL: The URL of your local ADS-B data stream (replace with your actual IP and port).
  • NEXT_PUBLIC_FLIGHT_DETAILS_URL: The adsbdb API URL to fetch flight details by callsign - hexdb.io is another option.
  • NEXT_PUBLIC_CENTER_LAT: The latitude of the center point of the map where you're tracking planes (replace with your location).
  • NEXT_PUBLIC_CENTER_LON: The longitude of the center point (replace with your location).
  • NEXT_PUBLIC_RADIUS_KM: The radius (in kilometers) for which you want to track planes around your center point.

7. Start the Development Server

To start the server in development mode, run the following command:

npm run dev

This will start the server, and you can view Jetscreen by navigating to http://localhost:3000 in your browser.

8. Optional: Run Jetscreen in Production

For production mode, first build the app:

npm run build

Then, start the production server:

npm start

Now, you can access Jetscreen from any device on the same network by navigating to the Raspberry Pi's IP address and port 3000 in a browser.

9. Set up the browser on the Raspberry Pi

To run Jetscreen in full-screen mode on the Raspberry Pi, you can use a browser like Chromium. Install it using the following command:

sudo apt install chromium-browser -y

To open Jetscreen in full-screen mode, run:

chromium-browser --kiosk http://localhost:3000

About

See live jets overhead

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published