jAER project on SourceForge

ch.unizh.ini.jaer.chip.cochlea
Class CochleaAMS1b.Biasgen

java.lang.Object
  extended by net.sf.jaer.biasgen.Biasgen
      extended by ch.unizh.ini.jaer.chip.cochlea.CochleaAMS1b.Biasgen
All Implemented Interfaces:
java.util.Observer, BiasgenHardwareInterface, BiasgenPreferences, ChipControlPanel, HardwareInterface
Enclosing class:
CochleaAMS1b

public class CochleaAMS1b.Biasgen
extends Biasgen
implements ChipControlPanel

Describes IPots on tmpdiff128 retina chip. These are configured by a shift register as shown here:

tmpdiff128 shift register arrangement

This bias generator also offers an abstracted ChipControlPanel interface that is used for a simplified user interface.

Author:
tobi

Nested Class Summary
 
Nested classes/interfaces inherited from class net.sf.jaer.biasgen.Biasgen
Biasgen.HasPreference
 
Field Summary
protected  DAC dac
          The DAC on the board.
 
Fields inherited from class net.sf.jaer.biasgen.Biasgen
controlPanel, hardwareInterface, potArray
 
Constructor Summary
CochleaAMS1b.Biasgen(Chip chip)
          Creates a new instance of Biasgen for Tmpdiff128 with a given hardware interface
 
Method Summary
 javax.swing.JPanel buildControlPanel()
          Builds the default control panel and returns it.
 void initDAC()
           
 boolean isDACPowered()
          Returns the DAC powered state
 void loadPreferences()
          Loads preferences for the potArray and masterbias.
 void setDACPowered(boolean yes)
          Sets the VDACs on the board to be powered or high impedance output.
 void setHardwareInterface(BiasgenHardwareInterface hw)
          Assigns the HardwareInterface to this Biasgen.
 void storePreferences()
          Stores preferences to the Preferences node for the potArray and masterbias.
 void update(java.util.Observable observable, java.lang.Object object)
          The central point for communication with HW from biasgen.
 
Methods inherited from class net.sf.jaer.biasgen.Biasgen
close, endBatchEdit, exportPreferences, flashConfiguration, formatConfigurationBytes, getChip, getControlPanel, getHardwareInterface, getIPotGroups, getMasterbias, getName, getNumPots, getPotArray, getPotByName, getPotByNumber, getTypeName, importPreferences, isBatchEditOccurring, isInitialized, isOpen, open, putPref, putPref, putPref, putPref, putPref, resume, sendConfiguration, setBatchEditOccurring, setChip, setControlPanel, setIPotGroups, setMasterbias, setName, setPotArray, setPowerDown, showUnitializedBiasesWarningDialog, startBatchEdit, suspend, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.sf.jaer.biasgen.ChipControlPanel
getControlPanel
 

Field Detail

dac

protected final DAC dac
The DAC on the board. Specified with 5V reference even though Vdd=3.3 because the internal 2.5V reference is used and so that the VPot controls display correct voltage.

Constructor Detail

CochleaAMS1b.Biasgen

public CochleaAMS1b.Biasgen(Chip chip)
Creates a new instance of Biasgen for Tmpdiff128 with a given hardware interface

Parameters:
chip - the chip this biasgen belongs to
Method Detail

loadPreferences

public void loadPreferences()
Description copied from class: Biasgen
Loads preferences for the potArray and masterbias. Subclasses should override this method to load additional information.

Specified by:
loadPreferences in interface BiasgenPreferences
Overrides:
loadPreferences in class Biasgen

storePreferences

public void storePreferences()
Description copied from class: Biasgen
Stores preferences to the Preferences node for the potArray and masterbias. Subclasses must override this method to store additional information!!! For example, a subclass that defines additional configuration information should call storePreferences explicitly for additional configuration.

Specified by:
storePreferences in interface BiasgenPreferences
Overrides:
storePreferences in class Biasgen

buildControlPanel

public javax.swing.JPanel buildControlPanel()
Description copied from class: Biasgen
Builds the default control panel and returns it. This method builds a BiasgenPanel that encloses the PotArray in a PotPanel and the Masterbias in a MasterbiasPanel and returns a tabbed pane for these two components. Subclasses can override buildControlPanel to build their own control panel.

Overrides:
buildControlPanel in class Biasgen
Returns:
the default control panel

setHardwareInterface

public void setHardwareInterface(BiasgenHardwareInterface hw)
Description copied from class: Biasgen
Assigns the HardwareInterface to this Biasgen. If non-null, the configuration information (e.g. biases) are also sent to the device.

Overrides:
setHardwareInterface in class Biasgen
Parameters:
hw - the hardware interface.

update

public void update(java.util.Observable observable,
                   java.lang.Object object)
The central point for communication with HW from biasgen. All objects in Biasgen are Observables and add Biasgen.this as Observer. They then call notifyObservers when their state changes.

Specified by:
update in interface java.util.Observer
Overrides:
update in class Biasgen
Parameters:
observable - IPot, Scanner, etc
object - not used at present

initDAC

public void initDAC()
             throws HardwareInterfaceException
Throws:
HardwareInterfaceException

setDACPowered

public void setDACPowered(boolean yes)
                   throws HardwareInterfaceException
Sets the VDACs on the board to be powered or high impedance output. This is a global operation.

Parameters:
yes - true to power up DACs
Throws:
HardwareInterfaceException

isDACPowered

public boolean isDACPowered()
Returns the DAC powered state

Returns:
true if powered up

jAER project on SourceForge