Klasse VIACore

java.lang.Object
libsidplay.components.c1541.VIACore
Bekannte direkte Unterklassen:
VIA6522BC, VIA6522DC

public abstract class VIACore extends Object
 24jan97 a.fachat
 new interrupt handling, hopefully according to the specs now.
 All interrupts (note: not timer events (i.e. alarms) are put
 into one interrupt flag.
 if an interrupt condition changes, the function (i.e. cpp macro)
 update_myviairq() id called, that checks the IRQ line state.
 This is now possible, as ettore has decoupled A_* alarm events
 from interrupts for performance reasons.

 A new function for signaling rising/falling edges on the
 control lines is introduced:
      myvia_signal(VIA_SIG_[CA1|CA2|CB1|CB2], VIA_SIG_[RISE|FALL])
 which signals the corresponding edge to the VIA. The constants
 are defined in via.h.

 Except for shift register and input latching everything should be ok now.
 
  • Feldübersicht

    Felder
    Modifizierer und Typ
    Feld
    Beschreibung
    protected int
     
    protected int
     
    protected boolean
     
    protected int
     
    protected int
     
    protected byte
     
    protected byte
     
    private boolean
     
    protected byte
     
    protected byte
     
    protected int
     
    protected int
     
    protected int
     
    protected int
     
    protected int
     
    private final Event
     
    private final Event
     
    protected long
     
    protected char
     
    protected long
     
    private static final int
    timer values do not depend on a certain value here, but PB7 does...
    protected long
     
    protected char
     
    protected long
     
    protected final byte[]
    Registers
    protected static final int
    Auxiliary control register.
    protected static final int
    Data direction register for port A.
    protected static final int
    Data direction register for port B.
    protected static final int
    Interrupt control register.
    protected static final int
    Interrupt flag register.
    protected static final int
    Handshake.
    protected static final int
    Handshake.
    protected static final int
    Handshake.
    protected static final int
    Handshake.
    protected static final int
    Control Bit.
    protected static final int
    Shift Register completion.
    protected static final int
    Timer 1 underflow.
    protected static final int
    Timer 2 underflow.
    protected static final int
    Peripheral control register.
    protected static final int
    Port A.
    protected static final int
    Port A with no handshake.
    protected static final int
    Port B.
    static final int
     
    protected static final int
     
    static final int
     
    protected static final int
     
    static final int
     
    static final int
     
    protected static final int
    Serial port shift register.
    protected static final int
    Timer 1 count high.
    protected static final int
    Timer 1 count low.
    protected static final int
    Timer 1 latch high.
    protected static final int
    Timer 1 latch low.
    protected static final int
    Timer 2 latch/count high.
    protected static final int
    Timer 2 count low - read only.
    protected static final int
    Timer 2 latch low - write only.
  • Konstruktorübersicht

    Konstruktoren
    Modifizierer
    Konstruktor
    Beschreibung
    protected
     
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
    protected abstract void
    alarmSet(Event alarm, long ti)
     
    protected abstract void
     
    protected void
     
    protected abstract long
     
    final void
     
    private boolean
     
    private boolean
     
    private boolean
     
    private boolean
     
    private boolean
     
    private boolean
     
    private boolean
     
    private long
     
    private long
     
    final byte
    read(int addr)
     
    protected abstract byte
     
    protected abstract byte
     
    void
     
    protected abstract void
    setCa2(int state)
     
    protected abstract void
    setCb2(int state)
     
    protected abstract void
    setIRQ(boolean irq)
     
    final void
    signal(int line, int edge)
     
    protected abstract void
    storeAcr(byte value)
     
    protected abstract void
    storePra(int addr, byte value)
     
    protected abstract void
    storePrb(byte value)
     
    protected abstract void
    storeSr(byte value)
     
    protected abstract void
    storeT2l(byte value)
     
    private void
    updateMyviatal(long rclk)
    Update timer A latch value.
    private void
     
    final void
    write(int addr, byte b)
     

    Von Klasse geerbte Methoden java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Felddetails

    • VIA_PRB

      protected static final int VIA_PRB
      Port B.
      Siehe auch:
    • VIA_PRA

      protected static final int VIA_PRA
      Port A.
      Siehe auch:
    • VIA_DDRB

      protected static final int VIA_DDRB
      Data direction register for port B.
      Siehe auch:
    • VIA_DDRA

      protected static final int VIA_DDRA
      Data direction register for port A.
      Siehe auch:
    • VIA_T1CL

      protected static final int VIA_T1CL
      Timer 1 count low.
      Siehe auch:
    • VIA_T1CH

      protected static final int VIA_T1CH
      Timer 1 count high.
      Siehe auch:
    • VIA_T1LL

      protected static final int VIA_T1LL
      Timer 1 latch low.
      Siehe auch:
    • VIA_T1LH

      protected static final int VIA_T1LH
      Timer 1 latch high.
      Siehe auch:
    • VIA_T2CL

      protected static final int VIA_T2CL
      Timer 2 count low - read only.
      Siehe auch:
    • VIA_T2LL

      protected static final int VIA_T2LL
      Timer 2 latch low - write only.
      Siehe auch:
    • VIA_T2CH

      protected static final int VIA_T2CH
      Timer 2 latch/count high.
      Siehe auch:
    • VIA_SR

      protected static final int VIA_SR
      Serial port shift register.
      Siehe auch:
    • VIA_ACR

      protected static final int VIA_ACR
      Auxiliary control register.
      Siehe auch:
    • VIA_PCR

      protected static final int VIA_PCR
      Peripheral control register.
      Siehe auch:
    • VIA_IFR

      protected static final int VIA_IFR
      Interrupt flag register.
      Siehe auch:
    • VIA_IER

      protected static final int VIA_IER
      Interrupt control register.
      Siehe auch:
    • VIA_PRA_NHS

      protected static final int VIA_PRA_NHS
      Port A with no handshake.
      Siehe auch:
    • VIA_IM_IRQ

      protected static final int VIA_IM_IRQ
      Control Bit.
      Siehe auch:
    • VIA_IM_T1

      protected static final int VIA_IM_T1
      Timer 1 underflow.
      Siehe auch:
    • VIA_IM_T2

      protected static final int VIA_IM_T2
      Timer 2 underflow.
      Siehe auch:
    • VIA_IM_CB1

      protected static final int VIA_IM_CB1
      Handshake.
      Siehe auch:
    • VIA_IM_CB2

      protected static final int VIA_IM_CB2
      Handshake.
      Siehe auch:
    • VIA_IM_SR

      protected static final int VIA_IM_SR
      Shift Register completion.
      Siehe auch:
    • VIA_IM_CA1

      protected static final int VIA_IM_CA1
      Handshake.
      Siehe auch:
    • VIA_IM_CA2

      protected static final int VIA_IM_CA2
      Handshake.
      Siehe auch:
    • VIA_SIG_CA1

      public static final int VIA_SIG_CA1
      Siehe auch:
    • VIA_SIG_CA2

      protected static final int VIA_SIG_CA2
      Siehe auch:
    • VIA_SIG_CB1

      public static final int VIA_SIG_CB1
      Siehe auch:
    • VIA_SIG_CB2

      protected static final int VIA_SIG_CB2
      Siehe auch:
    • VIA_SIG_FALL

      public static final int VIA_SIG_FALL
      Siehe auch:
    • VIA_SIG_RISE

      public static final int VIA_SIG_RISE
      Siehe auch:
    • via

      protected final byte[] via
      Registers
    • ifr

      protected int ifr
    • ier

      protected int ier
    • tal

      protected char tal
    • tbl

      protected char tbl
    • tau

      protected long tau
    • tbu

      protected long tbu
    • tai

      protected long tai
    • tbi

      protected long tbi
    • pb7

      protected int pb7
    • pb7x

      protected int pb7x
    • pb7o

      protected int pb7o
    • pb7xx

      protected int pb7xx
    • pb7sx

      protected int pb7sx
    • oldpa

      protected byte oldpa
    • oldpb

      protected byte oldpb
    • ila

      protected byte ila
    • ilb

      protected byte ilb
    • ca2State

      protected int ca2State
    • cb2State

      protected int cb2State
    • enabled

      protected boolean enabled
    • t1Alarm

      private final Event t1Alarm
    • t2Alarm

      private final Event t2Alarm
    • lastState

      private boolean lastState
    • TAUOFFSET

      private static final int TAUOFFSET
      timer values do not depend on a certain value here, but PB7 does...
      Siehe auch:
  • Konstruktordetails

    • VIACore

      protected VIACore(String name)
  • Methodendetails

    • isCa2Indinput

      private boolean isCa2Indinput()
    • isCa2Handshake

      private boolean isCa2Handshake()
    • isCa2PulseMode

      private boolean isCa2PulseMode()
    • isCa2ToggleMode

      private boolean isCa2ToggleMode()
    • isCb2Handshake

      private boolean isCb2Handshake()
    • isCb2PulseMode

      private boolean isCb2PulseMode()
    • isCb2ToggleMode

      private boolean isCb2ToggleMode()
    • checkInterrupts

      protected void checkInterrupts()
    • myviata

      private long myviata()
    • myviatb

      private long myviatb()
    • updateMyviatal

      private void updateMyviatal(long rclk)
      Update timer A latch value.
    • updateMyviatbl

      private void updateMyviatbl()
    • disable

      public final void disable()
    • reset

      public void reset()
    • signal

      public final void signal(int line, int edge)
    • write

      public final void write(int addr, byte b)
    • read

      public final byte read(int addr)
    • alarmSet

      protected abstract void alarmSet(Event alarm, long ti)
    • alarmUnset

      protected abstract void alarmUnset(Event alarm)
    • cpuClk

      protected abstract long cpuClk()
    • setIRQ

      protected abstract void setIRQ(boolean irq)
    • storePra

      protected abstract void storePra(int addr, byte value)
    • storePrb

      protected abstract void storePrb(byte value)
    • storeAcr

      protected abstract void storeAcr(byte value)
    • storeSr

      protected abstract void storeSr(byte value)
    • storeT2l

      protected abstract void storeT2l(byte value)
    • readPra

      protected abstract byte readPra()
    • readPrb

      protected abstract byte readPrb()
    • setCa2

      protected abstract void setCa2(int state)
    • setCb2

      protected abstract void setCb2(int state)