21 m_BurstHalfwaveClockCount(7),
39 return "org.mitk.modules.us.USDiPhASDevice";
84 short* rfDataChannelData,
int channelDatalinesPerDataset,
int channelDataSamplesPerChannel,
int channelDataTotalDatasets,
85 short* rfDataArrayBeamformed,
int beamformedLines,
int beamformedSamples,
int beamformedTotalDatasets,
86 unsigned char* imageData,
int imageWidth,
int imageHeight,
int imagePixelFormat,
int imageSetsTotal,
double timeStamp)
89 rfDataChannelData, channelDatalinesPerDataset, channelDataSamplesPerChannel, channelDataTotalDatasets,
90 rfDataArrayBeamformed, beamformedLines, beamformedSamples, beamformedTotalDatasets,
91 imageData, imageWidth, imageHeight, imagePixelFormat, imageSetsTotal, timeStamp);
126 MITK_WARN(
"USDevice")(
"USDiPhASDevice") <<
"No probe found.";
168 int numChannels =
m_ScanMode.reconstructionLines;
173 for (
int ev = 0; ev <
m_ScanMode.transmitEventsCount; ++ev)
175 m_ScanMode.TransmitEvents[ev].transmitEventDelays =
new float[numChannels];
176 m_ScanMode.TransmitEvents[ev].BurstHalfwaveClockCountPerChannel =
new int[numChannels];
177 m_ScanMode.TransmitEvents[ev].BurstCountPerChannel =
new int[numChannels];
178 m_ScanMode.TransmitEvents[ev].BurstUseNegativePolarityPerChannel =
new bool[numChannels];
179 m_ScanMode.TransmitEvents[ev].ChannelMultiplexerSetups =
nullptr;
180 float tiltStrength = ((
m_ScanMode.transmitEventsCount - 1) / 2 - ev) * 20e-9f;
182 for (
int i = 0; i < numChannels; ++i)
185 m_ScanMode.TransmitEvents[ev].BurstCountPerChannel[i] = 1;
186 m_ScanMode.TransmitEvents[ev].BurstUseNegativePolarityPerChannel[i] =
true;
187 m_ScanMode.TransmitEvents[ev].transmitEventDelays[i] = 2e-6f + (i - numChannels / 2) * tiltStrength;
193 m_ScanMode.transmitSequences[0].startEvent = 0;
213 m_ScanMode.receivePhaseLengthSeconds = 185e-6f;
215 for (
int tgc = 0; tgc < 8; ++tgc)
231 m_ScanMode.reconstructedLinePitchMmOrAngleDegree = 0.3f;
233 m_ScanMode.reconstructionSamplesPerLine = 2048;
238 m_ScanMode.transmitPhaseLengthSeconds = 1e-6f;
256 m_ScanMode.triggerSetup.constantPulseRepetitionRateHz = 20;
257 m_ScanMode.triggerSetup.triggerWidthMicroseconds = 15;
258 m_ScanMode.triggerSetup.delayTrigger2Microseconds = 300;
265 MITK_INFO <<
"DiPhAS API: " << message <<
'\n';
282 m_ScanMode.scanModeName =
"Interleaved Beamforming Mode";
293 m_ScanMode.scanModeName =
"Plane Wave Beamforming Mode";
void ImageDataCallback(short *rfDataChannelData, int &channelDataChannelsPerDataset, int &channelDataSamplesPerChannel, int &channelDataTotalDatasets, short *rfDataArrayBeamformed, int &beamformedLines, int &beamformedSamples, int &beamformedTotalDatasets, unsigned char *imageData, int &imageWidth, int &imageHeight, int &imagePixelFormat, int &imageSetsTotal, double &timeStamp)
Implementation of mitk::USControlInterfaceProbes for DiPhAS ultrasound devices. See documentation of ...
A device holds information about it's model, make and the connected probes. It is the common super cl...
virtual bool OnActivation()
Is called during the activation process. After this method is finished, the device is generating imag...
BeamformingParametersPlaneWaveCompound paramsPlaneWave
itk::DataObject::Pointer MakeOutput(DataObjectPointerArraySizeType idx) override
Make a DataObject of the correct type to used as the specified output.
void WrapperMessageCallback(const char *message)
Implementation of mitk::USImageSource for DiPhAS API devices. The method mitk::USImageSource::GetNext...
mitk::USDiPhASImageSource::Pointer m_ImageSource
mitk::USDiPhASDevice * w_device
DataCollection - Class to facilitate loading/accessing structured data.
ScanModeNative m_ScanMode
virtual ~USDiPhASDevice()
BeamformingParametersInterleaved_OA_US paramsInterleaved
Beamforming m_CurrentBeamformingAlgorithm
int m_BurstHalfwaveClockCount
virtual bool OnConnection()
Is called during the connection process. Connect to the DiPhAS API.
virtual bool OnInitialization()
Is called during the initialization process. There is nothing done on the initialization of a mik::US...
USDiPhASDevice(std::string manufacturer, std::string model)
void SetInterleaved(bool interleaved)
void MessageCallback(const char *message)
virtual bool OnDeactivation()
Is called during the deactivation process. After a call to this method the device is connected...
void SetBursts(int bursts)
unsigned int m_NumberOfOutputs
USDiPhASProbesControls::Pointer m_ControlsProbes
void InitializeScanMode()
USImageSource::Pointer GetUSImageSource()
virtual USControlInterfaceProbes::Pointer GetControlInterfaceProbes()
Default getter for the probes control interface. Has to be implemented in a subclass if a probes cont...
ScanModeNative & GetScanMode()
void UpdateTransmitEvents()
virtual void OnFreeze(bool freeze)
Changes scan state of the device if freeze is toggeled in mitk::USDevice.
virtual std::string GetDeviceClass()
Returns the class of the device.
virtual bool OnDisconnection()
Is called during the disconnection process. Deactivate and remove all DiPhAS API controls. A disconnect from the DiPhAS API is not possible for which reason the hardware stays in connected state even after calling this method.
mitk::USDiPhASImageSource * w_ISource
virtual itk::SmartPointer< USAbstractControlInterface > GetControlInterfaceCustom()
Default getter for the custom control interface. Has to be implemented in a subclass if a custom cont...
void WrapperImageDataCallback(short *rfDataChannelData, int channelDatalinesPerDataset, int channelDataSamplesPerChannel, int channelDataTotalDatasets, short *rfDataArrayBeamformed, int beamformedLines, int beamformedSamples, int beamformedTotalDatasets, unsigned char *imageData, int imageWidth, int imageHeight, int imagePixelFormat, int imageSetsTotal, double timeStamp)
itk::SmartPointer< USAbstractControlInterface > m_ControlInterfaceCustom