Welcome, Guest. Please login or register.

Author Topic: Kickflash OS4 problems  (Read 2440 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Piru

  • \' union select name,pwd--
  • Hero Member
  • *****
  • Join Date: Aug 2002
  • Posts: 6946
    • Show all replies
    • http://www.iki.fi/sintonen/
Re: Kickflash OS4 problems
« on: April 08, 2004, 12:40:42 PM »
From Amiga® Hardware Reference Manual:
Quote
Instead of using the pot pins as variable-resistive inputs, you can use these pins as a four-bit input/output port.  This provides you with two additional pins on each of the two controller ports for general purpose I/O.

If you set the output enable for any pin to a 1, the Amiga disconnects the potentiometer control circuitry from the port, and configures the pin for output.  The state of the data bit controls the logic level on the output pin. This register must be written to at the POTGO address, and read from the POTGOR address. There are large capacitors on these lines, and it can take up to 300 microseconds for the line to change state.

To use the entire register as an input, sensing the current state of the pot pins, write all 0s to POTGO. Thereafter you can read the current state by using read-only address POTGOR.  Note that bits set as inputs will be connected to the proportional counters (See the description of the START bit in POTGO).

These lines can also be used for button inputs. A button is a normally open switch that shorts to ground. The Amiga must provide a pull-up resistance on the sense pin. To do this, set the proper pin to output, and drive the line high (set both OUT... and DAT... to 1).  Reading POTGOR will produce a 0 if the button is pressed, a 1 if it is not.


You have to delay a bit after writing 0xffff to 'potgo' and reading the results back from 'potinp'. If you didn't delay, the button state would be read wrong.

Perhaps the flash is broken here?
 

Offline Piru

  • \' union select name,pwd--
  • Hero Member
  • *****
  • Join Date: Aug 2002
  • Posts: 6946
    • Show all replies
    • http://www.iki.fi/sintonen/
Re: Kickflash OS4 problems
« Reply #1 on: April 19, 2004, 12:57:22 PM »
@Noster

Figured it would be the right mouse button test, I once had similar problems (reading the RMB state properly after reboot) years ago. Reading the amiga hardware reference manual carefully helped here... :-)

Anyway, good to hear it got fixed.