Jump to content

D-Box and UDP Telemetry Information

Recommended Posts

JuanCarMR said:
Which is the name of the new app??? is it for IOS?

More info please, screenshots too!!!
Its not released yet, it will be called RS Dash. I cant release until i have approval or otherwise from CodeMasters re the logo as i do this for a hobby so a trademark infringement issue is the last thing i want. Hopefully i get an answer from Hoo, or at least get pointed to the right person regarding my query.

Share this post


Link to post
Share on other sites
@Hoo, another question, is it possible to change the rate of the telemetry output? it seems to be around 75Hz at the moment, its a bit quick for some of the lower end devices which could struggle to keep up with processing that + rendering at a high enough frame rate.

Share this post


Link to post
Share on other sites
Hi cjorgens79 using the actual F1 logo and Formula 1® would be a very bad idea. Those are Formula One trademarks that we use under license so we cannot give you permission to use those. I would suggest you make any logo as generic as possible and try not to include any trademarks etc. Sorry I can't be of more help.

Share this post


Link to post
Share on other sites
Lozzy said:
Hi cjorgens79 using the actual F1 logo and Formula 1® would be a very bad idea. Those are Formula One trademarks that we use under license so we cannot give you permission to use those. I would suggest you make any logo as generic as possible and try not to include any trademarks etc. Sorry I can't be of more help.

Hi Lozzy, thanks for the info, i suspected that would probably be the case but i figured it was work asking anyway. Is there any chance i can use the Codemasters logo so it could just have your logo with "Codemaster F1 2016" written below it? Im also happy to put a notice stating that i am in no way affiliated with CodeMasters etc if required. If not thats understandable too, but i figure i should at least ask. 
Cheers

Share this post


Link to post
Share on other sites
cjorgens79 said:j
@Hoo - I am the developer of the pCars Dash app for Project Cars. A number of my users have asked if i can interface to F1 2016, so i have created a new app based on my pCars Dash app that works with F1 2016 using the UDP feed you have documented above. This app also supports a couple of other racing titles (RaceRoom and Assetto Corsa). When using the app the user needs to click a tile to indicate which application they want to link to, for those apps i have their game logo and name, i would like to ask permission to use the F1 2016 logo as well for this interface. I would be using it on a tile that would look like this. 


If this is not acceptable, could you please provide a logo that I can use, or indicate that I should not use any logos at all for the interface to F1 2016.

Thanks,
Craig

Share this post


Link to post
Share on other sites
If you use F1 2016 you are referring to the game, so FOM shouldn't have an issue with it. If you however use just F1, then you would need to use the TM and maybe have to ask permission to FOM.

Share this post


Link to post
Share on other sites
We have continued the discussion in private but these logos are trademarks / registered and should not be used without the express permission of the company who owns them. Without that permission you're at risk of legal action so my best advice as an individual applying common sense is not to use any logo that is not owned by you or is free to use.

Share this post


Link to post
Share on other sites
@Hoo - I have had reports from one of my testers who is using XBox1 that the IP address for the UDP settings resets each time the game is restarted. Is this something that can be fixed?

Also there is a problem with the PC interface whereby if you start F1 2016 first before running any apps that use the interface on the same PC, those apps are unable to access the UDP port. The most likely cause is that when F1 2016 starts, it opens the same UDP port without the "reuse address" flag enabled which means it locks the port. It can be gotten around by opening the 3rd party apps first (so they grab the port first) then starting F1 2016. At that point it may be binding to a different port or possibly getting shared access to the 20777 port. It would be nice if they could fix this so that it doesnt cause problems for users of 3rd party interfaces linking to this telemetry on PC.

Cheers

Share this post


Link to post
Share on other sites
I've always had your app for project cars , still a great game ,and it took time for team and updates to get it to work ,I need this app for f1 2016 ps4 where and when can I get it ,how much , how soon , I know , too many questions , but I must have it ,lol

Share this post


Link to post
Share on other sites
senn said:
I've always had your app for project cars , still a great game ,and it took time for team and updates to get it to work ,I need this app for f1 2016 ps4 where and when can I get it ,how much , how soon , I know , too many questions , but I must have it ,lol
will be available soon, the app is all done and tested, just need to get it through the apple app approval process for ios and get my new website live as well which has all the setup info on it

Share this post


Link to post
Share on other sites
Hoo said:


UDP Packet Structure
The data is sent as raw data in the UDP packet, converted to a char array. To decode this into something usable it should be a case of casting the packet data back to the UDPPacket struct (or another structure with the same layout). The layout of the UDP data is as follows:


