TSW throttle controller

I am creating a game controller for train sim world, I have a mod that allows other controllers and i have verified that it works. I have assembled an Arduino Uno with a potentiometer and I have some code that will read the potentiometer. Now all I need to do is create some code for the computer to recognise and read it correctly, however I have no clue how to do that, can anyone help?

Edit:
Current Code:

// the setup routine runs once when you press reset:
void setup() {
  // initialize serial communication at 9600 bits per second:
  Serial.begin(9600);

}

// the loop routine runs over and over again forever:
void loop() {
  // read the input on analog pin 0:
  int sensorValue = analogRead(A0);
  // print out the value you read:
  Serial.println(sensorValue);

  delay(1);  // delay in between reads for stability
}

what kind of contoller does Train Sim World use?

I have a mod that will allow you to assign controllers to some inputs, other than that, tsw only supports keyboard/mouse, ps controller, xbox controller