panels

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Panels Dashboard

Panels仪表盘

Panels (by Lazar/ByteForce) is a web-based dashboard for FTC robots providing telemetry, graphs, and live configuration.
Panels(由Lazar/ByteForce开发)是一款基于Web的FTC机器人仪表盘,提供遥测、图表与实时配置功能。

Quick Start

快速开始

Add dependency in
TeamCode/build.gradle
:
gradle
implementation "com.bylazar:fullpanels:1.0.6"
Access dashboard at
192.168.43.1:8001
when connected to robot WiFi.
TeamCode/build.gradle
中添加依赖:
gradle
implementation "com.bylazar:fullpanels:1.0.6"
连接机器人WiFi后,访问仪表盘地址
192.168.43.1:8001

Core Plugins

核心插件

Telemetry Plugin

遥测插件

Text-based telemetry mirroring Driver Hub output.
java
// Standard FTC telemetry works automatically
telemetry.addData("Position", follower.getPose());
telemetry.addData("State", pathState);
telemetry.update();
基于文本的遥测功能,与Driver Hub输出同步。
java
// 标准FTC遥测可自动生效
telemetry.addData("Position", follower.getPose());
telemetry.addData("State", pathState);
telemetry.update();

Graph Plugin

图表插件

Visualize data over time - useful for PID tuning and control system validation.
java
// Add values to graph in loop()
telemetry.addData("Motor Power", motor.getPower());
telemetry.addData("Target Position", targetPos);
telemetry.addData("Current Position", currentPos);
telemetry.update();  // REQUIRED after adding telemetry
可视化展示随时间变化的数据——适用于PID调优与控制系统验证。
java
// 在loop()中向图表添加数值
telemetry.addData("Motor Power", motor.getPower());
telemetry.addData("Target Position", targetPos);
telemetry.addData("Current Position", currentPos);
telemetry.update();  // 添加遥测数据后必须调用此方法

Configurables Plugin

可配置项插件

Tunable variables that update in real-time.
java
@Configurable
public class MyOpMode extends OpMode {
    // These can be adjusted live from dashboard
    public static double kP = 0.1;
    public static double kI = 0.0;
    public static double kD = 0.01;
    public static double targetPosition = 100;
}
Use
@Configurable
annotation on your OpMode class, then declare
public static
fields.
支持实时更新的可调变量。
java
@Configurable
public class MyOpMode extends OpMode {
    // 这些变量可通过仪表盘实时调整
    public static double kP = 0.1;
    public static double kI = 0.0;
    public static double kD = 0.01;
    public static double targetPosition = 100;
}
在OpMode类上使用
@Configurable
注解,然后声明
public static
字段即可。

Capture Plugin

捕获插件

Records debugging data for offline replay - debug without robot connected.
记录调试数据以供离线回放——无需连接机器人即可进行调试。

Dashboard Features

仪表盘功能

OpMode Control

OpMode控制

  • Start/stop OpModes from dashboard
  • Separate autonomous and teleop sections
  • Built-in safety timers
  • 从仪表盘启动/停止OpMode
  • 区分自主模式与遥控模式区域
  • 内置安全计时器

Gamepad Support

游戏手柄支持

  • Two FTC gamepad inputs
  • Pre-configured button mapping
  • Wireless robot control through dashboard
  • 支持两个FTC游戏手柄输入
  • 预配置按钮映射
  • 通过仪表盘无线控制机器人

Monitoring

监控功能

  • Battery level tracking
  • Network latency/delay monitoring
  • Automatic plugin update notifications
  • 电池电量追踪
  • 网络延迟监控
  • 插件自动更新通知

Themes & Layout

主题与布局

  • Customizable colors
  • Resizable widget panels
  • Grid-based layout
  • Tabbed widget groups
  • 可自定义颜色
  • 可调整大小的组件面板
  • 网格布局
  • 选项卡组式组件分组

Usage Pattern

使用示例

java
@Configurable
@TeleOp(name = "Debug TeleOp")
public class DebugTeleOp extends OpMode {
    // Live-tunable from dashboard
    public static double driveSpeed = 0.8;
    public static double turnSpeed = 0.6;

    @Override
    public void loop() {
        // Telemetry shows in dashboard
        telemetry.addData("Drive Speed", driveSpeed);
        telemetry.addData("Turn Speed", turnSpeed);
        telemetry.addData("Left Stick Y", gamepad1.left_stick_y);

        // Use configurable values
        double drive = -gamepad1.left_stick_y * driveSpeed;
        double turn = gamepad1.right_stick_x * turnSpeed;

        telemetry.update();
    }
}
java
@Configurable
@TeleOp(name = "Debug TeleOp")
public class DebugTeleOp extends OpMode {
    // 可通过仪表盘实时调整
    public static double driveSpeed = 0.8;
    public static double turnSpeed = 0.6;

    @Override
    public void loop() {
        // 遥测数据将显示在仪表盘中
        telemetry.addData("Drive Speed", driveSpeed);
        telemetry.addData("Turn Speed", turnSpeed);
        telemetry.addData("Left Stick Y", gamepad1.left_stick_y);

        // 使用可配置变量
        double drive = -gamepad1.left_stick_y * driveSpeed;
        double turn = gamepad1.right_stick_x * turnSpeed;

        telemetry.update();
    }
}

Reference

参考资料