Arkanoid controller

From Nesdev wiki
Jump to: navigation, search

The Arkanoid Vaus controller was included with the Arkanoid game, and is only used for this game and Chase HQ. It has an control knob connected to a potentiometer and a single fire button. Under a small black plastic cover is another potentiometer to adjust the control knob's range.

            ,--------------------------------------.   |
            |                  %%                  |   |
            |   ,---.          %%                % |   |
            |  /     \         %%         ,-.   %% |   |
 Control  ->| |       |        %%        (   )  %% |<- Fire button
   knob     |  \     /         %%         `-'   %% |   |    
            |   `---'          %%                % |==/
Adjustment->|     ()           %%                  |
   screw    `--------------------------------------'

The Famicom version of this controller uses D1 (Famicom) on both ports. The NES version uses D3 and D4, usually in port 2 ($4017). The controller will not work in a Four Score.

Input ($4016 write)

7  bit  0
---- ----
xxxx xxCC
       |+- NES: Start ADC
       +-- Famicom: Start ADC

When the relevant bit of C goes from 0 to 1, a conversion is started. Leaving C at 1 will negatively shift the ADC result proportionate to the amount of time it remains. After the conversion is completed, the shift register is automatically loaded with the results of the ADC.

The analog to digital conversion takes about 7 ms, so strobing too fast will return bad data, especially at the right side of the range. A function that reads the controller multiple times in a row to avoid DPCM glitches may not work. Instead, check for spurious accelerations, where the second difference xt - 2xt - 1 + xt - 2 exceeds about eight units.

Output ($4016/$4017 read)


7  bit  0
---- ----
xxxx xxBx
       +-- Fire button (1: pressed)

7  bit  0
---- ----
xxxx xxDx
       +-- Serial control knob data


7  bit  0
---- ----
xxxD Bxxx
   | |
   | +---- Fire button (1: pressed)
   +------ Serial control knob data

Button status is returned in D3, and does not need to be latched. However, making sure it reads the same way eight times is a good way to distinguish it from a Power Pad, and reading it several times during a frame should distinguish it from the light sensor of a Zapper.

Control knob data is returned in D4, MSB first. The data is also inverted. The whole range is about 180 degrees, and returned in $A0 steps.

Variations in the analog to digital and pot physical range can vary the result slightly. With the trim pot at minimum the range returned is $0D-$AD. With the trim pot at maximum the range returned is $5C-$FC.

The Arkanoid game expects the range to be $54-$F4; the manual explains how to adjust the trimpot. New games can work at any trim pot setting by storing the maximum and minimum values seen during a play session and assuming values within ±80 units of the center of this range.

Test ROMs

  • Vaus Test shows adaptation to trimpot setting, repeated read rate, and first and second differences