Arkanoid controller: Difference between revisions

From NESdev Wiki
Jump to navigationJump to search
(Chase HQ supports this according to wikipedia)
(Second difference for DPCM glitches; test ROM; correct range based on my specimen; correct title of controls per Arkanoid manual; link to test ROM)
Line 1: Line 1:
The Arkanoid Vaus controller was included with the ''Arkanoid'' game, and is only used for this game and ''Chase HQ''. It has an analog potentiometer dial and a single button.
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 the black rubber dot is another potentiometer to adjust the dial range.
Under the black rubber dot is another potentiometer to adjust the control knob's range.


The controller uses D3 and D4 so it will not work in a [[Four score]].
The controller uses D3 and D4 so it will not work in a [[Four score]].
Line 11: Line 11:
  xxxx xxxS
  xxxx xxxS
         |
         |
         +- Dial shift register strobe
         +- Control knob shift register strobe


Writing 1 to this bit will record the state of the dial.
Writing 1 to this bit will record the state of the control knob.
Writing 0 afterwards will allow the dial to be read back.
Writing 0 afterwards will allow the dial to be read back.


The analog to digital conversion takes time so strobing too fast will return bad dial data.  A function that reads the controller multiple times in a row to avoid DPCM glitches may not work.
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 [[wikipedia:finite difference|second difference]] ''x''<sub>''t''</sub> - 2''x''<sub>''t'' - 1</sub> + ''x''<sub>''t'' - 2</sub> exceeds about eight units.


=== Output ($4016/$4017 read) ===
=== Output ($4016/$4017 read) ===
Line 24: Line 24:
  xxxD Bxxx
  xxxD Bxxx
     | |
     | |
     | +---- Button
     | +---- Fire button (1: pressed)
     +------ Serial dial data
     +------ Serial control knob data
      
      
Button status is returned in D3, and does not need to be latched.  Button is 1 if pressed, 0 if not pressed.
Button status is returned in D3, and does not need to be latched.


Dial data is returned in D4, MSB first.  The data is also inverted.  The whole dial range is about 270 degrees, and returned in $A0 steps.
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.
Variations in the analog to digital and pot physical range can vary the result slightly.
Line 35: Line 35:
With the trim pot at maximum the range returned is $5C-$FC.
With the trim pot at maximum the range returned is $5C-$FC.


The Arkanoid game expects the range to be $54-$F4.
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 &plusmn;80 units of the center of this range.
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 &plusmn;80 units of the center of this range.
== Test ROMs ==
*[//pineight.com/nes/#vaus Vaus Test] shows adaptation to trimpot setting, repeated read rate, and first and second differences
[[Category:Controllers]]
[[Category:Controllers]]

Revision as of 23:38, 26 November 2013

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 the black rubber dot is another potentiometer to adjust the control knob's range.

The controller uses D3 and D4 so it will not work in a Four score.

Input ($4016 write)

7  bit  0
---- ----
xxxx xxxS
        |
        +- Control knob shift register strobe

Writing 1 to this bit will record the state of the control knob. Writing 0 afterwards will allow the dial to be read back.

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
---- ----
xxxD Bxxx
   | |
   | +---- Fire button (1: pressed)
   +------ Serial control knob data
   

Button status is returned in D3, and does not need to be latched.

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