struct UDPPacket
{
    float m_time;
    float m_lapTime;
    float m_lapDistance;
    float m_totalDistance;
    float m_x;      // World space position
    float m_y;      // World space position
    float m_z;      // World space position
    float m_speed;
    float m_xv;      // Velocity in world space
    float m_yv;      // Velocity in world space
    float m_zv;      // Velocity in world space
    float m_xr;      // World space right direction
    float m_yr;      // World space right direction
    float m_zr;      // World space right direction
    float m_xd;      // World space forward direction
    float m_yd;      // World space forward direction
    float m_zd;      // World space forward direction
    float m_susp_pos_bl;
    float m_susp_pos_br;
    float m_susp_pos_fl;
    float m_susp_pos_fr;
    float m_susp_vel_bl;
    float m_susp_vel_br;
    float m_susp_vel_fl;
    float m_susp_vel_fr;
    float m_wheel_speed_bl;
    float m_wheel_speed_br;
    float m_wheel_speed_fl;
    float m_wheel_speed_fr;
    float m_throttle;
    float m_steer;
    float m_brake;
    float m_clutch;
    float m_gear;
    float m_gforce_lat;
    float m_gforce_lon;
    float m_lap;
    float m_engineRate;
    float m_sli_pro_native_support; // SLI Pro support
    float m_car_position;   // car race position
    float m_kers_level;    // kers energy left
    float m_kers_max_level;   // kers maximum energy
    float m_drs;     // 0 = off, 1 = on
    float m_traction_control;  // 0 (off) - 2 (high)
    float m_anti_lock_brakes;  // 0 (off) - 1 (on)
    float m_fuel_in_tank;   // current fuel mass
    float m_fuel_capacity;   // fuel capacity
    float m_in_pits;    // 0 = none, 1 = pitting, 2 = in pit area
    float m_sector;     // 0 = sector1, 1 = sector2; 2 = sector3
    float m_sector1_time;   // time of sector1 (or 0)
    float m_sector2_time;   // time of sector2 (or 0)
    float m_brakes_temp[4];   // brakes temperature (centigrade)
    float m_wheels_pressure[4];  // wheels pressure PSI
    float m_team_info;    // team ID
    float m_total_laps;    // total number of laps in this race
    float m_track_size;    // track size meters
    float m_last_lap_time;   // last lap time
    float m_max_rpm;    // cars max RPM, at which point the rev limiter will kick in
    float m_idle_rpm;    // cars idle RPM
    float m_max_gears;    // maximum number of gears
    float m_sessionType;   // 0 = unknown, 1 = practice, 2 = qualifying, 3 = race
    float m_drsAllowed;    // 0 = not allowed, 1 = allowed, -1 = invalid / unknown
    float m_track_number;   // -1 for unknown, 0-21 for tracks
    float m_vehicleFIAFlags;  // -1 = invalid/unknown, 0 = none, 1 = green, 2 = blue, 3 = yellow, 4 = red
 };

@Hoo
Does this represent the complete physics model - or are these just the variables you are currently exporting?

Thanks

Share this post


Link to post
Share on other sites

@dwin20 - This is just the set of data that we output in this format. If there is any extra data that you want then let us and we'll pass it onto the dev team for their consideration.

Share this post


Link to post
Share on other sites
Please please please... can we have drivers positions in race (name + position) for live coverage streming? :'(

I know... I already asked for this :# o:)

Share this post


Link to post
Share on other sites
Current tyre would be nice - US, SS, S, M, H, I, W

Team ID values
--------------
Red Bull = 0
Ferari = 1
McLaren = 2
Renault = 3
Merc = 4
Sauber = 5
Force India = 6
Williams = 7
Toro Rosso = 8
Haas = 11
Manor = 12

Track values ------------ Australia = 0
Malaysia = 1
China = 2
Bahrain = 3
Spain = 4
Monaco = 5
Canada = 6
Britain = 7
Germany = 8
Hungary = 9
Belgium = 10
Italy = 11
Singapore = 12
Japan = 13
Abu Dhabi = 14
USA = 15
Brazil = 16
Austria = 17
Russia = 18
Mexico = 19
Azerbaijan = 20

Share this post


Link to post
Share on other sites
@Hoo - the session type isn't switching to 3 for the race, at least in quick race mode retiring from qualifying.

Never mind, the session type changes when the lights go out.

Share this post


