public class CcmAccess
extends com.sig.ccm.CcmBase
| Modifier and Type | Field and Description |
|---|---|
static int |
CCM_BLOCKSIZE_1024
The Constant CCM_BLOCKSIZE_1024.
|
static int |
CCM_BLOCKSIZE_128
The Constant CCM_BLOCKSIZE_128.
|
static int |
CCM_BLOCKSIZE_2048
The Constant CCM_BLOCKSIZE_2048.
|
static int |
CCM_BLOCKSIZE_256
The Constant CCM_BLOCKSIZE_256.
|
static int |
CCM_BLOCKSIZE_512
The Constant CCM_BLOCKSIZE_512.
|
static int |
CCM_BLOCKSIZE_64
The Constant CCM_BLOCKSIZE_64.
|
static int |
CCM_SAMPLERATE_10000
The Constant CCM_SAMPLERATE_10000.
|
static int |
CCM_SAMPLERATE_12500
The Constant CCM_SAMPLERATE_12500.
|
static int |
CCM_SAMPLERATE_20000
The Constant CCM_SAMPLERATE_20000.
|
static int |
CCM_SAMPLERATE_25000
The Constant CCM_SAMPLERATE_25000.
|
static int |
CCM_SAMPLERATE_40000
The Constant CCM_SAMPLERATE_40000.
|
static int |
CCM_SAMPLERATE_50000
The Constant CCM_SAMPLERATE_50000.
|
static int |
CCM_STATUS_LOGGING_ENA
The Constant CCM_STATUS_LOGGING_ENA.
|
static int |
CCM_STATUS_MEMORY_FULL
The Constant CCM_STATUS_MEMORY_FULL.
|
static int |
CCM_STATUS_OVERFLOW
The Constant CCM_STATUS_OVERFLOW.
|
static int |
CCM_STATUS_RUNNING
The Constant CCM_STATUS_RUNNING.
|
static int |
CCM_STATUS_VALID_MASK
The Constant CCM_STATUS_VALID_MASK.
|
static int |
CCM_WINDOW_CUSTOM
The Constant CCM_WINDOW_CUSTOM.
|
static int |
CCM_WINDOW_HAMMING
The Constant CCM_WINDOW_HAMMING.
|
static int |
CCM_WINDOW_HANNING
The Constant CCM_WINDOW_HANNING.
|
static int |
CCM_WINDOW_RECTANGULAR
The Constant CCM_WINDOW_RECTANGULAR.
|
| Constructor and Description |
|---|
CcmAccess()
Instantiates a new Ccm access.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the I/O handle previously opened with open
|
java.lang.String |
getDescription()
Gets the description of an accessible Command and Control Module (CCM).
|
CcmVersion |
getFirmwareVersion()
Gets the firmware version of the current CCM.
|
int |
getFrequencyDomainBlockSize()
Gets the block size value currently used with frequency-domain data.
|
int |
getFrequencyDomainFrameBufferAvailable()
Gets the number of frequency domain frames available for reading from the frame buffer.
|
int |
getFrequencyDomainFrameBufferSize()
Gets the the number of frames maintained in the frequency domain frame buffer
|
int |
getFrequencyDomainFramesAvailable()
Gets the number of frequency domain frames available to read.
|
int |
getFrequencyDomainSkipFrames()
Gets the number of frequency domain frames that are skipped after taking frames.
|
int |
getFrequencyDomainTakeFrames()
Gets the number of frequency domain frames that are returned (taken) after skipping frames
|
int |
getFrequencyDomainWindow()
Gets the frequency domain window identifier.
|
CcmVersion |
getLibraryVersion()
Gets the version of the access library being used.
|
java.lang.String |
getLogfilePath()
Gets the current base folder used for server logging.
|
int[] |
getMicrophoneCoordinates()
Gets the coordinates of the microphones on the Ccm panel.
|
int |
getMicrophoneCount()
Gets the number of microphones available in the Ccm device.
|
java.lang.String |
getModel()
Gets the model of an accessible Command and Control Module (CCM).
|
int |
getOverflowWarning()
Gets the overflow warning level.
|
int |
getSampleRate()
Gets the current sample rate in Hz.
|
java.lang.String |
getSerialNumber()
Gets the serial number of the Command and Control Module (CCM).
|
CcmVersion |
getServiceVersion()
Gets the version of the system service being used
|
int |
getStatus()
Gets the current status information.
|
int |
getTimeDomainBlockSize()
Gets the block size value used for time domain data.
|
int |
getTimeDomainFrameBufferAvailable()
Gets the number of time domain frames available for reading from the frame buffer.
|
int |
getTimeDomainFrameBufferSize()
Gets the the number of frames maintained in the time domain frame buffer
|
int |
getTimeDomainFramesAvailable()
Gets the number of time domain frames available to read.
|
int |
getTimeDomainSkipFrames()
Gets the number of time domain frames that are skipped after taking frames.
|
int |
getTimeDomainTakeFrames()
Gets the number of time domain frames that are returned (taken) after skipping frames
|
boolean |
isFrequencyDomainEnabled()
Checks if is frequency domain enabled.
|
boolean |
isFrequencyDomainFrameBufferEnabled()
Checks if the frequency domain frame buffer is enabled.
|
boolean |
isFrequencyDomainLoggingEnabled()
Checks if service level frequency domain logging is enabled.
|
boolean |
isFrequencyDomainOverlapEnabled()
Checks if is frequency domain overlap is enabled.
|
boolean |
isTimeDomainEnabled()
Checks if time domain is enabled.
|
boolean |
isTimeDomainFrameBufferEnabled()
Checks if the time domain frame buffer is enabled.
|
boolean |
isTimeDomainLoggingEnabled()
Checks if is service level time domain logging is enabled.
|
void |
loadConfiguration(java.lang.String filepath)
Load a previously saved configuration from a file.
|
void |
open()
Open I/O handle for an accessible Command and Control Modules (CCM).
|
void |
readFrames(int[] frame,
boolean block)
Read one or more time domain or frequency domain frames.
|
int[] |
readFrames(int[] timeDomainFrame,
int[] frequencyDomainFrame,
boolean block)
Read read one or more time domain and frequency domain frames.
|
void |
saveConfiguration(java.lang.String filepath)
Save the Ccm configuration to a file
|
void |
setFrequencyDomainBlockSize(int blockSize)
Sets the block size to be used for frequency-domain data.
|
void |
setFrequencyDomainEnabled(boolean enabled)
Enable or disable frequency domain output from the CCM
|
void |
setFrequencyDomainFrameBufferEnabled(boolean enabled)
Enable or disable the frequency domain frame buffer
|
void |
setFrequencyDomainFrameBufferSize(int size)
Sets the the number of frames to be maintained in the frequency domain frame buffer
|
void |
setFrequencyDomainLoggingEnabled(boolean isEnabled)
Enable or disable the frequency domain service level logging
|
void |
setFrequencyDomainOverlapEnabled(boolean enabled)
Enable or disable the frequency domain frame overlap
|
void |
setFrequencyDomainSkipFrames(int skipFrame)
Set the number of frequency domain frames that are skipped after taking frames.
|
void |
setFrequencyDomainTakeFrames(int takeFrame)
Set the number of frequency domain frames that are taken after skipping frames.
|
void |
setFrequencyDomainWindow(int window)
Sets the frequency domain window.
|
void |
setFrequencyDomainWindowCoefficients(double[] buffer)
Sets the frequency domain window coefficients.
|
void |
setLogfilePath(java.lang.String path)
Sets the current base folder used for server logging.
|
void |
setPowerState(boolean power)
Turn Ccm power on or off
|
void |
setSampleRate(int sampleRate)
Sets the sample rate in Hz.
|
void |
setTimeDomainBlockSize(int blockSize)
Sets the block size to be used for time domain data.
|
void |
setTimeDomainEnabled(boolean enabled)
Enable or disable the time domain output.
|
void |
setTimeDomainFrameBufferEnabled(boolean enabled)
Enable or disable the time domain frame buffer.
|
void |
setTimeDomainFrameBufferSize(int size)
Set the number of frames maintained in the time domain frame buffer
|
void |
setTimeDomainLoggingEnabled(boolean isEnabled)
Enable or disable the time domain service level logging
|
void |
setTimeDomainSkipFrames(int skipFrame)
Set the number of time domain frames that are skipped after taking frames.
|
void |
setTimeDomainTakeFrames(int takeFrame)
Set the number of time domain frames that are taken after skipping frames.
|
void |
startInput()
Start the input sampling clock.
|
void |
stopInput()
Stop the input sampling clock
|
void |
writeData(int[] buffer)
Write data.
|
public static final int CCM_WINDOW_RECTANGULAR
public static final int CCM_WINDOW_CUSTOM
public static final int CCM_WINDOW_HAMMING
public static final int CCM_WINDOW_HANNING
public static final int CCM_STATUS_RUNNING
public static final int CCM_STATUS_OVERFLOW
public static final int CCM_STATUS_VALID_MASK
public static final int CCM_STATUS_LOGGING_ENA
public static final int CCM_STATUS_MEMORY_FULL
public static final int CCM_SAMPLERATE_10000
public static final int CCM_SAMPLERATE_12500
public static final int CCM_SAMPLERATE_20000
public static final int CCM_SAMPLERATE_25000
public static final int CCM_SAMPLERATE_40000
public static final int CCM_SAMPLERATE_50000
public static final int CCM_BLOCKSIZE_64
public static final int CCM_BLOCKSIZE_128
public static final int CCM_BLOCKSIZE_256
public static final int CCM_BLOCKSIZE_512
public static final int CCM_BLOCKSIZE_1024
public static final int CCM_BLOCKSIZE_2048
public CcmVersion getLibraryVersion() throws CcmException
CcmException - the Ccm exceptionpublic CcmVersion getServiceVersion() throws CcmException
CcmException - the Ccm exceptionpublic CcmVersion getFirmwareVersion() throws CcmException
CcmException - the Ccm exceptionpublic java.lang.String getDescription()
throws CcmException
CcmException - the Ccm exceptionpublic java.lang.String getModel()
throws CcmException
CcmException - the Ccm exceptionpublic java.lang.String getSerialNumber()
throws CcmException
CcmException - the Ccm exceptionpublic int getMicrophoneCount()
throws CcmException
CcmException - the Ccm exceptionpublic void close()
throws CcmException
CcmException - the Ccm exceptionpublic void open()
throws CcmException
CcmException - the Ccm exceptionpublic void setPowerState(boolean power)
throws CcmException
power - true to turn on, false otherwiseCcmException - the Ccm exceptionpublic void setSampleRate(int sampleRate)
throws CcmException
sampleRate - the sample rate
CcmException - the Ccm exceptionpublic int getSampleRate()
throws CcmException
CcmException - the Ccm exceptionpublic void setTimeDomainBlockSize(int blockSize)
throws CcmException
blockSize - the time domain block size
CcmException - the Ccm exceptionpublic int getTimeDomainBlockSize()
throws CcmException
CcmException - the Ccm exceptionpublic void setTimeDomainEnabled(boolean enabled)
throws CcmException
enabled - true to enable the time domain output, false otherwiseCcmException - the Ccm exceptionpublic boolean isTimeDomainEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainBlockSize(int blockSize)
throws CcmException
blockSize - the frequency domain block size
CcmException - the Ccm exceptionpublic int getFrequencyDomainBlockSize()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainEnabled(boolean enabled)
throws CcmException
enabled - true to enable the frequency domain output, false otherwiseCcmException - the Ccm exceptionpublic boolean isFrequencyDomainEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainWindow(int window)
throws CcmException
window - the frequency domain window identifier
CcmException - the Ccm exceptionpublic int getFrequencyDomainWindow()
throws CcmException
CcmException - the Ccm exceptionpublic void setTimeDomainLoggingEnabled(boolean isEnabled)
throws CcmException
isEnabled - true to enable time domain logging, false otherwiseCcmException - the Ccm exceptionpublic boolean isTimeDomainLoggingEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainLoggingEnabled(boolean isEnabled)
throws CcmException
isEnabled - true to enable the frequency domain logging, false otherwiseCcmException - the Ccm exceptionpublic boolean isFrequencyDomainLoggingEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic void setLogfilePath(java.lang.String path)
throws CcmException
path - the logging base folder pathCcmException - the Ccm exceptionpublic java.lang.String getLogfilePath()
throws CcmException
CcmException - the Ccm exceptionpublic void readFrames(int[] frame,
boolean block)
throws CcmException,
CcmInsufficientDataException
frame - the data buffer for the framesblock - wait for a frame to be availableCcmException - the Ccm exceptionCcmInsufficientDataException - the Ccm insufficient data exceptionpublic int[] readFrames(int[] timeDomainFrame,
int[] frequencyDomainFrame,
boolean block)
throws CcmException,
CcmInsufficientDataException
timeDomainFrame - the data buffer for the time domain framesfrequencyDomainFrame - the data buffer for the frequency domain framesblock - the blockCcmException - the Ccm exceptionCcmInsufficientDataException - the Ccm insufficient data exceptionpublic void writeData(int[] buffer)
throws CcmException
buffer - the bufferCcmException - the Ccm exceptionpublic int getTimeDomainFramesAvailable()
throws CcmException
CcmException - the Ccm exceptionpublic int getFrequencyDomainFramesAvailable()
throws CcmException
CcmException - the Ccm exceptionpublic void startInput()
throws CcmException
CcmException - the Ccm exceptionpublic void stopInput()
throws CcmException
CcmException - the Ccm exceptionpublic int getStatus()
throws CcmException,
CcmNotUpdatedException
CcmException - the Ccm exceptionCcmNotUpdatedException - the Ccm not updated exceptionpublic int getOverflowWarning()
throws CcmException
CcmException - the Ccm exceptionpublic void loadConfiguration(java.lang.String filepath)
throws CcmException
filepath - the the path to the configuration fileCcmException - the Ccm exceptionpublic void saveConfiguration(java.lang.String filepath)
throws CcmException
filepath - the path to where to save the configurationCcmException - the Ccm exceptionpublic void setTimeDomainFrameBufferEnabled(boolean enabled)
throws CcmException
enabled - true to enable the time domain frame buffer, false otherwiseCcmException - the Ccm exceptionpublic void setTimeDomainFrameBufferSize(int size)
throws CcmException
size - the number of time domain framesCcmException - the Ccm exceptionpublic boolean isTimeDomainFrameBufferEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic int getTimeDomainFrameBufferSize()
throws CcmException
CcmException - the Ccm exceptionpublic int getTimeDomainFrameBufferAvailable()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainFrameBufferEnabled(boolean enabled)
throws CcmException
enabled - true to enable the frequency domain frame buffer, false otherwiseCcmException - the Ccm exceptionpublic void setFrequencyDomainFrameBufferSize(int size)
throws CcmException
size - the number of frequency domain framesCcmException - the Ccm exceptionpublic boolean isFrequencyDomainFrameBufferEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic int getFrequencyDomainFrameBufferSize()
throws CcmException
CcmException - the Ccm exceptionpublic int getFrequencyDomainFrameBufferAvailable()
throws CcmException
CcmException - the Ccm exceptionpublic int[] getMicrophoneCoordinates()
throws CcmException,
CcmNotUpdatedException
CcmException - the Ccm exceptionCcmNotUpdatedException - the Ccm not updated exceptionpublic void setFrequencyDomainWindowCoefficients(double[] buffer)
throws CcmException
buffer - the frequency domain window coefficientsCcmException - the Ccm exceptionpublic void setFrequencyDomainOverlapEnabled(boolean enabled)
throws CcmException
enabled - true to enable the frequency domain frame overlap, false otherwiseCcmException - the Ccm exceptionpublic boolean isFrequencyDomainOverlapEnabled()
throws CcmException
CcmException - the Ccm exceptionpublic void setFrequencyDomainTakeFrames(int takeFrame)
throws CcmException
takeFrame - the number of frequency domain frames to takeCcmException - the Ccm exceptionpublic void setFrequencyDomainSkipFrames(int skipFrame)
throws CcmException
skipFrame - the number of frequency domain frames to skipCcmException - the Ccm exceptionpublic int getFrequencyDomainTakeFrames()
throws CcmException
CcmException - the Ccm exceptionpublic int getFrequencyDomainSkipFrames()
throws CcmException
CcmException - the Ccm exceptionpublic void setTimeDomainTakeFrames(int takeFrame)
throws CcmException
takeFrame - the number of time domain frames to takeCcmException - the Ccm exceptionpublic void setTimeDomainSkipFrames(int skipFrame)
throws CcmException
skipFrame - the number of time domain frames to skipCcmException - the Ccm exceptionsetTimeDomainTakeFramespublic int getTimeDomainTakeFrames()
throws CcmException
CcmException - the Ccm exceptionpublic int getTimeDomainSkipFrames()
throws CcmException
CcmException - the Ccm exception