mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-12 08:37:25 -05:00
IQ recording file playback partial checkin.
NOTE: only the gui components and settings handling have been implemented. Actual recording playback is not yet implemented. Partial checkin of initial P25 decoder development. NOTE: P25 decoder is not yet functional.
This commit is contained in:
@@ -31,6 +31,7 @@ import javax.swing.tree.TreePath;
|
||||
import map.IconManager;
|
||||
import playlist.PlaylistNode;
|
||||
import source.config.SourceConfigTuner;
|
||||
import source.recording.RecordingGroupNode;
|
||||
import source.tuner.Tuner;
|
||||
import source.tuner.TunerGroupNode;
|
||||
import source.tuner.TunerNode;
|
||||
@@ -61,8 +62,8 @@ public class ConfigurationControllerModel extends DefaultTreeModel
|
||||
|
||||
|
||||
private PlaylistNode mPlaylistNode;
|
||||
|
||||
private TunerGroupNode mTunerGroupNode;
|
||||
private RecordingGroupNode mRecordingGroupNode;
|
||||
|
||||
private IconManager mIconManagerFrame;
|
||||
|
||||
@@ -114,17 +115,24 @@ public class ConfigurationControllerModel extends DefaultTreeModel
|
||||
public void init()
|
||||
{
|
||||
/**
|
||||
* Add the root tuner group node
|
||||
* Add the tuner group node
|
||||
*/
|
||||
mTunerGroupNode = new TunerGroupNode();
|
||||
insertNodeInto( mTunerGroupNode, (MutableTreeNode)root, 0 );
|
||||
addTuners( mTunerGroupNode );
|
||||
|
||||
/**
|
||||
* Add the recording group node
|
||||
*/
|
||||
mRecordingGroupNode = new RecordingGroupNode();
|
||||
insertNodeInto( mRecordingGroupNode, (MutableTreeNode)root, 1 );
|
||||
mRecordingGroupNode.loadRecordings();
|
||||
|
||||
/**
|
||||
* Add the playlist node
|
||||
*/
|
||||
mPlaylistNode = new PlaylistNode();
|
||||
insertNodeInto( mPlaylistNode, (MutableTreeNode)root, 1 );
|
||||
insertNodeInto( mPlaylistNode, (MutableTreeNode)root, 2 );
|
||||
mPlaylistNode.loadPlaylist();
|
||||
}
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ import playlist.PlaylistManager;
|
||||
import record.RecorderManager;
|
||||
import settings.SettingsManager;
|
||||
import source.SourceManager;
|
||||
import source.recording.RecordingSourceManager;
|
||||
import source.tuner.TunerManager;
|
||||
import controller.channel.ChannelManager;
|
||||
import eventlog.EventLogManager;
|
||||
@@ -35,6 +36,7 @@ public class ResourceManager
|
||||
private EventLogManager mEventLogManager;
|
||||
private PlaylistManager mPlaylistManager;
|
||||
private RecorderManager mRecorderManager;
|
||||
private RecordingSourceManager mRecordingSourceManager;
|
||||
private SettingsManager mSettingsManager;
|
||||
private SourceManager mSourceManager;
|
||||
private TunerManager mTunerManager;
|
||||
@@ -66,6 +68,7 @@ public class ResourceManager
|
||||
*/
|
||||
mChannelManager = new ChannelManager( this );
|
||||
mSourceManager = new SourceManager( this );
|
||||
mRecordingSourceManager = new RecordingSourceManager( this );
|
||||
mTunerManager = new TunerManager( this );
|
||||
mController = new ConfigurationControllerModel( this );
|
||||
mMapService = new MapService( this );
|
||||
@@ -146,6 +149,16 @@ public class ResourceManager
|
||||
{
|
||||
mSourceManager = sourceManager;
|
||||
}
|
||||
|
||||
public RecordingSourceManager getRecordingSourceManager()
|
||||
{
|
||||
return mRecordingSourceManager;
|
||||
}
|
||||
|
||||
public void setRecordingSourceManager( RecordingSourceManager manager )
|
||||
{
|
||||
mRecordingSourceManager = manager;
|
||||
}
|
||||
|
||||
public ChannelManager getChannelManager()
|
||||
{
|
||||
|
||||
@@ -40,6 +40,7 @@ import record.config.RecordConfiguration;
|
||||
import sample.Listener;
|
||||
import source.SourceType;
|
||||
import source.config.SourceConfigFactory;
|
||||
import source.config.SourceConfigRecording;
|
||||
import source.config.SourceConfigTuner;
|
||||
import source.config.SourceConfiguration;
|
||||
import source.tuner.TunerChannel;
|
||||
@@ -344,6 +345,14 @@ public class Channel extends Configuration
|
||||
retVal = new TunerChannel( Type.LOCKED, config.getFrequency(),
|
||||
mDecodeConfiguration.getDecoderType().getChannelBandwidth() );
|
||||
}
|
||||
else if( mSourceConfiguration.getSourceType() == SourceType.RECORDING )
|
||||
{
|
||||
SourceConfigRecording config =
|
||||
(SourceConfigRecording)mSourceConfiguration;
|
||||
|
||||
retVal = new TunerChannel( Type.LOCKED, config.getFrequency(),
|
||||
mDecodeConfiguration.getDecoderType().getChannelBandwidth() );
|
||||
}
|
||||
|
||||
return retVal;
|
||||
}
|
||||
|
||||
@@ -41,6 +41,7 @@ import source.FloatArraySource;
|
||||
import source.FloatSource;
|
||||
import source.Source;
|
||||
import source.Source.SampleType;
|
||||
import source.SourceException;
|
||||
import source.config.SourceConfigMixer;
|
||||
import source.tuner.Tuner;
|
||||
import source.tuner.TunerChannelSource;
|
||||
@@ -256,8 +257,18 @@ public class ProcessingChain implements Listener<Message>
|
||||
/* Get a new source if needed and start the sample processor thread */
|
||||
if( mChannel.getEnabled() && mResourceManager != null )
|
||||
{
|
||||
mSource = mResourceManager.getSourceManager()
|
||||
.getSource( ProcessingChain.this );
|
||||
try
|
||||
{
|
||||
mSource = mResourceManager.getSourceManager()
|
||||
.getSource( ProcessingChain.this );
|
||||
}
|
||||
catch ( SourceException e )
|
||||
{
|
||||
Log.error( "Couldn't obtain source for processing chain [" +
|
||||
toString() + "] - " + e.getLocalizedMessage() );
|
||||
|
||||
mSource = null;
|
||||
}
|
||||
|
||||
if( mSource != null )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user