新聞中心

        EEPW首頁 > 模擬技術(shù) > 設(shè)計應(yīng)用 > 利用MAXQ7667確定超聲傳感器的諧振頻率和阻尼特性

        利用MAXQ7667確定超聲傳感器的諧振頻率和阻尼特性

        作者: 時間:2012-09-14 來源:網(wǎng)絡(luò) 收藏
        ; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BACKGROUND-COLOR: rgb(255,255,255); orphans: 2; widows: 2; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px">  {

          // Use the "damping_half_time" routine to measure the time in μs that it takes for the

          // ringing to drop to half of the peak value. Do this at more than one frequency so that

          // one of the frequencies will be within range of the transducer.

          wait2measure = damping_half_time(128, 88); //Measure damping time at 35kHz.

          halfpeak = damping_half_time(256, 101); //Measure damping time at 40kHz.

          if (wait2measure halfpeak) {wait2measure = halfpeak;} // Save the longest time.

          halfpeak = damping_half_time(384, 113); //Measure damping time at 45kHz.

          if (wait2measure halfpeak) {wait2measure = halfpeak;} // Save the longest time.

          // Repeatedly pulse the transducer with a constant width pulse while sweeping the receiver

          // frequency. Use the half-time value from the damping test (wait2measure) for the interval

          // between pulse transmission and reading LPFD (lowpass filter data).

          PLLF_bit.PLLF = 0; // Start the sweep at 30kHz.

          BPH = 77; // Pulse ~6.3μs. This value is easy to maintain over frequency.

          peak = 0;

          number_of_steps = 0;

          do // Sweep from 30kHz to 50kHz with step_size * 39.062500kHz.

          {

          usWaitTimer2(5000); // Wait 5ms for the frequency to settle.

          STIM = 0; // Reset the system timer. It controls the Pulse to LPF read time.

          BPH_bit .BSTT = 1; // Send burst.

          while(STIM wait2measure) {} // Wait the specified amount of time for the ringing to dampen.

          lpfdata[number_of_steps]= LPFD; // Store the LPF reading.

          if(lpfdata[number_of_steps]> peak) {peak = lpfdata[number_of_steps];} //Save the peak value.

          number_of_steps++;

          PLLF_bit.PLLF = number_of_steps * step_size; // Increase the frequency.

          BPH = 77 + number_of_steps; // Increase the duty cycle to maintain pulse width.

          } while (PLLF 512-step_size);



        關(guān)鍵詞: MAXQ7667 超聲傳感器 諧振頻率 阻尼特性

        評論


        相關(guān)推薦

        技術(shù)專區(qū)

        關(guān)閉
        主站蜘蛛池模板: 油尖旺区| 旺苍县| 深州市| 泸溪县| 光山县| 长乐市| 侯马市| 南乐县| 阿拉善盟| 合山市| 独山县| 比如县| 登封市| 东乌珠穆沁旗| 上思县| 伊通| 岱山县| 洛宁县| 双峰县| 隆回县| 思南县| 随州市| 阿图什市| 雷山县| 云浮市| 友谊县| 平泉县| 凤凰县| 南陵县| 金沙县| 五莲县| 桃园县| 上饶县| 措勤县| 沅陵县| 湄潭县| 双柏县| 彩票| 科尔| 隆化县| 伊吾县|