Interfacing the SEGA MODEL 3 Drive board
A- INTRODUCTION
This page explained how a SEGA Daytona USA 2 PCB communicate with their drive board to generate force feedback.
Once all sequences known, I start to drive the board with an Arduino rather than the SEGA PCB. Then I will able to interface the SEGA Model 3 FFB wheel with a PC.
I use 838-13481 drive boards, as DAYTONA USA 2 or SUPER GT (SCUD RACE) games. The following tips don’t work with MIDI (JVS) drive boards or SEGA Rally 2 Drive boards.
B- COMMAND
SEGA Model 3 PCB used a parallel communication (8 bits, one way bus) to communicate with the drive board. 9 pins are used, 8 data + ground. Data level is 5V.
Drive board do not return acknowledgment to the SEGA Model 3 PCB. So the Drive board -> Model 3 wiring is not really used, excepted in test mode.
A simple CENTRONIX parallel port could be used to replace the Model 3 PCB. Personally, I used an Arduino MEGA (the Arduino Uno haven’t port to address full byte) to send data.
Model 3 send one byte commands to the drive board, one after one. Commands are used to:
- Initialize drive board
- Enable/disable FFB effects
- Test the board
List of commands:
COMMANDS |
||
0x |
Play sequence /* TODO */ |
In game effect command |
1x |
Set centering strength - auto-centering – SendSelfCenter 0x10: Disable – 0x11 = weakest – 0x1F = strongest |
In game effect command |
2x |
Friction strength – SendFriction 0x20: Disable - 0x21 = weakest - 0x2F = strongest |
In game effect command |
3x |
Uncentering (vibrate)- SendVibrate 0x30: Disable - 0x31 = weakest - 0x3F = strongest |
In game effect command |
4x |
Play power-slide sequence/* TODO */ |
In game effect command |
5x |
Rotate wheel right – SendConstantForce (+) 0x50: Disable - 0x51 = weakest - 0x5F = strongest |
In game effect command |
6x |
Rotate wheel left - SendConstantForce(-) 0x60: Disable - 0x61 = weakest - 0x6F = strongest |
In game effect command |
7x |
Set steering parameters 0x70 : set general power : 50% 0x71 : set general power : 60% 0x72 : set general power : 70% 0x73 : set general power : 80% 0x74 : set general power : 90% 0x75 : set general power : 100% |
Initialization command |
8x |
Test Mode 0x80 Stop motor SendStopAll 0x81: Roll wheel right - SendConstantForce(+) 0x82: Roll wheel left - SendConstantForce(-) 0x83: Clutch on 0x84: Clutch off 0x85: Set wheel center position 0x86: Set cockpit banking position 0x87: Lamp on/off |
Test mode command |
9x |
Don't appear to have any effect with Scud Race ROM |
|
Ax |
Don't appear to have any effect with Scud Race ROM |
|
Bx |
Invalid command (reserved for use by PPC to send cabinet type 0xB0 or 0xB1 during initialization) /* Ignore */ |
Initialization command |
Cx |
Set board mode 0xCB: reset board - SendStopAll >0xCB Reset board |
Initialization command |
Dx |
Set read mode |
Initialization command |
Ex |
Invalid command |
|
Fx |
Echo test |
Initialization command |
An effect command is composed by 2 quartets:
- Effect: 4bits format - MSB
- Force: 4 bits format – LSB
By example, send 0x12 (effect 1, force 2) to the drive board will make centering the wheel smoothly.
C- DATA SEQUENCES
Initialization – Power ON
At Power ON, the drive board need to be initializing. The following sequence is send:
The Model 3 keep the 0xC1 value until a game start or entering the test menu.
In game – Start button pressed
There are persistent and non persistent effect commands.
Persistent one are activate by a short (50ms) command and stay alive until a “Disable” command is sent.
Non persistent effect take end when the command stop to be send.
Test Mode – Test button pressed
To exit the test mode, initialize the board again.
D- WIRING
E- CODE SAMPLE
This is an Arduino MEGA 2560 sample code. It activated the auto-centering of the Model 3 wheel, usefull if you connect the wheel to your xbox with a hackpad.
// Drive board connected to the arduino MEGA 2560 Port A
// Pin 13 LED blinked
int led = 13;
void setup() {
// initialize digital pins as an output
pinMode(led, OUTPUT);
DDRA = 0xFF;
digitalWrite(led, LOW);
// Drive board Initialization
// --------------------------
PORTA = 0xFF;delay(3500);
PORTA = 0x00;delay(3000);
PORTA = 0xCB;delay(1700); //Reset board
PORTA = 0x7E;delay(50);
PORTA = 0x80;delay(100);
PORTA = 0xB1; delay(800);
PORTA = 0xC1; delay(500);
//Board initialized
// Start button pushed game init
// --------------------------
PORTA = 0xC2;delay(50);
PORTA = 0xC4;delay(3000); //Race+car selection screens
PORTA = 0x75; delay(170); //FORCE = 0x70=50% 0x71=60% 0x72=70% 0x73=80% 0x74=90% 0x75=100% originaly set in the test menu
PORTA = 0xC6;delay(3000);
PORTA = 0xC7;delay(50);
PORTA = 0x00;delay(140);
PORTA = 0x0C;delay(15);
//game initialized
// Game start Gentlemen starts your engines
// ----------------------------------------
PORTA = 0x12; //Effect: auto centering low force
}
// Blink the led
void loop() {
digitalWrite(led, LOW); delay(100);
digitalWrite(led, HIGH); delay(100);
}
F- RECOMPIL MODEL 3 EMULATOR
Work in progress… will be available in 2014.
G- BUILT A DIRECTX FFB DRIVER
Looking for a Direct Input MCU sample code…