Link to post
Share on other sites
@Hoo - in terms of the api, the following information (in no particular order) is missing compared to other sim racing interfaces ive linked with
1. Tyre Temperature (everyone else has this, this is the most glaringly obvious missing field)
2. Tyre Compound (R3E and AC have this, pCars and F1 2016 do not)
3. Tyre Wear (pCars and AC have this)
4. Brake bias (R3E has this, very useful to have available in app)
5. Damage (the others all support this to some degree)
6. Fuel Pressure, Water Pressure, Oil pressure (some have this as they simulate this)
7. Water Temp, Oil Temp (some have this as they simulate this)
8. Invalid lap (ie off track) indicator (very important for any app tracking lap times)
9. AI player x/y/z positions (needed for displaying maps with position of all players)
10. AI player race positions (1st, 2nd, 3rd etc) and lap times (needed for leaderboard and live streaming coverage)

The UDP packet structure itself  could really use a revision number and packet size at the front so that interfaces can detect any changes to the api that may occur in future updates. A sequence number could also be helpful as UDP packet order arrival is not guaranteed.

If the developers are going to add some of these things, they must take into account the MTU size to prevent UDP packet fragmentation from occuring, so the packet should not exceed 1500 bytes. The packet size at the moment (from memory) was about 280 bytes, so no problems, however if they add the telemetry from the other competitors then this grows quickly so needs to be considered carefully. F1 2016 has an advantage over the other games though in that the grid size is fixed to 22 cars and the AI opponents names are all known so can be encoded as an enum to save space. Ideally it would be great to have an array of an aiData structure something like the following added 
{
byte m_player_id                   // id of player, eg 0 = player, 1 = hamilton, 2 = rosberg, etc
byte m_car_position             // race position of player, 1st, 2nd, 3rd, etc
byte m_lap_invalid               // is current lap time is invalid (ie off track)
byte m_sector                         // current sector player is in on this lap
byte m_lap                              // current lap number player is on
byte m_in_pits                       // is player in the pits?
float m_lap_distance            // lap distance travelled
float m_x                                 // world space position
float 
m_y                                 // world space position
float m_z
                                 // world space position
float m_lap_time                   // current lap time
float m_last_lap_time          // last lap time
float m_best_lap_time         // session best lap time (needed for qualifying leaderboards when app is started midway through session)
float m_sector1_time           // current sector 1 time
float m_sector2_time           // current sector 2 time
}
Structure packing would need to be considered so some of those byte fields could be combined into a single byte as the values wouldnt use all the available bits. eg m_lap_invalidated and m_in_pits only need 1 bit each. m_lap_distance could probably be reduced to 16 bit too if needed. 

You could also technically drop the two sector times and the last lap time fields if  packet space was needed and instead just have a last sector time as the apps could still calculate what they need using just that. 

Using my bloated example AI structure above for 22 opponents plus adding the other fields at the top of my list would result in a packet size of approx 1184 bytes, still reasonably well under the 1500 byte limit.

The above is pretty much everything that i have available to me currently in my pCars Dash app from the Project Cars telemetry stream and it has proven to be very popular among the players, providing them with another dimension to the racing which has kept them engaged in the game longer. Hopefully you will consider adding the above to the api as companions apps do help the game retain its players for longer.

Thanks
Craig
Pocket Playground
www.pocketplayground.net
Home of pCars Dash for Project CARS and RS-Dash for F1 2016, RaceRoom Racing Experience and Assetto Corsa.

Share this post


Link to post
Share on other sites
@cjorgens79 - First - this is a terrific post! Helpful detail that can really help the Codemaster team to make the third party telemetry efforts significantly better - and as a result make F1 2016 better. 

BTW - in your app is there a way in the telemetry section to see the track map as well as the graphs?

Thanks 

Share this post


Link to post
Share on other sites
dwin20 said:
@cjorgens79 - First - this is a terrific post! Helpful detail that can really help the Codemaster team to make the third party telemetry efforts significantly better - and as a result make F1 2016 better. 

BTW - in your app is there a way in the telemetry section to see the track map as well as the graphs?

Thanks 
Thanks. The track map is not currently available, but i am in the process of creating all the track maps so it wont be too far away to being added to the app. Keep in mind that the f1 2016 udp telemetry only has the current players positions so the track map will only be useful to see yourself one the track and upcoming corners, you wont be able to use it to see the position of other competitors until (hopefully) they add this information to the api.

Share this post


Link to post
Share on other sites
@cjorgens79 the problem is that if you download for iPhone, you must paid to use in an iPad as well.  :( 

Share this post


Link to post
Share on other sites
JuanCarMR said:
@cjorgens79 the problem is that if you download for iPhone, you must paid to use in an iPad as well.  :( 
No you shouldn't have to if you are logged into the app store with the same account. Click on the cog in the bottom left and then click the "Restore Purchases" button and it should unlock anything you have previously purchased.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×