New pulseblaster_only driver (with DAC)

This commit is contained in:
Markus Rosenstihl 2016-10-27 14:41:54 +00:00
parent 0aaa1496dc
commit e12d64957c
2 changed files with 14 additions and 3 deletions

View File

@ -332,14 +332,18 @@ pb_radio_processor_g_backend.o: pb_radio_processor_g_backend.cpp \
pulseblaster_only$(EXEEXT): pulseblaster_only.o \
hardware.o \
../drivers/dummy/dummy.o \
$(DRV_SPC_MI40xx) \
$(DRV_PTS) \
$(DRV_TEMPCONT) \
$(DRV_DAC20) \
$(DRV_PB_24BIT) $(DRV_PB) $(DRV_PB_PROG) \
../core/core.a
@$(LINK_MACHINE) $^ $(LIBS) -o $@ -lpthread
pulseblaster_only.o: pulseblaster_only.cpp \
../drivers/SpinCore-PulseBlaster24Bit/SpinCore-PulseBlaster24Bit.h ../drivers/SpinCore-PulseBlaster/SpinCore-PulseBlaster.h ../drivers/SpinCore-PulseBlaster/PulseBlasterProgram.h \
../core/stopwatch.h ../drivers/Spectrum-MI40xxSeries/Spectrum-MI40xxSeries.h ../drivers/Spectrum-M2i40xxSeries/Spectrum-M2i40xxSeries.h
../drivers/SpinCore-PulseBlaster24Bit/SpinCore-PulseBlaster24Bit.h \
../drivers/SpinCore-PulseBlaster/SpinCore-PulseBlaster.h \
../drivers/SpinCore-PulseBlaster/PulseBlasterProgram.h \
../drivers/Tecmag-DAC20/DAC20.h \
../core/stopwatch.h

View File

@ -7,6 +7,7 @@
#include "machines/hardware.h"
#include "core/core.h"
#include "drivers/PTS-Synthesizer/PTS.h"
#include "drivers/Tecmag-DAC20/DAC20.h"
#include "drivers/dummy/dummy.h"
#include "drivers/SpinCore-PulseBlaster24Bit/SpinCore-PulseBlaster24Bit.h"
@ -35,6 +36,7 @@ class pulseblaster_only_hardware: public hardware
PTS* my_pts;
SpinCorePulseBlaster24Bit* my_pulseblaster;
dummy* my_adc;
DAC20* my_dac;
public:
pulseblaster_only_hardware()
@ -47,11 +49,16 @@ public:
/* device_id=0, clock=100MHz, sync_mask: Bit 16 */
my_pulseblaster = new SpinCorePulseBlaster24Bit(0, 1e8, 0 << 16);
my_pts = new PTS_latched(0);
my_dac = new DAC20(1);
my_dac->set_latch_bit(17); // 17 is default LE; DATA 18 and CLK 16
// publish devices
the_pg = my_pulseblaster;
the_adc = my_adc;
the_fg = my_pts;
list_dacs.push_back(my_dac);
}
virtual ~pulseblaster_only_hardware()