Esempio n. 1
0
        public bool ReadHardData(out short[] bufferCH1, out short[] bufferCH2, uint nReadLine, short[] level, THantekTrigSweep trigSweep, THantekChannelNumber trigSource, short trigLevel, THantekTriggerSlope trigSlope, short HTrigPosition, uint drawLength, out uint trigPoint, THantekInsertMode insertMode)
        {
            bool readSuccess = false;

            bufferCH1 = new short[nReadLine];
            bufferCH2 = new short[nReadLine];

            unsafe {
                uint trigPt = 0;
                fixed (short* pBufferCH1 = bufferCH1)
                fixed (short* pBufferCH2 = bufferCH2)
                fixed (short* pLevel = level) {
                    readSuccess = dsoReadHardData(m_deviceIndex, pBufferCH1, pBufferCH2, nReadLine, pLevel, (int)m_voltDivCH1, (int)m_voltDivCH2, (short)trigSweep, (short)trigSource, trigLevel, (short)trigSlope, (int)m_timeDiv, HTrigPosition, drawLength, &trigPt, (short)insertMode) != -1;
                }
                trigPoint = trigPt;
            }

            return readSuccess;
        }
        public bool ReadHardData(out short[] bufferCH1, out short[] bufferCH2, uint nReadLine, short[] level, THantekTrigSweep trigSweep, THantekChannelNumber trigSource, short trigLevel, THantekTriggerSlope trigSlope, short HTrigPosition, uint drawLength, out uint trigPoint, THantekInsertMode insertMode)
        {
            bool readSuccess = false;

            bufferCH1 = new short[nReadLine];
            bufferCH2 = new short[nReadLine];

            unsafe {
                uint trigPt = 0;
                fixed(short *pBufferCH1 = bufferCH1)
                fixed(short *pBufferCH2 = bufferCH2)
                fixed(short *pLevel     = level)
                {
                    readSuccess = dsoReadHardData(m_deviceIndex, pBufferCH1, pBufferCH2, nReadLine, pLevel, (int)m_voltDivCH1, (int)m_voltDivCH2, (short)trigSweep, (short)trigSource, trigLevel, (short)trigSlope, (int)m_timeDiv, HTrigPosition, drawLength, &trigPt, (short)insertMode) != -1;
                }
                trigPoint = trigPt;
            }

            return(readSuccess);
        }