⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fft_32768_ts201.tcl

📁 TigerSharc TS201 32-bit floating point FFT routine
💻 TCL
字号:
proc fft_32768_TS201 { {target_name "TS201"} {test_name "test1"} } {

  cd "..\\"
	set benchmark_name "fft_fxp16_TS201"
	set outdata_name "input"

	puts [format "Testing %s (%s) on target: %s" $benchmark_name $test_name $target_name]

  # build the program
	catch { dspprojectclose }
  dspprojectload [format "%s.dpj" $benchmark_name]
	dspprojectbuild Debug -all -wait

	# run the program
  #load the executable
  dspload [format "debug\\%s.dxe" $benchmark_name]  -wait
  dsprun -wait
  dspwaitforhalt
  puts "program was executed"

	set buf_size 32768
	set fid [open outputs\\outdata_32768.dat w]
  puts $fid
	set memory [lindex [lindex [dspgetmeminfo] 0] 0]
	set outdata [dspgetmemblock $memory [dsplookupsymbol $outdata_name] $buf_size -format Hexadecimal]

  set index 0
  while {$index < $buf_size} {
    set cur [lindex $outdata $index]
    set cur [format "0x%08x" $cur]

    set msb [string range $cur 2 5]
    set lsb [string range $cur 6 9]

    puts $fid $lsb
    puts $fid $msb

    set index [expr $index+1]
  }


	close $fid
  cd "tcl_TS201"
  puts "Done\n"

#	dspprojectclose
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -