F1 23 UDP
Data Output from F1® 23 Game
Found the code helpful? ⭐ Show your support by starring the repo on GitHub!
how to use?
import { F123UDP } from "f1-23-udp";
const f123: F123UDP = new F123UDP();
f123.start();
f123.on('motion',function(data) {
console.log(data);
})
#Overview
The F1® 23 Game supports the output of certain game data across UDP connections. This data can be used supply race information to external applications, or to drive certain hardware (e.g. motion platforms, force feedback steering wheels and LED devices).
The following information summarise these data structures so that developers of supporting hardware or software can configure these to work correctly with the F1® 23 Game.
*Note: To ensure that you are using the latest specification for this game, please check our official forum page https://answers.ea.com/t5/General-Discussion/F1-23-UDP-Specification/td-p/12632888
If you cannot find the information that you require then please contact the team via the official forum thread listed above. For any bugs with the UDP system, please post a new bug report on the F1® 23 Game forum.
DISCLAIMER: “This information is being provided under license from EA for reference purposes only and we do not make any representations or warranties about the accuracy or reliability of the information for any specific purpose.”
#Packet Information
Packet Types
Each packet carries different types of data rather than having one packet which contains everything. The header in each packet describes the packet type and versioning info so it will be easier for applications to check they are interpreting the incoming data in the correct way. Please note that all values are encoded using Little Endian format. All data is packed.
The following data types are used in the structures:
Type | Description |
---|
uint8 | Unsigned 8-bit integer |
int8 | Signed 8-bit integer |
uint16 | Unsigned 16-bit integer |
int16 | Signed 16-bit integer |
uint32 | Unsigned 32-bit integer |
float | Floating point (32-bit) |
Double | Double-precision floating point (64-bit) |
uint64 | Unsigned 64-bit integer |
char | Character |
Each packet has the following header:
struct PacketHeader
pub struct PacketHeader {
pub packet_format: u16,
pub game_year: u8,
pub game_major_version: u8,
pub game_minor_version: u8,
pub packet_version: u8,
pub packet_id: u8,
pub session_uid: u64,
pub session_time: f32,
pub frame_identifier: u32,
pub overall_frame_identifier: u32,
pub player_car_index: u8,
pub secondary_player_car_index: u8,
}
Packet IDs
The packets IDs are as follows:
Packet Name | Value | Description |
---|
Motion | 0 | Contains all motion data for player’s car – only sent while player is in control |
Session | 1 | Data about the session – track, time left |
Lap Data | 2 | Data about all the lap times of cars in the session |
Event | 3 | Various notable events that happen during a session |
Participants | 4 | List of participants in the session, mostly relevant for multiplayer |
Car Setups | 5 | Packet detailing car setups for cars in the race |
Car Telemetry | 6 | Telemetry data for all cars |
Car Status | 7 | Status data for all cars |
Final Classification | 8 | Final classification confirmation at the end of a race |
Lobby Info | 9 | Information about players in a multiplayer lobby |
Car Damage | 10 | Damage status for all cars |
Session History | 11 | Lap and tyre data for session |
Tyre Sets | 12 | Extended tyre set data |
Motion Ex | 13 | Extended motion data for player car |
Motion Packet
The motion packet gives physics data for all the cars being driven.
N.B. For the normalised vectors below, to convert to float values divide by 32767.0f – 16-bit signed values are used to pack the data and on the assumption that direction values are always between -1.0f and 1.0f.
Frequency: Rate as specified in menus
Size: 1349 bytes
Version: 1
struct CarMotionData
struct CarMotionData {
m_worldPositionX: f32,
m_worldPositionY: f32,
m_worldPositionZ: f32,
m_worldVelocityX: f32,
m_worldVelocityY: f32,
m_worldVelocityZ: f32,
m_worldForwardDirX: i16,
m_worldForwardDirY: i16,
m_worldForwardDirZ: i16,
m_worldRightDirX: i16,
m_worldRightDirY: i16,
m_worldRightDirZ: i16,
m_gForceLateral: f32,
m_gForceLongitudinal: f32,
m_gForceVertical: f32,
m_yaw: f32,
m_pitch: f32,
m_roll: f32,
}
struct PacketMotionData {
m_header: PacketHeader,
m_carMotionData: [CarMotionData; 22],
}
Session Packet
The session packet includes details about the current session in progress.
Frequency: 2 per second
Size: 644 bytes
Version: 1
struct MarshalZone {
m_zoneStart: f32,
m_zoneFlag: i8,
}
struct WeatherForecastSample {
m_sessionType: u8,
m_timeOffset: u8,
m_weather: u8,
m_trackTemperature: i8,
m_trackTemperatureChange: i8,
m_airTemperature: i8,
m_airTemperatureChange: i8,
m_rainPercentage: u8,
}
struct PacketSessionData {
m_header: PacketHeader,
m_weather: u8,
m_trackTemperature: i8,
m_airTemperature: i8,
m_totalLaps: u8,
m_trackLength: u16,
m_sessionType: u8,
m_trackId: i8,
m_formula: u8,
m_sessionTimeLeft: u16,
m_sessionDuration: u16,
m_pitSpeedLimit: u8,
m_gamePaused: u8,
m_isSpectating: u8,
m_spectatorCarIndex: u8,
m_sliProNativeSupport: u8,
m_numMarshalZones: u8,
m_marshalZones: [MarshalZone; 21],
m_safetyCarStatus: u8,
m_networkGame: u8,
m_numWeatherForecastSamples: u8,
m_weatherForecastSamples: [WeatherForecastSample; 56],
m_forecastAccuracy: u8,
m_aiDifficulty: u8,
m_seasonLinkIdentifier: u32,
m_weekendLinkIdentifier: u32,
m_sessionLinkIdentifier: u32,
m_pitStopWindowIdealLap: u8,
m_pitStopWindowLatestLap: u8,
m_pitStopRejoinPosition: u8,
m_steeringAssist: u8,
m_brakingAssist: u8,
m_gearboxAssist: u8,
m_pitAssist: u8,
m_pitReleaseAssist: u8,
m_ERSAssist: u8,
m_DRSAssist: u8,
m_dynamicRacingLine: u8,
m_dynamicRacingLineType: u8,
m_gameMode: u8,
m_ruleSet: u8,
m_timeOfDay: u32,
m_sessionLength: u8,
m_speedUnitsLeadPlayer: u8,
m_temperatureUnitsLeadPlayer: u8,
m_speedUnitsSecondaryPlayer: u8,
m_temperatureUnitsSecondaryPlayer: u8,
m_numSafetyCarPeriods: u8,
m_numVirtualSafetyCarPeriods: u8,
m_numRedFlagPeriods: u8,
}
Lap Data Packet
The lap data packet gives details of all the cars in the session.
Frequency: Rate as specified in menus
Size: 1131 bytes
Version: 1
struct LapData {
m_lastLapTimeInMS: u32,
m_currentLapTimeInMS: u32,
m_sector1TimeInMS: u16,
m_sector1TimeMinutes: u8,
m_sector2TimeInMS: u16,
m_sector2TimeMinutes: u8,
m_deltaToCarInFrontInMS: u16,
m_deltaToRaceLeaderInMS: u16,
m_lapDistance: f32,
m_totalDistance: f32,
m_safetyCarDelta: f32,
m_carPosition: u8,
m_currentLapNum: u8,
m_pitStatus: u8,
m_numPitStops: u8,
m_sector: u8,
m_currentLapInvalid: u8,
m_penalties: u8,
m_totalWarnings: u8,
m_cornerCuttingWarnings: u8,
m_numUnservedDriveThroughPens: u8,
m_numUnservedStopGoPens: u8,
m_gridPosition: u8,
m_driverStatus: u8,
m_resultStatus: u8,
m_pitLaneTimerActive: u8,
m_pitLaneTimeInLaneInMS: u16,
m_pitStopTimerInMS: u16,
m_pitStopShouldServePen: u8,
}
struct PacketLapData {
m_header: PacketHeader,
m_lapData: [LapData; 22],
m_timeTrialPBCarIdx: u8,
m_timeTrialRivalCarIdx: u8,
}
Event Packet
This packet gives details of events that happen during the course of a session.
Frequency: When the event occurs
Size: 45 bytes
Version: 1
// The event details packet is different for each type of event.
// Make sure only the correct type is interpreted.
#[repr(C)]
union EventDataDetails {
FastestLap: FastestLapData,
Retirement: RetirementData,
TeamMateInPits: TeamMateInPitsData,
RaceWinner: RaceWinnerData,
Penalty: PenaltyData,
SpeedTrap: SpeedTrapData,
StartLights: StartLightsData,
DriveThroughPenaltyServed: DriveThroughPenaltyServedData,
StopGoPenaltyServed: StopGoPenaltyServedData,
Flashback: FlashbackData,
Buttons: ButtonsData,
Overtake: OvertakeData,
}
#[repr(C)]
struct PacketEventData {
m_header: PacketHeader,
m_eventStringCode: [u8; 4],
m_eventDetails: EventDataDetails,
}
#[repr(C)]
struct FastestLapData {
vehicleIdx: u8,
lapTime: f32,
}
#[repr(C)]
struct RetirementData {
vehicleIdx: u8,
}
#[repr(C)]
struct TeamMateInPitsData {
vehicleIdx: u8,
}
#[repr(C)]
struct RaceWinnerData {
vehicleIdx: u8,
}
#[repr(C)]
struct PenaltyData {
penaltyType: u8,
infringementType: u8,
vehicleIdx: u8,
otherVehicleIdx: u8,
time: u8,
lapNum: u8,
placesGained: u8,
}
#[repr(C)]
struct SpeedTrapData {
vehicleIdx: u8,
speed: f32,
isOverallFastestInSession: u8,
isDriverFastestInSession: u8,
fastestVehicleIdxInSession: u8,
fastestSpeedInSession: f32,
}
#[repr(C)]
struct StartLightsData {
numLights: u8,
}
#[repr(C)]
struct DriveThroughPenaltyServedData {
vehicleIdx: u8,
}
#[repr(C)]
struct StopGoPenaltyServedData {
vehicleIdx: u8,
}
#[repr(C)]
struct FlashbackData {
flashbackFrameIdentifier: u32,
flashbackSessionTime: f32,
}
#[repr(C)]
struct ButtonsData {
buttonStatus: u32,
}
#[repr(C)]
struct OvertakeData {
overtakingVehicleIdx: u8,
beingOvertakenVehicleIdx: u8,
}
enum EventStringCode {
SessionStarted,
SessionEnded,
FastestLap,
Retirement,
DRSEnabled,
DRSDisabled,
TeamMateInPits,
ChequeredFlag,
RaceWinner,
PenaltyIssued,
SpeedTrapTriggered,
StartLights,
LightsOut,
DriveThroughServed,
StopGoServed,
Flashback,
ButtonStatus,
RedFlag,
Overtake,
}
impl From<[u8; 4]> for EventStringCode {
fn from(code: [u8; 4]) -> Self {
match code {
[83, 83, 84, 65] => EventStringCode::SessionStarted,
[83, 69, 78, 68] => EventStringCode::SessionEnded,
[70, 84, 76, 80] => EventStringCode::FastestLap,
[82, 84, 77, 84] => EventStringCode::Retirement,
[68, 82, 83, 69] => EventStringCode::DRSEnabled,
[68, 82, 83, 68] => EventStringCode::DRSDisabled,
[84, 77, 80, 84] => EventStringCode::TeamMateInPits,
[67, 72, 81, 70] => EventStringCode::ChequeredFlag,
[82, 67, 87, 78] => EventStringCode::RaceWinner,
[80, 69, 78, 65] => EventStringCode::PenaltyIssued,
[83, 80, 84, 80] => EventStringCode::SpeedTrapTriggered,
[83, 84, 76, 71] => EventStringCode::StartLights,
[76, 71, 79, 84] => EventStringCode::LightsOut,
[68, 84, 83, 86] => EventStringCode::DriveThroughServed,
[83, 71, 83, 86] => EventStringCode::StopGoServed,
[70, 76, 66, 75] => EventStringCode::Flashback,
[66, 85, 84, 78] => EventStringCode::ButtonStatus,
[82, 68, 70, 76] => EventStringCode::RedFlag,
[79, 86, 84, 75] => EventStringCode::Overtake,
_ => panic!("Unknown event string code: {:?}", code),
}
}
}
Event String Codes
Event | Code | Description |
---|
Session Started | “SSTA” | Sent when the session starts |
Session Ended | “SEND” | Sent when the session ends |
Fastest Lap | “FTLP” | When a driver achieves the fastest lap |
Retirement | “RTMT” | When a driver retires |
DRS enabled | “DRSE” | Race control have enabled DRS |
DRS disabled | “DRSD” | Race control have disabled DRS |
Team mate in pits | “TMPT” | Your team mate has entered the pits |
Chequered flag | “CHQF” | The chequered flag has been waved |
Race Winner | “RCWN” | The race winner is announced |
Penalty Issued | “PENA” | A penalty has been issued – details in event |
Speed Trap Triggered | “SPTP” | Speed trap has been triggered by fastest speed |
Start lights | “STLG” | Start lights – number shown |
Lights out | “LGOT” | Lights out |
Drive through served | “DTSV” | Drive through penalty served |
Stop go served | “SGSV” | Stop go penalty served |
Flashback | “FLBK” | Flashback activated |
Button status | “BUTN” | Button status changed |
Red Flag | “RDFL” | Red flag shown |
Overtake | “OVTK” | Overtake occurred |
Participants Packet
This is a list of participants in the race. If the vehicle is controlled by AI, then the name will be the driver name. If this is a multiplayer game, the names will be the Steam Id on PC, or the LAN name if appropriate.
N.B. on Xbox One, the names will always be the driver name, on PS4 the name will be the LAN name if playing a LAN game, otherwise it will be the driver name.
The array should be indexed by vehicle index.
Frequency: Every 5 seconds
Size: 1306 bytes
Version: 1
struct ParticipantData {
m_aiControlled: u8,
m_driverId: u8,
m_networkId: u8,
m_teamId: u8,
m_myTeam: u8,
m_raceNumber: u8,
m_nationality: u8,
m_name: [u8; 48],
m_yourTelemetry: u8,
m_showOnlineNames: u8,
m_platform: u8,
}
struct PacketParticipantsData {
m_header: PacketHeader,
m_numActiveCars: u8,
m_participants: [ParticipantData; 22],
}
Car Setups Packet
This packet details the car setups for each vehicle in the session. Note that in multiplayer games, other player cars will appear as blank, you will only be able to see your own car setup, regardless of the “Your Telemetry” setting. Spectators will also not be able to see any car setups.
Frequency: 2 per second
Size: 1107 bytes
Version: 1
struct CarSetupData {
m_frontWing: u8,
m_rearWing: u8,
m_onThrottle: u8,
m_offThrottle: u8,
m_frontCamber: f32,
m_rearCamber: f32,
m_frontToe: f32,
m_rearToe: f32,
m_frontSuspension: u8,
m_rearSuspension: u8,
m_frontAntiRollBar: u8,
m_rearAntiRollBar: u8,
m_frontSuspensionHeight: u8,
m_rearSuspensionHeight: u8,
m_brakePressure: u8,
m_brakeBias: u8,
m_rearLeftTyrePressure: f32,
m_rearRightTyrePressure: f32,
m_frontLeftTyrePressure: f32,
m_frontRightTyrePressure: f32,
m_ballast: u8,
m_fuelLoad: f32,
}
struct PacketCarSetupData {
m_header: PacketHeader,
m_carSetups: [CarSetupData; 22],
}
Car Telemetry Packet
This packet details telemetry for all the cars in the race. It details various values that would be recorded on the car such as speed, throttle application, DRS etc. Note that the rev light configurations are presented separately as well and will mimic real life driver preferences.
Frequency: Rate as specified in menus
Size: 1352 bytes
Version: 1
struct CarTelemetryData {
m_speed: u16,
m_throttle: f32,
m_steer: f32,
m_brake: f32,
m_clutch: u8,
m_gear: i8,
m_engineRPM: u16,
m_drs: u8,
m_revLightsPercent: u8,
m_revLightsBitValue: u16,
m_brakesTemperature: [u16; 4],
m_tyresSurfaceTemperature: [u8; 4],
m_tyresInnerTemperature: [u8; 4],
m_engineTemperature: u16,
m_tyresPressure: [f32; 4],
m_surfaceType: [u8; 4],
}
struct PacketCarTelemetryData {
m_header: PacketHeader,
m_carTelemetryData: [CarTelemetryData; 22],
m_mfdPanelIndex: u8,
m_mfdPanelIndexSecondaryPlayer: u8,
m_suggestedGear: i8,
}
Car Status Packet
This packet details car statuses for all the cars in the race.
Frequency: Rate as specified in menus
Size: 1239 bytes
Version: 1
struct CarStatusData {
m_traction_control: u8,
m_anti_lock_brakes: u8,
m_fuel_mix: u8,
m_front_brake_bias: u8,
m_pit_limiter_status: u8,
m_fuel_in_tank: f32,
m_fuel_capacity: f32,
m_fuel_remaining_laps: f32,
m_max_rpm: u16,
m_idle_rpm: u16,
m_max_gears: u8,
m_drs_allowed: u8,
m_drs_activation_distance: u16,
m_actual_tyre_compound: u8,
m_visual_tyre_compound: u8,
m_tyres_age_laps: u8,
m_vehicle_fia_flags: i8,
m_engine_power_ice: f32,
m_engine_power_mguk: f32,
m_ers_store_energy: f32,
m_ers_deploy_mode: u8,
m_ers_harvested_this_lap_mguk: f32,
m_ers_harvested_this_lap_mguh: f32,
m_ers_deployed_this_lap: f32,
m_network_paused: u8,
}
struct PacketCarStatusData {
m_header: PacketHeader,
m_car_status_data: [CarStatusData; 22],
}
Final Classification Packet
This packet details the final classification at the end of the race, and the data will match with the post race results screen. This is especially useful for multiplayer games where it is not always possible to send lap times on the final frame because of network delay.
Frequency: Once at the end of a race
Size: 1020 bytes
Version: 1
struct FinalClassificationData {
m_position: u8,
m_numLaps: u8,
m_gridPosition: u8,
m_points: u8,
m_numPitStops: u8,
m_resultStatus: u8,
m_bestLapTimeInMS: u32,
m_totalRaceTime: f64,
m_penaltiesTime: u8,
m_numPenalties: u8,
m_numTyreStints: u8,
m_tyreStintsActual: [u8; 8],
m_tyreStintsVisual: [u8; 8],
m_tyreStintsEndLaps: [u8; 8],
}
struct PacketFinalClassificationData {
m_header: PacketHeader,
m_numCars: u8,
m_classificationData: [FinalClassificationData; 22],
}
Lobby Info Packet
This packet details the players currently in a multiplayer lobby. It details each player’s selected car, any AI involved in the game and also the ready status of each of the participants.
Frequency: Two every second when in the lobby
Size: 1218 bytes
Version: 1
struct LobbyInfoData {
m_aiControlled: u8,
m_teamId: u8,
m_nationality: u8,
m_platform: u8,
m_name: [u8; 48],
m_carNumber: u8,
m_readyStatus: u8,
}
struct PacketLobbyInfoData {
m_header: PacketHeader,
m_numPlayers: u8,
m_lobbyPlayers: [LobbyInfoData; 22],
}
Car Damage Packet
This packet details car damage parameters for all the cars in the race.
Frequency: 10 per second
Size: 953 bytes
Version: 1
struct CarDamageData {
m_tyres_wear: [f32; 4],
m_tyres_damage: [u8; 4],
m_brakes_damage: [u8; 4],
m_front_left_wing_damage: u8,
m_front_right_wing_damage: u8,
m_rear_wing_damage: u8,
m_floor_damage: u8,
m_diffuser_damage: u8,
m_sidepod_damage: u8,
m_drs_fault: u8,
m_ers_fault: u8,
m_gear_box_damage: u8,
m_engine_damage: u8,
m_engine_mguh_wear: u8,
m_engine_es_wear: u8,
m_engine_ce_wear: u8,
m_engine_ice_wear: u8,
m_engine_mguk_wear: u8,
m_engine_tc_wear: u8,
m_engine_blown: u8,
m_engine_seized: u8,
}
struct PacketCarDamageData {
m_header: PacketHeader,
m_car_damage_data: [CarDamageData; 22],
}
Session History Packet
This packet contains lap times and tyre usage for the session. This packet works slightly differently to other packets. To reduce CPU and bandwidth, each packet relates to a specific vehicle and is sent every 1/20 s, and the vehicle being sent is cycled through. Therefore in a 20 car race you should receive an update for each vehicle at least once per second.
Note that at the end of the race, after the final classification packet has been sent, a final bulk update of all the session histories for the vehicles in that session will be sent.
Frequency: 20 per second but cycling through cars
Size: 1460 bytes
Version: 1
struct LapHistoryData {
m_lapTimeInMS: u32,
m_sector1TimeInMS: u16,
m_sector1TimeMinutes: u8,
m_sector2TimeInMS: u16,
m_sector2TimeMinutes: u8,
m_sector3TimeInMS: u16,
m_sector3TimeMinutes: u8,
m_lapValidBitFlags: u8,
}
struct TyreStintHistoryData {
m_endLap: u8,
m_tyreActualCompound: u8,
m_tyreVisualCompound: u8,
}
struct PacketSessionHistoryData {
m_header: PacketHeader,
m_carIdx: u8,
m_numLaps: u8,
m_numTyreStints: u8,
m_bestLapTimeLapNum: u8,
m_bestSector1LapNum: u8,
m_bestSector2LapNum: u8,
m_bestSector3LapNum: u8,
m_lapHistoryData: [LapHistoryData; 100],
m_tyreStintsHistoryData: [TyreStintHistoryData; 8],
}
Tyre Sets Packet
This packets gives a more in-depth details about tyre sets assigned to a vehicle during the session.
Frequency: 20 per second but cycling through cars
Size: 231 bytes
Version: 1
struct TyreSetData {
m_actualTyreCompound: u8,
m_visualTyreCompound: u8,
m_wear: u8,
m_available: u8,
m_recommendedSession: u8,
m_lifeSpan: u8,
m_usableLife: u8,
m_lapDeltaTime: i16,
m_fitted: u8,
}
struct PacketTyreSetsData {
m_header: PacketHeader,
m_carIdx: u8,
m_tyreSetData: [TyreSetData; 20],
m_fittedIdx: u8,
}
Motion Ex Packet
The motion packet gives extended data for the car being driven with the goal of being able to drive a motion platform setup.
Frequency: Rate as specified in menus
Size: 217 bytes
Version: 1
struct PacketMotionExData {
m_header: PacketHeader,
m_suspensionPosition: [f32; 4],
m_suspensionVelocity: [f32; 4],
m_suspensionAcceleration: [f32; 4],
m_wheelSpeed: [f32; 4],
m_wheelSlipRatio: [f32; 4],
m_wheelSlipAngle: [f32; 4],
m_wheelLatForce: [f32; 4],
m_wheelLongForce: [f32; 4],
m_heightOfCOGAboveGround: f32,
m_localVelocityX: f32,
m_localVelocityY: f32,
m_localVelocityZ: f32,
m_angularVelocityX: f32,
m_angularVelocityY: f32,
m_angularVelocityZ: f32,
m_angularAccelerationX: f32,
m_angularAccelerationY: f32,
m_angularAccelerationZ: f32,
m_frontWheelsAngle: f32,
m_wheelVertForce: [f32; 4],
}
Restricted data (Your Telemetry setting)
There is some data in the UDP that you may not want other players seeing if you are in a multiplayer game. This is controlled by the “Your Telemetry” setting in the Telemetry options. The options are:
- Restricted (Default) – other players viewing the UDP data will not see values for your car
- Public – all other players can see all the data for your car
- Show online ID – this additional option allows other players to view your online ID / gamertag in their UDP output.
Note: You can always see the data for the car you are driving regardless of the setting.
The following data items are set to zero if the player driving the car in question has their “Your Telemetry” set to “Restricted”:
Car status packet
- m_fuelInTank
- m_fuelCapacity
- m_fuelMix
- m_fuelRemainingLaps
- m_frontBrakeBias
- m_ersDeployMode
- m_ersStoreEnergy
- m_ersDeployedThisLap
- m_ersHarvestedThisLapMGUK
- m_ersHarvestedThisLapMGUH
- m_enginePowerICE
- m_enginePowerMGUK
Car damage packet
- m_frontLeftWingDamage
- m_frontRightWingDamage
- m_rearWingDamage
- m_floorDamage
- m_diffuserDamage
- m_sidepodDamage
- m_engineDamage
- m_gearBoxDamage
- m_tyresWear (All four wheels)
- m_tyresDamage (All four wheels)
- m_brakesDamage (All four wheels)
- m_drsFault
- m_engineMGUHWear
- m_engineESWear
- m_engineCEWear
- m_engineICEWear
- m_engineMGUKWear
- m_engineTCWear
Tyre set packet
- All data within this packet for player car
To allow other players to view your online ID in their UDP output during an online session, you must enable the “Show online ID / gamertags” option. Selecting this will bring up a confirmation box that must be confirmed before this option is enabled.
Please note that all options can be changed during a game session and will take immediate effect.
#FAQS
How do I enable the UDP Telemetry Output?
In F1 23, UDP telemetry output is controlled via the in-game menus. To enable this, enter the options menu from the main menu (triangle / Y), then enter the settings menu - the UDP option will be at the bottom of the list. From there you will be able to enable / disable the UDP output, configure the IP address and port for the receiving application, toggle broadcast mode and set the send rate. Broadcast mode transmits the data across the network subnet to allow multiple devices on the same subnet to be able to receive this information. When using broadcast mode it is not necessary to set a target IP address, just a target port for applications to listen on.
Advanced PC Users: You can additionally edit the game’s configuration XML file to configure UDP output. The file is located here (after an initial boot of the game):
...\Documents\My Games<game_folder>\hardwaresettings\hardware_settings_config.xml
You should see the tag:
...
...
Here you can set the values manually. Note that any changes made within the game when it is running will overwrite any changes made manually. Note the enabled flag is now a state.
What has changed since last year?
F1® 23 sees the following changes to the UDP specification:
- Added game year to packet header – apps can identify which F1 game data is coming from
- Temperature and speed units choice for players sent in session packet
- Platform of players added to lobby info and participants packets
- Added flag to say whether a player has their “Show online names” flag set in participants packet
- Added whole minute part to sector times in lap data and session history packets
- Damage packet now updates at 10/s
- Separated corner cutting warnings in the lap data packet
- Added new tyre sets packet to give more detail about tyre sets for each car
- Added time deltas for cars in the lap data packet
- Added overall frame identifier to packet header to help deal with flashbacks
- Red flag event added
- Added Safety car, VSC and Red Flag counts to session data
- Added more physics data in the motion packet
- Added Overtake event
- Added power outputs readings for the engine
- Added C0 tyre type
- Added a new Motion Ex packet and moved player car settings from Motion packet to stop it getting too large, added vertical wheel forces
What is the order of the wheel arrays?
All wheel arrays are in the following order:
0 – Rear Left (RL)
1 – Rear Right (RR)
2 – Front Left (FL)
3 – Front Right (FR)
Do the vehicle indices change?
During a session, each car is assigned a vehicle index. This will not change throughout the session and all the arrays that are sent use this vehicle index to dereference the correct piece of data.
What are the co-ordinate systems used?
Here is a visual representation of the co-ordinate system used with the F1 telemetry data.
![Diagram
Description automatically generated](Aspose.Words.01edf42c-17a2-49a2-965c-e50b14328043.002.png) ![Logo
Description automatically generated with low confidence](Aspose.Words.01edf42c-17a2-49a2-965c-e50b14328043.003.png)
What encoding format is used?
All values are encoded using Little Endian format.
Are the data structures packed?
Yes, all data is packed, there is no padding used.
How many cars are in the data structures?
The maximum number of cars in the data structures is 22, to allow for certain game modes, although the data is not always filled in.
You should always check the data item called m_numActiveCars in the participants packet which tells you how many cars are active in the race. However, you should check the individual result status of each car in the lap data to see if that car is actively providing data. If it is not “Invalid” or “Inactive” then the corresponding vehicle index has valid data.
How often are updated packets sent?
For the packets which get updated at “Rate as specified in the menus” you can be guaranteed that on the frame that these get sent they will all get sent together and will never be separated across frames. This of course relies on the reliability of your network as to whether they are received correctly as everything is sent via UDP. Other packets that get sent at specific rates can arrive on any frame.
If you are connected to the game when it starts transmitting the first frame will contain the following information to help initialise data structures on the receiving application:
Packets sent on Frame 1: (All packets sent on this frame have “Session timestamp” 0.000)
- Session
- Participants
- Car Setups
- Lap Data
- Motion Data
- Car Telemetry
- Car Status
- Car Damage
- Motion Ex Data
As an example, assuming that you are running at 60Hz with 60Hz update rate selected in the menus then you would expect to see the following packets and timestamps:
Packets sent on Frame 2: (All packets sent on this frame have “Session timestamp” 0.016)
- Lap Data
- Motion Data
- Car Telemetry
- Car Status
- Motion Ex Data
…
Packets sent on Frame 31: (All packets sent on this frame have “Session timestamp” 0.5)
- Session (since 2 updates per second)
- Car Setups (since 2 updates per second)
- Lap Data
- Motion Data
- Car Telemetry
- Car Status
- Car Damage (since 2 updates per second)
- Motion Ex Data
Will my old app still work with F1 23?
Please note that from F1 23 the game will only support the previous 2 UDP formats.
F1 23 uses a new format for the UDP data. However, some earlier formats of the data are still supported so that most older apps implemented using the previous data formats should work with little or no change from the developer. To use the old formats, please enter the UDP options menu and set “UDP Format” to either “2022” or “2021”.
Specifications for the older formats can be seen here:
- F1 2021 -
https://forums.codemasters.com/topic/80231-f1-2021-udp-specification
- F1 22 -
https://answers.ea.com/t5/General-Discussion/F1-22-UDP-Specification/td-p/11551274
How do I enable D-BOX output?
D-BOX output is currently supported on the PC platform. In F1 23, the D-BOX activation can be controlled via the menus. Navigate to Game Options->Settings->UDP Telemetry Settings->D-BOX to activate this on your system.
Advanced PC Users: It is possible to control D-BOX by editing the games’ configuration XML file. The file is located here (after an initial boot of the game):
...\Documents\My Games<game_folder>\hardwaresettings\hardware_settings_config.xml
You should see the tag:
<dbox enabled="false" />
...
Set the “enabled” value to “true” to allow the game to output to your D-BOX motion platform. Note that any changes made within the game when it is running will overwrite any changes made manually.
How can I disable in-game support for LED device?
The F1 game has native support for some of the basic features supported by some external LED devices, such as the Leo Bodnar SLI Pro and the Fanatec steering wheels. To avoid conflicts between the game’s implementation and any third-party device managers on the PC platform it may be necessary to disable the native support. This is done using the following led_display flags in the hardware_settings_config.xml. The file is located here (after an initial boot of the game):
...\Documents\My Games<game_folder>\hardwaresettings\hardware_settings_config.xml
The flags to enabled/disable LED output are:
<led_display fanatecNativeSupport="true" sliProNativeSupport="true" />
The sliProNativeSupport flag controls the output to SLI Pro devices. The fanatecNativeSupport flag controls the output to Fanatec (and some related) steering wheel LEDs. Set the values for any of these to “false” to disable them and avoid conflicts with your own device manager.
Please note there is an additional flag to manually control the LED brightness on the SLI Pro:
<led_display sliProForceBrightness="127" />
This option (using value in the range 0-255) will be ignored when setting the sliProNativeSupport flag to “false”.
Also note it is now possible to edit these values on the fly via the Game Options->Settings->UDP Telemetry Settings menu.
Can I configure the UDP output using an XML File?
PC users can edit the game’s configuration XML file to configure UDP output. The file is located here (after an initial boot of the game):
...\Documents\My Games<game_folder>\hardwaresettings\hardware_settings_config.xml
You should see the tag:
...
<udp enabled="false" broadcast=”false” ip="127.0.0.1" port="20777" sendRate=”20” format=”2023” yourTelemetry="restricted" onlineNames="off" />
...
Here you can set the values manually. Note that any changes made within the game when it is running will overwrite any changes made manually.
#Appendices
Here are the values used for some of the parameters in the UDP data output.
Team IDs
ID | Team | ID | Team | ID | Team |
---|
0 | Mercedes | 106 | Prema ‘21 | 136 | Campos ‘22 |
1 | Ferrari | 107 | Uni-Virtuosi ‘21 | 137 | Van Amersfoort Racing ‘22 |
2 | Red Bull Racing | 108 | Carlin ‘21 | 138 | Trident ‘22 |
3 | Williams | 109 | Hitech ‘21 | 139 | Hitech ‘22 |
4 | Aston Martin | 110 | Art GP ‘21 | 140 | Art GP ‘22 |
5 | Alpine | 111 | MP Motorsport ‘21 | | |
6 | Alpha Tauri | 112 | Charouz ‘21 | | |
7 | Haas | 113 | Dams ‘21 | | |
8 | McLaren | 114 | Campos ‘21 | | |
9 | Alfa Romeo | 115 | BWT ‘21 | | |
85 | Mercedes 2020 | 116 | Trident ‘21 | | |
86 | Ferrari 2020 | 117 | Mercedes AMG GT Black Series | | |
87 | Red Bull 2020 | 118 | Mercedes ‘22 | | |
88 | Williams 2020 | 119 | Ferrari ‘22 | | |
89 | Racing Point 2020 | 120 | Red Bull Racing ‘22 | | |
90 | Renault 2020 | 121 | Williams ‘22 | | |
91 | Alpha Tauri 2020 | 122 | Aston Martin ‘22 | | |
92 | Haas 2020 | 123 | Alpine ‘22 | | |
93 | McLaren 2020 | 124 | Alpha Tauri ‘22 | | |
94 | Alfa Romeo 2020 | 125 | Haas ‘22 | | |
95 | Aston Martin DB11 V12 | 126 | McLaren ‘22 | | |
96 | Aston Martin Vantage F1 Edition | 127 | Alfa Romeo ‘22 | | |
97 | Aston Martin Vantage Safety Car | 128 | Konnersport ‘22 | | |
98 | Ferrari F8 Tributo | 129 | Konnersport | | |
99 | Ferrari Roma | 130 | Prema ‘22 | | |
100 | McLaren 720S | 131 | Virtuosi ‘22 | | |
101 | McLaren Artura | 132 | Carlin ‘22 | | |
102 | Mercedes AMG GT Black Series Safety Car | 133 | MP Motorsport ‘22 | | |
103 | Mercedes AMG GTR Pro | 134 | Charouz ‘22 | | |
104 | F1 Custom Team | 135 | Dams ‘22 | | |
Driver IDs
ID | Driver | ID | Driver | ID | Driver |
---|
0 | Carlos Sainz | 56 | Louis Delétraz | 115 | Theo Pourchaire |
1 | Daniil Kvyat | 57 | Antonio Fuoco | 116 | Richard Verschoor |
2 | Daniel Ricciardo | 58 | Charles Leclerc | 117 | Lirim Zendeli |
3 | Fernando Alonso | 59 | Pierre Gasly | 118 | David Beckmann |
4 | Felipe Massa | 62 | Alexander Albon | 121 | Alessio Deledda |
6 | Kimi Räikkönen | 63 | Nicholas Latifi | 122 | Bent Viscaal |
7 | Lewis Hamilton | 64 | Dorian Boccolacci | 123 | Enzo Fittipaldi |
9 | Max Verstappen | 65 | Niko Kari | 125 | Mark Webber |
10 | Nico Hulkenburg | 66 | Roberto Merhi | 126 | Jacques Villeneuve |
11 | Kevin Magnussen | 67 | Arjun Maini | 127 | Callie Mayer |
12 | Romain Grosjean | 68 | Alessio Lorandi | 128 | Noah Bell |
13 | Sebastian Vettel | 69 | Ruben Meijer | 129 | Jake Hughes |
14 | Sergio Perez | 70 | Rashid Nair | 130 | Frederik Vesti |
15 | Valtteri Bottas | 71 | Jack Tremblay | 131 | Olli Caldwell |
17 | Esteban Ocon | 72 | Devon Butler | 132 | Logan Sargeant |
19 | Lance Stroll | 73 | Lukas Weber | 133 | Cem Bolukbasi |
20 | Arron Barnes | 74 | Antonio Giovinazzi | 134 | Ayumu Iwasa |
21 | Martin Giles | 75 | Robert Kubica | 135 | Clement Novalak |
22 | Alex Murray | 76 | Alain Prost | 136 | Jack Doohan |
23 | Lucas Roth | 77 | Ayrton Senna | 137 | Amaury Cordeel |
24 | Igor Correia | 78 | Nobuharu Matsushita | 138 | Dennis Hauger |
25 | Sophie Levasseur | 79 | Nikita Mazepin | 139 | Calan Williams |
26 | Jonas Schiffer | 80 | Guanya Zhou | 140 | Jamie Chadwick |
27 | Alain Forest | 81 | Mick Schumacher | 141 | Kamui Kobayashi |
28 | Jay Letourneau | 82 | Callum Ilott | 142 | Pastor Maldonado |
29 | Esto Saari | 83 | Juan Manuel Correa | 143 | Mika Hakkinen |
30 | Yasar Atiyeh | 84 | Jordan King | 144 | Nigel Mansell |
31 | Callisto Calabresi | 85 | Mahaveer Raghunathan | | |
32 | Naota Izum | 86 | Tatiana Calderon | | |
33 | Howard Clarke | 87 | Anthoine Hubert | | |
34 | Wilheim Kaufmann | 88 | Guiliano Alesi | | |
35 | Marie Laursen | 89 | Ralph Boschung | | |
36 | Flavio Nieves | 90 | Michael Schumacher | | |
37 | Peter Belousov | 91 | Dan Ticktum | | |
38 | Klimek Michalski | 92 | Marcus Armstrong | | |
39 | Santiago Moreno | 93 | Christian Lundgaard | | |
40 | Benjamin Coppens | 94 | Yuki Tsunoda | | |
41 | Noah Visser | 95 | Jehan Daruvala | | |
42 | Gert Waldmuller | 96 | Gulherme Samaia | | |
43 | Julian Quesada | 97 | Pedro Piquet | | |
44 | Daniel Jones | 98 | Felipe Drugovich | | |
45 | Artem Markelov | 99 | Robert Schwartzman | | |
46 | Tadasuke Makino | 100 | Roy Nissany | | |
47 | Sean Gelael | 101 | Marino Sato | | |
48 | Nyck De Vries | 102 | Aidan Jackson | | |
49 | Jack Aitken | 103 | Casper Akkerman | | |
50 | George Russell | 109 | Jenson Button | | |
51 | Maximilian Günther | 110 | David Coulthard | | |
52 | Nirei Fukuzumi | 111 | Nico Rosberg | | |
53 | Luca Ghiotto | 112 | Oscar Piastri | | |
54 | Lando Norris | 113 | Liam Lawson | | |
55 | Sérgio Sette Câmara | 114 | Juri Vips | | |
Track IDs
ID | Track |
---|
0 | Melbourne |
1 | Paul Ricard |
2 | Shanghai |
3 | Sakhir (Bahrain) |
4 | Catalunya |
5 | Monaco |
6 | Montreal |
7 | Silverstone |
8 | Hockenheim |
9 | Hungaroring |
10 | Spa |
11 | Monza |
12 | Singapore |
13 | Suzuka |
14 | Abu Dhabi |
15 | Texas |
16 | Brazil |
17 | Austria |
18 | Sochi |
19 | Mexico |
20 | Baku (Azerbaijan) |
21 | Sakhir Short |
22 | Silverstone Short |
23 | Texas Short |
24 | Suzuka Short |
25 | Hanoi |
26 | Zandvoort |
27 | Imola |
28 | Portimão |
29 | Jeddah |
30 | Miami |
31 | Las Vegas |
32 | Losail |
Nationality IDs
ID | Nationality | ID | Nationality | ID | Nationality |
---|
1 | American | 31 | Greek | 61 | Paraguayan |
2 | Argentinean | 32 | Guatemalan | 62 | Peruvian |
3 | Australian | 33 | Honduran | 63 | Polish |
4 | Austrian | 34 | Hong Konger | 64 | Portuguese |
5 | Azerbaijani | 35 | Hungarian | 65 | Qatari |
6 | Bahraini | 36 | Icelander | 66 | Romanian |
7 | Belgian | 37 | Indian | 67 | Russian |
8 | Bolivian | 38 | Indonesian | 68 | Salvadoran |
9 | Brazilian | 39 | Irish | 69 | Saudi |
10 | British | 40 | Israeli | 70 | Scottish |
11 | Bulgarian | 41 | Italian | 71 | Serbian |
12 | Cameroonian | 42 | Jamaican | 72 | Singaporean |
13 | Canadian | 43 | Japanese | 73 | Slovakian |
14 | Chilean | 44 | Jordanian | 74 | Slovenian |
15 | Chinese | 45 | Kuwaiti | 75 | South Korean |
16 | Colombian | 46 | Latvian | 76 | South African |
17 | Costa Rican | 47 | Lebanese | 77 | Spanish |
18 | Croatian | 48 | Lithuanian | 78 | Swedish |
19 | Cypriot | 49 | Luxembourger | 79 | Swiss |
20 | Czech | 50 | Malaysian | 80 | Thai |
21 | Danish | 51 | Maltese | 81 | Turkish |
22 | Dutch | 52 | Mexican | 82 | Uruguayan |
23 | Ecuadorian | 53 | Monegasque | 83 | Ukrainian |
24 | English | 54 | New Zealander | 84 | Venezuelan |
25 | Emirian | 55 | Nicaraguan | 85 | Barbadian |
26 | Estonian | 56 | Northern Irish | 86 | Welsh |
27 | Finnish | 57 | Norwegian | 87 | Vietnamese |
28 | French | 58 | Omani | | |
29 | German | 59 | Pakistani | | |
30 | Ghanaian | 60 | Panamanian | | |
Game Mode IDs
ID | Mode |
---|
0 | Event Mode |
3 | Grand Prix |
4 | Grand Prix ‘23 |
5 | Time Trial |
6 | Splitscreen |
7 | Online Custom |
8 | Online League |
11 | Career Invitational |
12 | Championship Invitational |
13 | Championship |
14 | Online Championship |
15 | Online Weekly Event |
17 | Story Mode |
19 | Career ‘22 |
20 | Career ’22 Online |
21 | Career ‘23 |
22 | Career ’23 Online |
127 | Benchmark |
Ruleset IDs
ID | Ruleset |
---|
0 | Practice & Qualifying |
1 | Race |
2 | Time Trial |
4 | Time Attack |
6 | Checkpoint Challenge |
8 | Autocross |
9 | Drift |
10 | Average Speed Zone |
11 | Rival Duel |
Surface types
These types are from physics data and show what type of contact each wheel is experiencing.
ID | Surface |
---|
0 | Tarmac |
1 | Rumble strip |
2 | Concrete |
3 | Rock |
4 | Gravel |
5 | Mud |
6 | Sand |
7 | Grass |
8 | Water |
9 | Cobblestone |
10 | Metal |
11 | Ridged |
Button flags
These flags are used in the telemetry packet to determine if any buttons are being held on the controlling device. If the value below logical ANDed with the button status is set then the corresponding button is being held.
Bit Flag | Button |
---|
0x00000001 | Cross or A |
0x00000002 | Triangle or Y |
0x00000004 | Circle or B |
0x00000008 | Square or X |
0x00000010 | D-pad Left |
0x00000020 | D-pad Right |
0x00000040 | D-pad Up |
0x00000080 | D-pad Down |
0x00000100 | Options or Menu |
0x00000200 | L1 or LB |
0x00000400 | R1 or RB |
0x00000800 | L2 or LT |
0x00001000 | R2 or RT |
0x00002000 | Left Stick Click |
0x00004000 | Right Stick Click |
0x00008000 | Right Stick Left |
0x00010000 | Right Stick Right |
0x00020000 | Right Stick Up |
0x00040000 | Right Stick Down |
0x00080000 | Special |
0x00100000 | UDP Action 1 |
0x00200000 | UDP Action 2 |
0x00400000 | UDP Action 3 |
0x00800000 | UDP Action 4 |
0x01000000 | UDP Action 5 |
0x02000000 | UDP Action 6 |
0x04000000 | UDP Action 7 |
0x08000000 | UDP Action 8 |
0x10000000 | UDP Action 9 |
0x20000000 | UDP Action 10 |
0x40000000 | UDP Action 11 |
0x80000000 | UDP Action 12 |
Penalty types
ID | Penalty meaning |
---|
0 | Drive through |
1 | Stop Go |
2 | Grid penalty |
3 | Penalty reminder |
4 | Time penalty |
5 | Warning |
6 | Disqualified |
7 | Removed from formation lap |
8 | Parked too long timer |
9 | Tyre regulations |
10 | This lap invalidated |
11 | This and next lap invalidated |
12 | This lap invalidated without reason |
13 | This and next lap invalidated without reason |
14 | This and previous lap invalidated |
15 | This and previous lap invalidated without reason |
16 | Retired |
17 | Black flag timer |
Infringement types
ID | Infringement meaning |
---|
0 | Blocking by slow driving |
1 | Blocking by wrong way driving |
2 | Reversing off the start line |
3 | Big Collision |
4 | Small Collision |
5 | Collision failed to hand back position single |
6 | Collision failed to hand back position multiple |
7 | Corner cutting gained time |
8 | Corner cutting overtake single |
9 | Corner cutting overtake multiple |
10 | Crossed pit exit lane |
11 | Ignoring blue flags |
12 | Ignoring yellow flags |
13 | Ignoring drive through |
14 | Too many drive throughs |
15 | Drive through reminder serve within n laps |
16 | Drive through reminder serve this lap |
17 | Pit lane speeding |
18 | Parked for too long |
19 | Ignoring tyre regulations |
20 | Too many penalties |
21 | Multiple warnings |
22 | Approaching disqualification |
23 | Tyre regulations select single |
24 | Tyre regulations select multiple |
25 | Lap invalidated corner cutting |
26 | Lap invalidated running wide |
27 | Corner cutting ran wide gained time minor |
28 | Corner cutting ran wide gained time significant |
29 | Corner cutting ran wide gained time extreme |
30 | Lap invalidated wall riding |
31 | Lap invalidated flashback used |
32 | Lap invalidated reset to track |
33 | Blocking the pitlane |
34 | Jump start |
35 | Safety car to car collision |
36 | Safety car illegal overtake |
37 | Safety car exceeding allowed pace |
38 | Virtual safety car exceeding allowed pace |
39 | Formation lap below allowed speed |
40 | Formation lap parking |
41 | Retired mechanical failure |
42 | Retired terminally damaged |
43 | Safety car falling too far back |
44 | Black flag timer |
45 | Unserved stop go penalty |
46 | Unserved drive through penalty |
47 | Engine component change |
48 | Gearbox change |
49 | Parc Fermé change |
50 | League grid penalty |
51 | Retry penalty |
52 | Illegal time gain |
53 | Mandatory pitstop |
54 | Attribute assigned |
Legal Notice
F1® 23 Game - an official product of the FIA Formula One World Championship™.
The F1 Formula 1 logo, F1 logo, Formula 1, F1, FIA FORMULA ONE WORLD CHAMPIONSHIP, GRAND PRIX and related marks are trademarks of Formula One Licensing BV, a Formula 1 company. © 2023 Cover images Formula One World Championship Limited, a Formula 1 company. Licensed by Formula One World Championship Limited. The F2 FIA Formula 2 CHAMPIONSHIP logo, FIA Formula 2 CHAMPIONSHIP, FIA Formula 2, Formula 2, F2 and related marks are trademarks of the Federation Internationale de l’Automobile and used exclusively under licence. All rights reserved. The FIA and FIA AfRS logos are trademarks of Federation Internationale de l’Automobile. All rights reserved.
---===END OF DOCUMENT===---