ECU Input: Throttle Angle Sensor
The throttle angle sensor is another key input sensor. This sensor measures how far open the throttle is. The picture below shows the throttle body removed from the bike, sitting upside down so you can see the closed throttle plate inside the two openings on the top.
The throttle angle sensor is the black plastic unit on the left side with the silver front. Notice that it is right in line with the throttle butterfly shaft so that when the shaft rotates to open the butterfly valve, the end of the throttle shaft also rotates the sensing element.
The throttle angle sensor is a simple potentiometer (a variable resistor), much like the volume control knob on a stereo. The input to the sensor is a regulated sensor supply voltage supply of 5.0 volts. The output of the sensor is a variable voltage that corresponds to how far open the throttle is. The ECU reads the voltage using its analog to digital converter.
One interesting note from reading the software is that while the ECU processor hardware supports 10 bits of resolution in its analog to digital conversions, the ECU software throws away the two least-significant bits, effectively performing an 8-bit conversion. This means that the ECU processor can only resolve 28 or 256 different throttle positions. If the throttle moves through 90 degrees from full shut to wide open, it means that in theory, the ECU can detect the position of the throttle to a resolution of 90/256 or about a third of a degree. In practice, the resolution is a bit less than this because ECU purposely does not use the full range of sensor output. This is to say, the lowest voltage that it could possible put out is a bit more than 0 volts, and the highest voltage it could possible put out is a bit less that 5.0 volts. It is as though Aprilia designed a stereo volume control that could neither go fully quiet nor fully loud. For a stereo, this would be a bad idea. For a throttle position sensor, this turns out to be a fine idea.
If you think about it for a minute, you will figure out that by not utilizing the full range of the sensor output, it is easy to detect two very common sensor failure modes. For variable resistor devices, two very common failure modes are that they either short circuit (zero resistance) or that they go open (infinite resistance). Depending on exactly how they fail (short or open), the output will be stuck at either the maximum or the minimum possible voltage. By utilizing less than the entire possible range of output, the ECU should never see either a maximum or minimum voltage output from the sensor. If it does, the ECU knows that the sensor is either open or shorted. Either way, the ECU knows that the sensor is broken and can start flashing the "EFI" warning light on the dashboard.
An implication of this method of failure detection is that if the ECU is using a zero volt output to indicate a broken sensor, then some other small, but non-zero needs to serve as the 'throttle completely closed' voltage level. The obvious questions would be: what is this voltage, and how does the ECU calibrate it? Fortunately, the answers are built right into the ECU software with the help of the DIAG wire.