Guide d’installation WPILib
Ce guide est destiné aux équipes programmant en Java et C++. Les équipes LabVIEW peuvent passer à la section Installation de LabVIEW pour FRC. En outre, le didacticiel ci-dessous montre le cas d’une installation sous Windows 10, mais les étapes sont identiques pour tous les systèmes d’exploitation. Les notes différenciant les systèmes d’exploitation seront affichées.
Prérequis
- Supported Operating Systems and Architectures:
Windows 10 & 11, 64 bit only. 32 bit and Arm are not supported
Ubuntu 22.04, 64 bit. Other Linux distributions with glibc >= 2.34 may work, but are unsupported
macOS 11 or higher, both Intel and Arm.
Avertissement
The following OSes are no longer supported: macOS 10.15, Ubuntu 18.04 & 20.04, Windows 7, Windows 8.1, and any 32-bit Windows.
WPILib est conçu pour s’installer dans différents dossiers correspondant à différentes années, de sorte qu’il n’est pas nécessaire de désinstaller une version précédente avant d’installer la version WPILib de l’année en cours.
Downloading
WPILib Installer
Release Notes
This is an update release of WPILib for the 2023 season. This release reduces NetworkTables CPU usage and latency, improves dashboard NetworkTables connection/disconnection behavior, and has several other quality-of-life improvements, in particular to Shuffleboard. This release also includes all fixes made in earlier releases.
Upgrading from earlier 2023 releases is easy: simply download and run the new installer and it will update your current installation. If you already have the 2023 WPILib vscode installed, it will detect it and you can simply click "next" for that installation step. After installation, vscode will prompt you when opening your robot project whether you want to upgrade it to this version. Note that using the installer is required to get the new version of desktop tools such as Shuffleboard.
The documentation for WPILib is located at https://docs.wpilib.org/ (if you have trouble accessing this location, https://frcdocs.wpi.edu/en/stable/ is an alternate location with the same content).
If you're new to FRC, start with Getting Started.
Minimum system requirements have changed for 2023. WPILib requires 64-bit Windows 10 or 11, Ubuntu 22.04, or macOS 11 or higher. Newly supported this year is Apple Silicon (arm64)! C++ teams should note that Visual Studio 2022 is now required for desktop builds. For this release, Mac users will need to have the Xcode Command Line Tools installed before running the installer; we are working on removing this requirement in a future release. This can be done by running xcode-select --install
in the Terminal.
If you're returning from a previous season, check out what's new for 2023; be sure to read through this, as a lot has changed from 2022! You will need a new RoboRIO image for 2023; this is available via the FRC 2023 Game Tools. Follow the WPILib installation guide to install WPILib.
If you're starting from a 2022 robot project, you will need to import your project to create a 2023 project. The import process is important, as it will make a number of automated corrections for some breaking changes that happened in 2023. It is also necessary to import vendor libraries again, since last year’s vendor libraries must be updated to be compatible with this year’s projects.
A complete list of known issues with this release can be found here.
WPILib is developed by a small team of volunteers and the FIRST community.
What's Changed since 2022.4.2
NetworkTables
- Optimize scan of outgoing messages by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5227
- NT4 client: close timed-out connections by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5175
- Use int64 for datalog type string by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5186
- ParallelTcpConnector: don't connect to duplicate addresses by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5169
Math
- Check LTV controller max velocity precondition by @calcmogul in https://github.com/wpilibsuite/allwpilib/pull/5142
- Fix invalid iterator access in TimeInterpolatableBuffer by @virtuald in https://github.com/wpilibsuite/allwpilib/pull/5138
- Fix Pose3d log returning Twist3d NaN for theta between 1E-9 and 1E-7 by @7910f6ba7ee4 in https://github.com/wpilibsuite/allwpilib/pull/5168
- Fix NaN in C++ MakeCostMatrix() that takes an array by @calcmogul in https://github.com/wpilibsuite/allwpilib/pull/5194
- Fix potential divide-by-zero in RKDP by @calcmogul in https://github.com/wpilibsuite/allwpilib/pull/5242
Commands
- RamseteCommand: default-initialize m_prevSpeeds by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5188
WPILib
- Add isTestEnabled and minor docs cleanup by @rzblue in https://github.com/wpilibsuite/allwpilib/pull/5172
- Fix enableLiveWindowInTest crashing in disabled by @rzblue in https://github.com/wpilibsuite/allwpilib/pull/5173
- DataLogManager: increase time for datetime to be valid by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5185
- Fix DutyCycleEncoder.setDistancePerRotation() in java simulation by @rzblue in https://github.com/wpilibsuite/allwpilib/pull/5147
- Fix RobotController.getComments() mishandling quotes inside the comments string by @rzblue in https://github.com/wpilibsuite/allwpilib/pull/5197
- [java] DriverStation: Fix joystick data logs by @PeterJohnson in https://github.com/wpilibsuite/allwpilib/pull/5240
- Shuffleboard: Keep duplicates on SelectTab() by @Starlight220 in https://github.com/wpilibsuite/allwpilib/pull/5198
Shuffleboard
- Fix IndexOutOfBoundsException in tab setup by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/772
- Make any entries set by dashboard retained by @PeterJohnson in https://github.com/wpilibsuite/shuffleboard/pull/778
- FieldData: Don't throw on missing data by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/776
- Add DataSource.equals() by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/774
- Don't switch to selected tab on value change by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/771
- CameraServerWidget: Explicitly unbox Number objects by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/780
- Use ConcurrentHashMap for static collection of NT sources by @Starlight220 in https://github.com/wpilibsuite/shuffleboard/pull/779
SysId
- Give measurement period a valid default of 1 by @calcmogul in https://github.com/wpilibsuite/sysid/pull/495
- Add Venom support by @wlmchen in https://github.com/wpilibsuite/sysid/pull/499
Docs
- CommandScheduler.isComposed: Remove incorrect throws clause (NFC) by @DAflamingFOX in https://github.com/wpilibsuite/allwpilib/pull/5183
- WaitCommand: Remove subclass note (NFC) by @Starlight220 in https://github.com/wpilibsuite/allwpilib/pull/5200
Examples
- Shuffleboard: Correct parameter order by @Starlight220 in https://github.com/wpilibsuite/allwpilib/pull/5204
New Contributors
- @7910f6ba7ee4 made their first contribution in https://github.com/wpilibsuite/allwpilib/pull/5143
- @wlmchen made their first contribution in https://github.com/wpilibsuite/sysid/pull/499
MD5 Hashes
fc58a52edea675b0ff91938a9c9d0743 WPILib_Linux-2023.4.3.tar.gz
5b67d336669bed34ab0dd428f81b9d31 WPILib_Windows-2023.4.3.iso
47246def80eea87b468e0be30119f789 WPILib_macOS-Intel-2023.4.3.dmg
1bb6113c1202fbb68248c3848556e47e WPILib_macOS-Arm64-2023.4.3.dmg
SHA256 Hashes
640e1ee7cc8f39d1789b4137f4a5aae90f78eeecf2326e2c50808205d02e7795 WPILib_Linux-2023.4.3.tar.gz
8ea417ede0a8541c9ab906b943be55ca49112dddef6750f2db1a742ba0c69378 WPILib_Windows-2023.4.3.iso
a80723596a08790c78b4c35ac64b4758c72076e74df559512a62c808b2a11ef1 WPILib_macOS-Intel-2023.4.3.dmg
8dad67e28a3bdf482979a1fe4c857d52ab36a2fdec56ae05971b7177d5409ae9 WPILib_macOS-Arm64-2023.4.3.dmg
You can download the latest release of the installer from GitHub.
Once on the GitHub releases page, scroll to the assets section at the bottom of the page.

