已知问题

本文详细介绍了FRC|reg|控制系统软件的已知问题(和解决方法)。

公开的问题

roboRIO 2.0 Ethernet Settings

Issue: On the roboRIO 2.0, the Ethernet port is configured to DHCP only. This will work in normal networking setups where the radio acts as a DHCP server, but will not communicate when tethered directly to the Driver Station via Ethernet.

Workaround: Use the roboRIO 网络仪表板 to change the Ethernet Adapter eth0 Configure IPv4 Address to DHCP or Link Local.

Driver Station Reporting No Code

Issue: There is a rare occurrence in the roboRIO 2.0 that causes the roboRIO to not properly start the robot program. This causes the Driver Station to report a successful connection but no code, even though code is deployed on the roboRIO.

Workaround: We are currently investigating the root cause, but FIRST volunteers have been made aware and the recommendation is to reboot the roboRIO when this occurs.

备注

Pressing the physical User button on the roboRIO for 5 seconds can also cause the robot code to not start, but a reboot will not start the robot code. If the robot code does not start after rebooting, press the User button. Ensure that nothing on the robot is in contact with the User button.

Radio Second Port Sometimes Fails to Communicate

Issue: There is a rare occurrence in the OM5P Radios that causes the second Ethernet port (the one farthest from the power plug) to not communicate.

Workaround: Generally, power cycling the radio will restablish communication with the second port. Alternately, utilize a network switch such as the tp-link switch available from FIRST Choice or the brainboxes SW-005 and plug all ethernet devices into the network switch and then plug the switch into the radio’s first Ethernet port. This also allows easier tethering while at competition.

Onboard I2C Causing System Lockups

Issue: Use of the onboard I2C port on the roboRIO 1 or 2, in any language, can result in system lockups. The frequency of these lockups appears to be dependent on the specific hardware (i.e. different roboRIOs will behave differently) as well as how the bus is being used.

Workaround: The only surefire mitigation is to use the MXP I2C port or another device to read the I2C data. Accessing the device less frequently and/or using a different roboRIO may significantly reduce the likelihood/frequency of lockups, it will be up to each team to assess their tolerance of the risk of lockup. This lockup can not be definitively identified on the field and a field fault will not be called for a match where this behavior is believed to occur. This lockup is a CPU/kernel hang, the roboRIO will completely stop responding and will not be accessible via the DS, webpage or SSH. If you can access your roboRIO via any of these methods, you are experiencing a different issue.

Several alternatives exist for accessing the REV color sensor without using the roboRIO I2C port. A similar approach could be used for other I2C sensors.

  • Use a Raspberry Pi Pico. Supports up to 2 REV color sensors, sends data to the roboRIO via serial. The Pi Pico is low cost (less than $10) and readily available.

  • Use a Raspberry Pi. Supports 1-4 color sensors, sends data to the roboRIO via NetworkTables. Primarily useful for teams already using a Raspberry Pi as a coprocessor.

Updating Properties on roboRIO 2.0 may be slow or hang

Issue: Updating the properties on a roboRIO 2.0 without reformatting using the Imaging Tool (such as setting the team number) may be slow or hang.

Workaround: After a few minutes of the tool waiting the roboRIO should be able to be rebooted and the new properties should be set.

Simulation crashes on Mac after updating WPILib

Issue: On macOS, after updating the project to use a newer version of WPILib, running simulation immediately crashes without the GUI appearing.

Workaround: In VS Code, run WPILib | Run a command in Gradle, clean. Alternatively, run ./gradlew clean in the terminal or delete the build directory.

由于缺少 GradleRIO 导致构建无效

问题: 用户的 Gradle 缓存很少会损坏,并且会显示类似于以下内容的错误:

Could not apply requested plugin [id: ‘edu.wpi.first.GradleRIO’, version: ‘2020.3.2’] as it does not provide a plugin with id ‘edu.wpi.first.GradleRIO’

解决方法:

删除位于``~$USER_HOME/.gradle`` 下的 Gradle 缓存。 Windows 可能需要启用查看隐藏文件的能力 <https://support.microsoft.com/en-us/windows/view-hidden-files-and-folders-in-windows-10-97fbc472-c603- 9d90-91d0-1166d1d9f4b5>`__。到目前为止,此问题仅出现在 Windows 上。如果您在其他操作系统上遇到此问题,请向 <https://github.com/wpilibsuite/frc-docs/issues/new>`__ 报告这个问题。

Driver Station日志中的汉字

**问题:**极少情况下,driver station日志会显示中文字符而不是英文文本。仅当Windows设置为英语以外的其他语言时,才会出现这种情况。

机器操控台日志窗口中出现中文字符。

**解决方法:**有两种已知的解决方法:

  1. 将中文字符复制并粘贴到记事本中,将显示英文文本。

  2. 暂时将Windows语言更改为英语。

C ++ Intellisense-启动时打开的文件无法正常工作

**问题:**在C++中,当VS Code启动时打开的文件将出现“Intellisense”功能异常,显示来自编译单元的所有选项的建议而不仅仅是适当的选项,或者找不到头文件。这是VS Code中的一个bug。

解决方法:

  1. 关闭VS Code中的所有文件,但保持VS Code处于打开状态

  2. 如果存在,删除 .vscode文件夹中的c_cpp_properties.json文件

  3. Run the “Refresh C++ Intellisense” command in VS Code.

  4. 在右下角,您应该会看到类似于平台的东西( linuxathna或windowsx86-64等)。如果不是linuxastina,请单击它并将其设置为linuxastina(release)。

  5. 等待〜1分钟

  6. 打开主cpp文件(而不是头文件)。 Intellisense现在应该可以工作了

Issues with WPILib Dashboards and Simulation on Windows N Editions

Issue: WPILib code using CSCore (dashboards and simulated robot code) will have issues on Education N editions of Windows.

  • Shuffleboard will run, but not load cameras

  • Smartdashbard will crash on start-up

  • Robot Simulation will crash on start-up

**解决方案:**安装`媒体功能包 <https://www.microsoft.com/en-us/software-download/mediafeaturepack>`__

Fixed in Game Tools 2023.1.0

Driver Station does not detect joysticks at startup

Issue: The Driver Station application does not detect already connected joysticks when it starts up. Connecting joysticks after it is already running works.

Workaround: Connect joysticks after starting the DS, or use the joystick rescan button or the F1 shortcut to rescan for joysticks.

Fixed in WPILib 2023.2.1

SysId - Robot program crash on startup when using CAN Spark Maxes

Issue: SysId 2023.1.1’s deployed robot program crashes on startup if it was configured to use CAN Spark Maxes.

Solution: Install WPILib 2023.2.1 or newer.

Manually flushing a client NetworkTableInstance does not work

Issue: Calling flush() on a NetworkTableInstance does not cause the data to be flushed to remote subscribers immediately. This issue will be fixed in an upcoming WPILib release.

Workaround: Set the periodic option on the NetworkTable publishers that need a faster update rate:

// Get a DoubleEntry for myTopic and update it with a 10ms period.
DoubleEntry myEntry = table.getDoubleTopic("myTopic").getEntry(0, PubSubOption.periodic(0.01));