Home / Android_Termux
Name Modified Size InfoDownloads / Week
Parent folder
play_cam_en.sh 2025-09-08 43.7 kB
play_cam_pl.sh 2025-09-08 44.9 kB
ptz-en.sh 2025-09-08 70.9 kB
ptz-pl.sh 2025-09-08 74.6 kB
README.md 2025-08-13 3.2 kB
Totals: 5 Items   237.2 kB 0

README.md for play_cam.sh

Here's a well-structured README.md file in English for your play_cam.sh script. It explains the script's purpose, features, requirements, and how to use it, making it easy for users to understand and get started.


RTSP Stream Scanner (play_cam.sh)

play_cam.sh is a shell script for Termux on Android that automatically scans your local network for ONVIF RTSP cameras and lets you play the detected video streams using VLC. It's a handy tool for quickly accessing camera feeds without manually entering IP addresses and stream paths.

Features

  • Automatic Network Scanning: The script detects your active network interfaces and scans the subnets for open RTSP ports (default: 554 and 8554).
  • Stream Verification: It uses ffprobe to confirm that a detected RTSP URL contains an actual video or audio stream before presenting it to you.
  • Interactive Stream Selection: After the scan is complete, you get a list of found streams and can choose which ones you want to open in VLC.
  • Dependency Management: The script automatically checks for required packages (ffmpeg, vlc, netcat-openbsd, etc.) and guides you through the installation process if any are missing.
  • Beginner-Friendly: Includes a detailed help section (--info) with tips for new Termux users, explaining how to install the app and grant the necessary permissions.

Requirements

  • Android: The script is designed to run on an Android device.
  • Termux: The Termux terminal emulator app, preferably installed from F-Droid (the Google Play version can sometimes have update issues).
  • Termux Permissions: You'll need to grant Termux storage and API permissions. Run the following commands inside Termux: bash termux-setup-storage termux-setup-api
  • Dependencies: The script will prompt you to install the necessary packages. These include: ffmpeg, vlc, netcat-openbsd, ifconfig, ffprobe, jq, and termux-api.

Installation and Usage

  1. Save the Script: Save the script code into a file named play_cam.sh in your Termux home directory or any other location.
  2. Grant Permissions: Open Termux, navigate to the directory where you saved the file, and make it executable: bash chmod +x play_cam.sh
  3. Run the Script: bash ./play_cam.sh
  4. Follow the Prompts: The script will guide you through the process, from checking dependencies to scanning the network. If multiple subnets are found, it will ask you to select which one to scan.

Command-Line Options

  • -h, --help: Displays a brief usage manual.
  • -i, --info: Shows detailed instructions and tips for beginners.
  • -e, --edit: Launches the script editor to modify the script's code.

Logging

The script creates a log file named rtsp_scanner.log in the /sdcard/Download/ directory. You can use this file to troubleshoot issues and review the scan results. The script also automatically refreshes the Android media database upon exit, making the log file immediately visible in your device's file manager.

Source: README.md, updated 2025-08-13