mirror of
https://github.com/jetkvm/website.git
synced 2025-09-16 08:38:16 +00:00
* docs: update developer mode section * docs: update developer mode section --------- Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
91 lines
4.6 KiB
Plaintext
91 lines
4.6 KiB
Plaintext
---
|
|
title: "Developing"
|
|
description: "Explore JetKVM's developer features including Developer Mode for SSH access, DFU Mode for firmware updates, and Serial Console for debugging. Learn how to customize and extend JetKVM's functionality."
|
|
order: 2
|
|
---
|
|
|
|
JetKVM is built with developers in mind, providing tools and modes that allow you to explore, modify, and extend the functionality of the device. If you're interested in tinkering, testing new firmware, or contributing to JetKVM, here's an overview of the key development features.
|
|
|
|
## Developer Mode
|
|
|
|
Developer Mode unlocks SSH access to the JetKVM device, allowing you to customize or modify the system. When you enable Developer Mode, you must provide an **SSH public key**, as JetKVM uses key-based authentication. **For security reasons, you can not use your JetKVM password for SSH logins.**
|
|
|
|
### Generating an SSH Key
|
|
|
|
Before you can enable Developer Mode, you need to generate an SSH key pair.
|
|
|
|
**On macOS and Linux:**
|
|
|
|
1. Open a terminal window.
|
|
2. Run the following command to generate a new SSH key pair:
|
|
```sh
|
|
ssh-keygen -t rsa -b 4096
|
|
```
|
|
3. You will be prompted to enter a file in which to save the key. Press **Enter** to accept the default location (`~/.ssh/id_rsa`).
|
|
4. You will be asked to enter a passphrase. This is optional but recommended for extra security.
|
|
5. Your public key will be saved to `~/.ssh/id_rsa.pub`.
|
|
|
|
**On Windows:**
|
|
|
|
1. Open PowerShell.
|
|
2. Run the following command to generate a new SSH key pair:
|
|
```powershell
|
|
ssh-keygen -t rsa -b 4096
|
|
```
|
|
3. You will be prompted to enter a file in which to save the key. Press **Enter** to accept the default location (`C:\\Users\\YourUsername\\.ssh\\id_rsa`).
|
|
4. You will be asked to enter a passphrase. This is optional but recommended for extra security.
|
|
5. Your public key will be saved to `C:\\Users\\YourUsername\\.ssh\\id_rsa.pub`.
|
|
|
|
### Adding Your SSH Key to JetKVM
|
|
|
|
1. Navigate to the JetKVM settings page.
|
|
2. Go to the **Advanced** tab.
|
|
3. Check the box to **Enable Developer Mode**.
|
|
4. Open your public key file (`~/.ssh/id_rsa.pub` or `C:\\Users\\YourUsername\\.ssh\\id_rsa.pub`) with a text editor and copy the entire content.
|
|
5. Paste the public key into the input box and save the changes.
|
|
|
|
### Connecting to JetKVM
|
|
|
|
Once you have enabled Developer Mode and added your SSH public key, you can connect to the JetKVM device using an SSH client.
|
|
|
|
1. Open a terminal (on macOS/Linux) or PowerShell (on Windows).
|
|
2. Use the following command to connect to your JetKVM device:
|
|
```sh
|
|
ssh root@<jetkvm-ip-address>
|
|
```
|
|
Replace `<jetkvm-ip-address>` with the IP address of your JetKVM device.
|
|
3. If you set a passphrase for your SSH key, you will be prompted to enter it.
|
|
|
|
The system runs on a lightweight Linux environment using **BusyBox** as the core user space and **DropBear** as the SSH server.
|
|
|
|
For a full, in-depth guide on how to develop and contribute to the JetKVM, please see the [DEVELOPMENT.md](https://github.com/jetkvm/kvm/blob/dev/DEVELOPMENT.md) file on our GitHub.
|
|
|
|
## DFU Mode (Device Firmware Update)
|
|
|
|
DFU Mode allows you to update the firmware of your JetKVM device, especially when standard access methods like SSH are not available or when testing new firmware. DFU mode provides a way to recover or upgrade the firmware without relying on the standard boot process.
|
|
|
|
### How to Enter DFU Mode:
|
|
|
|
1. Unplug the USB cable from the device.
|
|
2. Locate the small hole on the right side of the device.
|
|
3. Insert a needle into the hole and press & hold the button inside before reconnecting the USB cable.
|
|
4. Hold the needle for three seconds, then release. Your device is now in DFU Mode.
|
|
|
|
### Flashing New Firmware:
|
|
|
|
1. Download the firmware update tool for [MacOS & Linux](https://wiki.luckfox.com/Luckfox-Pico/Linux-MacOS-Burn-Image/) or [Windows](https://wiki.luckfox.com/Luckfox-Pico/Luckfox-Pico-RV1106/Luckfox-Pico-Ultra-W/Luckfox-Pico-emmc-burn-image/#driver-installation).
|
|
2. Compile your firmware into an `.img` file.
|
|
3. Run the following command in your terminal:
|
|
|
|
```sh
|
|
sudo ./upgrade_tool uf your_firmware.img
|
|
```
|
|
|
|
4. The tool will display progress, and once completed, the JetKVM device will boot with the new firmware.
|
|
|
|
## Serial Console
|
|
|
|
A serial console provides direct access to system logs, boot messages, and other low-level interactions. It is essential for debugging and monitoring the device during the boot process or when testing new features.
|
|
|
|
Since modern computers no longer include traditional serial ports, JetKVM uses a UART splitter to provide serial console access. The UART signal is multiplexed over the SBU (Sideband Use) pins of the USB cable, so you'll need a UART splitter to connect to the serial console.
|