Then click on the correct binary for your OS and architecture to begin the download.

Extraction de l’installateur
Lorsque vous téléchargez l’installateur WPILib, celui-ci est distribué sous la forme d’un fichier d’image de disque .iso
pour Windows, .tar.gz
pour Linux, et distribué sous la forme de DMG
pour MacOS.
Windows 10+ users can right click on the downloaded disk image and select Mount to open it. Then launch WPILibInstaller.exe
.

Note
Other installed programs may associate with iso files and the mount option may not appear. If that software does not give the option to mount or extract the iso file, then follow the directions below.
You can use 7-zip to extract the disk image by right-clicking, selecting 7-Zip and selecting Extract to…. Windows 11 users may need to select Show more options at the bottom of the context menu.

After opening the .iso
file, launch the installer by opening WPILibInstaller.exe
.
Note
After launching the installer, Windows may display a window titled « Windows protected your PC ». Click More info, then select Run anyway to run the installer.
For this release, macOS users will need to have the Xcode Command Line Tools installed before running the installer; we are working on removing this requirement in a future release. This can be done by running xcode-select --install
in the Terminal.
Les utilisateurs du système macOS peuvent cliquer deux fois sur le DMG
téléchargé, puis sélectionnez WPILibInstaller
pour lancer l’application.

