Python Forum
How do I emulate a Forza telemetry server and a Bluetooth OBD device?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How do I emulate a Forza telemetry server and a Bluetooth OBD device?
#1
I'm making a driving game in Pygame, and want to give a player the option to send game data to a Forza compatible dashboard app or to an OBD app like RevHeadz. How do I do so?
Reply
#2
Hello, here are a few things you would need to do to emulate a Forza telemetry server or Bluetooth OBD device from a Pygame driving game. Hope that they are useful for you. geometry dash lite

For Forza Telemetry Server:
1. Research the Forza Motorsport telemetry format and data streams. Forza broadcasts telemetry data like speed, RPM, gear, steering angle, etc over UDP.

2. Set up your Pygame game to track all the relevant telemetry data as the player drives. Things like speed, RPM, gear position, accelerator/brake position, steering angle, etc.

3. Implement a UDP server in Python that listens on the ports Forza uses (usually 20777 or 20780).

4. Have the UDP server broadcast the current telemetry data from your game in the correct Forza format at a consistent rate, like 30 times per second.

For Bluetooth OBD Emulator:

1. Look up the OBD-II SAE J1850 and ISO 15765-4 protocols. These define the commands and responses for OBD data.

2. Emulator needs to support basic PID/parameter requests like engine RPM, vehicle speed, temperature, etc.

3. Implement a Bluetooth server that advertises the OBD service and accepts connections.

4. When a client connects and requests data, translate relevant game metrics like RPM to an OBD response and send over Bluetooth.
Larz60+ write Sep-13-2023, 10:19 PM:
removed hidden url
Please be aware that this is against forum rules
Reply
#3
I was suggested to Look up the Obd-II SAE J1850 and ISO 15765-4 protocols. They define commands and responses to OBD data. But when I started implementing it, I encountered many problems that were difficult to achieve as expected. I'm still struggling with it
Larz60+ write Nov-10-2023, 10:06 AM:
spam link removed
Reply
#4
Following setting up contact between the Forza-compatible dashboard app and the OBD app, it is important to test the integration fully. Make sure that the data is being sent properly and that the external apps are showing or using it correctly.
Larz60+ write Dec-21-2023, 05:49 PM:
Spam link removed.
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020