This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] DCA1000EVM:与电路板直接对话以收集原始 ADC 数据的最佳方式?

Guru**** 2540720 points
Other Parts Discussed in Thread: IWR6843AOPEVM, DCA1000EVM, MMWAVEICBOOST

请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/sensors-group/sensors/f/sensors-forum/1390878/dca1000evm-best-way-to-directly-talk-to-the-board-to-collect-raw-adc-data

器件型号:DCA1000EVM
主题中讨论的其他器件:IWR6843AOPEVM、、 MMWAVEICBOOSTIWR6843

工具与软件:

尊敬的:

我的目标是直接与 DCA1000EVM 板交谈。 此电路板连接到 IWR6843AOPEVM + MMWAVEICBOOST 电路板。 我可以正确收集 ADC 数据并对这些数据进行后处理。 我现在的目标是在 python 等中实现实时数据收集脚本  

我的问题是、直接与电路板通信并在不使用 mmWave Studio 的情况下动态配置电路板设置的最佳方法是什么?
我目前正这样做、但必须有更好的方法:

我运行一个脚本来启动 mmWave Studio、并使用它运行 lua 脚本:

cmd /C "mmWaveStudio.exe /lua C:\Users\dagma\Documents\mmWave_script_IWR6843\auto_lua\src\auto_communication.lua"

这是我的运行方式:

    def start_mmwave_studio(self):
        subprocess.Popen(self.config['paths']['cmd_path'], cwd=self.config['paths']['studio_runtime_path'])
        self.write_to_file("Starting mmWave Studio...")
        time.sleep(110)
        self.write_to_file("mmWave Studio should be ready now.")


这是我的 lua 脚本:
-------- CONSTANTS ----------------------------------------
COM_PORT=6
BAUDRATE= 115200

RADARSS_BIN_PATH =  "C:\\ti\\mmwave_studio_02_01_01_00\\rf_eval_firmware\\radarss\\xwr68xx_radarss.bin"
MASTERSS_BIN_PATH = "C:\\ti\\mmwave_studio_02_01_01_00\\rf_eval_firmware\\masterss\\xwr68xx_masterss.bin"

-----------------------------------------------------------

-------- RADAR SETTINGS -----------------------------------
-- General
NUM_TX = 2
NUM_RX = 4

-- ProfileConfig
START_FREQ = 60 -- GHz
IDLE_TIME = 100 -- us
RAMP_END_TIME = 60 -- us
ADC_START_TIME = 6 --us
FREQ_SLOPE = 29,982 -- MHz/us
ADC_SAMPLES = 256 -- ADC Samples originally 256
SAMPLE_RATE = 10000 -- ksps
RX_GAIN = 30 -- dB was orginially 30
TX_START_TIME = 0

-- FrameConfig
START_CHIRP_TX = 0
END_CHIRP_TX = 1 
NUM_FRAMES = 0 -- Set this to 0 to continuously stream data
CHIRP_LOOPS = 128 
PERIODICITY = 40 -- ms
-----------------------------------------------------------

-------- INIT ---------------------------------------------

dofile("C:\\ti\\mmwave_studio_02_01_01_00\\mmWaveStudio\\Scripts\\AR1xInit.lua")
ar1.selectRadarMode(0)
ar1.selectCascadeMode(0)
ar1.FullReset()
ar1.SOPControl(2)
ar1.Connect(COM_PORT,BAUDRATE,1000)
ar1.Calling_IsConnected()
-----------------------------------------------------------

-------- DEVICE SETTINGS ----------------------------------
ar1.frequencyBandSelection("60G")
ar1.SelectChipVersion("IWR6843")
ar1.deviceVariantSelection("IWR6843")
-----------------------------------------------------------

-------- DOWNLOAD FIRMARE ---------------------------------
ar1.DownloadBSSFw(RADARSS_BIN_PATH)
ar1.GetBSSFwVersion()
ar1.DownloadMSSFw(MASTERSS_BIN_PATH)
ar1.GetMSSFwVersion()
ar1.PowerOn(0, 1000, 0, 0)
ar1.RfEnable()
ar1.GetMSSFwVersion()
ar1.GetBSSFwVersion()
-----------------------------------------------------------

-------- STATIC CONFIG ------------------------------------
ar1.ChanNAdcConfig(1, 1, 1, 1, 1, 1, 1, 2, 1, 0)
ar1.LPModConfig(0, 0)
ar1.RfInit()
-----------------------------------------------------------

-------- DATA CONFIG --------------------------------------
ar1.DataPathConfig(513, 1216644097, 0)
ar1.LvdsClkConfig(1, 1)
ar1.LVDSLaneConfig(0, 1, 1, 0, 0, 1, 0, 0)
-----------------------------------------------------------

-------- SENSOR CONFIG ------------------------------------
ar1.ProfileConfig(0, 60, 100, 6, 60, 0, 0, 0, 0, 0, 0, 29.982, 0, 256, 10000, 0, 131072, 30)
ar1.ChirpConfig(0, 0, 0, 0, 0, 0, 0, 1, 0, 0)
ar1.DisableTestSource(0)
ar1.FrameConfig(0, 0, 0, 128, 40, 0, 0, 1)
-----------------------------------------------------------

-------- ETHERNET -----------------------------------------
ar1.GetCaptureCardDllVersion()
ar1.SelectCaptureDevice("DCA1000")
ar1.CaptureCardConfig_EthInit("192.168.33.30", "192.168.33.180", "12:34:56:78:90:12", 4096, 4098)
ar1.CaptureCardConfig_Mode(1, 2, 1, 2, 3, 30)
ar1.CaptureCardConfig_PacketDelay(25)
ar1.GetCaptureCardFPGAVersion()
-----------------------------------------------------------

-------- CAPTURE DATA -------------------------------------
ar1.CaptureCardConfig_StartRecord("C:\\ti\\mmwave_studio_02_01_01_00\\mmWaveStudio\\PostProc\\adc_data_post_crash.bin", 0)

ar1.StartFrame()
os.execute("timeout /t 2 /nobreak")
--ar1.StopFrame()
--os.execute("timeout /t 3 /nobreak")
--ar1.StartMatlabPostProc("C:\\ti\\mmwave_studio_02_01_01_00\\mmWaveStudio\\PostProc\\auto_collection\\adc_data.bin")
-----------------------------------------------------------


但肯定有更好的方法来运行这些 lua 命令到电路板并直接与电路板通信。 有技巧或经验的人?

我还想知道雷达 API 是否有良好的文档源、其中包含我们可以发送到雷达的所有不同命令。

如果需要更多信息、请告诉我!  

提前感谢。

此致、
DAG.