Les utilisateurs de Linux devraient extraire le .tar.gz
téléchargé, puis lancer WPILibInstaller
. Ubuntu traite les fichiers exécutables dans l’explorateur de fichiers comme des libairies partagées, de sorte qu’en les double-cliquant, on ne les exécutera pas. À la place, exécutez les commandes suivantes dans un terminal avec <version>
remplacé par la version que vous êtes en train d’installer.
$ tar -xf WPILib_Linux-<version>.tar.gz
$ cd WPILib_Linux-<version>/
$ ./WPILibInstaller
Exécution de l’installateur
Lors de l’ouverture de l’installateur, l’écran ci-dessous vous sera présenté. Procédez et appuyez sur Start.


Cela présente une liste d’options incluses avec l’installation de WPILib.
Tools Only installe uniquement les outils WPILib (Pathweaver, Shuffleboard, RobotBuilder, SysID, Glass et OutlineViewer) et le JDK.
Everything installe l’environnement de développement complet (VS Code, extensions, toutes les dépendances), les outils WPILib et le JDK.
Vous remarquerez deux boutons, Install for this User et Install for all Users. Install for this User ne l’installe que sur le compte utilisateur actuel et ne nécessite pas de privilèges d’administrateur. Cependant, Install for all Users installe les outils pour tous les comptes système et nécessitera un accès administrateur. Install for all Users n’est pas une option pour macOS et Linux.
Note
Si vous sélectionnez Install for all Users, Windows vous demandera un accès administrateur via le contrôle de compte d’utilisateur pendant l’installation.
Sélectionnez l’option qui vous convient et l’écran d’installation suivant vous sera présenté.
Cet écran suivant concerne le téléchargement de VS Code. Malheureusement, pour des raisons de licence, VS Code ne peut pas être intégré dans l’installateur.

Télécharger pour cet ordinateur uniquement
Cette option télécharge VS Code uniquement pour la plate-forme actuelle, ce qui correspond également au plus petit téléchargement.
Ignorer et ne pas utiliser VS Code
Ignore l’installation de VS Code. Cette option est utile pour les installations ou les configurations avancées. Généralement pas recommandé.
Sélectionnez le fichier zip de VS Code existant pour une installation hors connexion sur cet ordinateur
La sélection de cette option fera apparaître une invitation vous permettant de sélectionner un fichier zip préexistant de VS Code qui a été téléchargé précédemment par le programme d’installation. Cette option ne vous permet pas de sélectionner une copie déjà installée de VS Code sur votre machine.
Créer un fichier zip VS Code à partager avec d’autres ordinateurs/systèmes d’exploitation pour une installation hors connexion
Cette option télécharge et enregistre une copie de VS Code pour toutes les plates-formes, ce qui est utile pour partager la copie du programme d’installation.
Go ahead and select Download for this computer only. This will begin the download process and can take a bit depending on internet connectivity (it’s ~100MB). Once the download is done, select Next. You should be presented with a screen that looks similar to the one below.

Une fois l’installation terminée, l’écran de fin d’installation vous sera présenté.

