This Python program allows you to control a Roku device using a computer. It emulates a remote control by sending commands to the Roku device through HTTP requests. You can input a message, and the program will type it out on the Roku device using the virtual keyboard.
- Python 3.x
curl
command-line tool- Access to a Roku device on the same network
- Clone the repository or download the
rokutyper.py
file to your local machine. - Make sure you have Python 3.x installed on your system.
- Install the
curl
command-line tool if it is not already installed. You can download it from the official website or use a package manager specific to your operating system. - Ensure that your computer and the Roku device are connected to the same network.
- Open a terminal or command prompt and navigate to the directory where
typer.py
is located. - Run the program using the following command:
python rokutyper.py
- The program will display a welcome message and prompt you to enter the Roku IP address. If you don't know the IP address of your Roku device, you can press enter to automate a quick nmap scan to find it.
- Once the IP address is entered, the program will establish a connection with the Roku device and navigate to the search menu.
- Enter the desired message you want to type on the Roku device. The message can contain lowercase letters, numbers, spaces, and special characters.
- Press enter to initiate the typing process.
- The program will simulate typing on the Roku device by sending appropriate HTTP requests to navigate the virtual keyboard and select each character.
- Repeat steps 5-7 to type multiple messages.
- To exit the program, press
Ctrl+C
in the terminal or command prompt.
- The program uses the
curl
command-line tool to send HTTP requests. Make surecurl
is installed and accessible from the command line. - The program assumes the default port for Roku devices is
8060
. If your Roku device uses a different port, you may need to modify the URL in the program accordingly. - The program uses a dictionary (
board
) to map each character to its corresponding position on the Roku keyboard. You can modify this dictionary if you want to change the mapping. - The program sends HTTP requests to control the Roku device. Make sure your Roku device is powered on and connected to the network before running the program.
- This program is for educational purposes and assumes you have proper authorization to control the Roku device.
- Author: Clempton
- Created: September 17, 2021