Skip to content

Commit

Permalink
#1819 SDRPlay RSP1B tuner is now constructed correctly.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dennis Sheirer committed Feb 3, 2024
1 parent 614bf72 commit aa88ea2
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions src/main/java/io/github/dsheirer/source/tuner/TunerFactory.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
import io.github.dsheirer.source.tuner.sdrplay.api.device.DeviceInfo;
import io.github.dsheirer.source.tuner.sdrplay.api.device.Rsp1Device;
import io.github.dsheirer.source.tuner.sdrplay.api.device.Rsp1aDevice;
import io.github.dsheirer.source.tuner.sdrplay.api.device.Rsp1bDevice;
import io.github.dsheirer.source.tuner.sdrplay.api.device.Rsp2Device;
import io.github.dsheirer.source.tuner.sdrplay.api.device.RspDuoDevice;
import io.github.dsheirer.source.tuner.sdrplay.api.device.RspDxDevice;
Expand All @@ -87,6 +88,11 @@
import io.github.dsheirer.source.tuner.sdrplay.rsp1a.Rsp1aTunerConfiguration;
import io.github.dsheirer.source.tuner.sdrplay.rsp1a.Rsp1aTunerController;
import io.github.dsheirer.source.tuner.sdrplay.rsp1a.Rsp1aTunerEditor;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.ControlRsp1b;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.DiscoveredRsp1bTuner;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.IControlRsp1b;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.Rsp1bTunerConfiguration;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.Rsp1bTunerController;
import io.github.dsheirer.source.tuner.sdrplay.rsp1b.Rsp1bTunerEditor;
import io.github.dsheirer.source.tuner.sdrplay.rsp2.ControlRsp2;
import io.github.dsheirer.source.tuner.sdrplay.rsp2.DiscoveredRsp2Tuner;
Expand Down Expand Up @@ -149,6 +155,9 @@ public static List<DiscoveredRspTuner> getRspTuners(DeviceInfo deviceInfo, Chann
case RSP1A:
tuners.add(new DiscoveredRsp1aTuner(deviceInfo, channelizerType));
break;
case RSP1B:
tuners.add(new DiscoveredRsp1bTuner(deviceInfo, channelizerType));
break;
case RSP2:
tuners.add(new DiscoveredRsp2Tuner(deviceInfo, channelizerType));
break;
Expand Down Expand Up @@ -229,6 +238,14 @@ public static RspTuner getRspTuner(DeviceInfo deviceInfo, ChannelizerType channe
return new RspTuner(rsp1aTunerController, tunerErrorListener, channelizerType);
}
break;
case RSP1B:
if(device instanceof Rsp1bDevice rsp1bDevice)
{
IControlRsp1b controlRsp1b = new ControlRsp1b(rsp1bDevice);
Rsp1bTunerController rsp1bTunerController = new Rsp1bTunerController(controlRsp1b, tunerErrorListener);
return new RspTuner(rsp1bTunerController, tunerErrorListener, channelizerType);
}
break;
case RSP2:
if(device instanceof Rsp2Device rsp2Device)
{
Expand Down Expand Up @@ -412,6 +429,8 @@ public static TunerConfiguration getTunerConfiguration(TunerType type, String un
return new Rsp1TunerConfiguration(uniqueID);
case RSP_1A:
return new Rsp1aTunerConfiguration(uniqueID);
case RSP_1B:
return new Rsp1bTunerConfiguration(uniqueID);
case RSP_2:
return new Rsp2TunerConfiguration(uniqueID);
case RSP_DUO_1:
Expand Down

0 comments on commit aa88ea2

Please sign in to comment.