Important
WPILib installe une version distincte de VS Code. Il n’utilise pas une installation déjà existante. Chaque année a sa propre copie des outils ajoutés avec l’année. IE: WPILib VS Code 2022
. Veuillez lancer le VS Code WPILib non une copie installée du système!
Félicitations, l’environnement de développement et les outils WPILib sont maintenant installés sur votre ordinateur! Appuyez sur Terminer pour quitter le programme d’installation.
Après l’installation
Certains systèmes d’exploitation nécessitent une dernière action pour terminer l’installation.
Après l’installation, l’installateur ouvre le dossier WPILib VS Code. Faites glisser l’application VS Code sur le dock. Éjectez l’image WPILibInstaller du bureau.
Certaines versions de Linux (par exemple Ubuntu 20.04) vous obligent à donner au raccourci de bureau la possibilité de démarrer. Cliquez à droite sur l’icône de bureau et sélectionnez Allow Launching.

Note
Installing desktop tools and rebooting will create a folder on the desktop called YYYY WPILib Tools
, where YYYY
is the current year. Desktop tool shortcuts are not available on Linux and macOS.
Installation C++ supplémentaire pour la simulation
C++ robot simulation requires that a native compiler to be installed. For Windows, this would be Visual Studio 2022 (not VS Code), macOS requires Xcode 13 or later, and Linux (Ubuntu) requires the build-essential
package.
Assurez-vous que l’option Desktop Development with C++ est cochée dans le programme d’installation de Visual Studio pour la prise en charge de la simulation.

Qu’est-ce qui a été installé?
Le programme d’installation hors ligne installe les composants suivants:
Visual Studio Code - L’IDE pris en charge à partir de 2019 et en montant pour le développement du code robot. L’installateur hors ligne définit une copie distincte de VS Code pour le développement WPILib, même si vous avez déjà VS Code sur votre ordinateur. Cela est possible car certains des paramètres pour la configuration et le bon fonctionnement de la WPILib peuvent briser les flux de travail existants si vous utilisez VS Code pour d’autres projets.
C++ Compiler - Les chaînes de compilation pour la création du code C++ pour le roboRIO
Gradle - La version spécifique de Gradle utilisée pour la création/déploiement du code robot C++ ou Java
Java JDK/JRE - Une version spécifique de Java JDK/JRE qui est utilisée pour construire le code robot Java et pour exécuter l’un des outils basés sur Java (Dashboard, etc.). Celle-ci cohabite avec les installations JDK déjà existantes et n’écrase pas la variable JAVA_HOME
Outils WPILib - SmartDashboard, Shuffleboard, RobotBuilder, Outline Viewer, Pathweaver, Glass, SysID
WPILib Dependencies - OpenCV, etc.
VS Code Extensions - Extensions WPILib pour le développement du code robot sous VS Code
Désinstallation
WPILib est conçu pour être installé dans différents dossiers pendant différentes années, de sorte qu’il n’est pas nécessaire de désinstaller une version précédente avant d’installer le WPILib de cette année courante. Cependant, les instructions suivantes peuvent être utilisées pour désinstaller WPILib si vous le souhaitez.
Delete the appropriate wpilib folder (
c:\Users\Public\wpilib\YYYY
whereYYYY
is the year to uninstall)Supprimez les icônes du bureau dans
C:\Users\Public\Public Desktop
Supprimez les variables d’environnement Path.
Dans le menu Start, taper Environment et sélectionnez « edit the system environment variables »
Cliquez sur le bouton des variables d’environnement (1).
Dans les variables utilisateur, sélectionnez le chemin (path) (2) puis cliquez sur edit (3).
Sélectionnez le chemin avec
roborio\bin
(4) et cliquez sur supprimer (5).Sélectionnez le chemin avec
frccode
et cliquez sur supprimer (5).Répétez les étapes 3 à 6 dans le volet « Systems Variable ».

Delete the appropriate wpilib folder (
~/wpilib/YYYY
whereYYYY
is the year to uninstall)
Delete the appropriate wpilib folder (
~/wpilib/YYYY
whereYYYY
is the year to uninstall). egrm -rf ~/wpilib/YYYY
Dépannage
En cas de défaillance de l’installateur, signalez le problème dans le dépôt de l’installateur. Un lien est disponible ici. L’installateur doit signaler un message relatif à la cause de l’erreur, s’il vous plaît l’inclure dans la description de votre problème.