I know that with the R32 it used three G-sensors, two measure longitudinal acceleration (ie acceleration and braking) and the other measures lateral acceleration (ie cornering).
As cheftrd was saying i think it also uses TPS and some sort of ABS sensor. These all get feed into the 4WD computer to determine the torque to the front wheels.