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.

AWR1843BOOST: AWR1843BOOST串口实时读取数据

Part Number: AWR1843BOOST

您好,目前我需要做的是利用AWR1843BOOST串口实时读取数据,

问题1:根据这个文件串口读取数据www.ti.com.cn/.../zhcab69.pdf

 请问这个文件相关资源在哪里可以获取?

问题二:目前板子烧录的程序是SDK3.6中XWR1843的demo.bin文件,目前也通过MATLAB写了一个串口的读取数据程序但是总是数据采集不到请问如何解决?下面是我的代码和雷达前端参数配置 这个参数我用mmwave studio可以实现采集,

clc;clear
clearvars; close all
delete(instrfind);
% 配置参数
configfile = "D:\seven\Desktop\采集数据串口\xxxw.cfg";

% 读取cfg文件
config = cell(1,100);
fid = fopen(configfile, 'r');
if fid == -1
    fprintf('File %s not found!\n', configfile);
    return;
else
    fprintf('Opening configuration file %s ...\n', configfile);
end
tline = fgetl(fid);
k=1;
while ischar(tline)
    config{k} = tline;
    tline = fgetl(fid);
    k = k + 1;
end
config = config(1:k-1);
fclose(fid);


%%%% UART COM PORT:
comPortString_UART = 'COM4';
UART_sphandle = serial(comPortString_UART,'BaudRate',115200);
set(UART_sphandle,'Parity','none')
set(UART_sphandle,'Terminator','LF')
fopen(UART_sphandle);

%%%% DATA COM PORT:
comPortString_data = 'COM3';
DATA_sphandle = serial(comPortString_data,'BaudRate',921600);
set(DATA_sphandle,'Terminator', '');
set(DATA_sphandle,'InputBufferSize', 65536);
set(DATA_sphandle,'Timeout',10);
set(DATA_sphandle,'ErrorFcn',@dispError);
set(DATA_sphandle,'BytesAvailableFcnMode','byte');
set(DATA_sphandle,'BytesAvailableFcnCount', 2^16+1);%BYTES_AVAILABLE_FCN_CNT);
set(DATA_sphandle,'BytesAvailableFcn',@readUartCallbackFcn);
fopen(DATA_sphandle);

% 
mmwDemoCliPrompt = char('mmwDemo:/>');

%Send CLI configuration to AWR1843
fprintf('Sending configuration from %s file to AWR1843 ...\n', configfile);
for k=1:length(config)
    command = config{k};
    fprintf(UART_sphandle, command);
    fprintf('%s\n', command);
    echo = fgetl(UART_sphandle); % Get an echo of a command
    done = fgetl(UART_sphandle); % Get "Done"
    prompt = fread(UART_sphandle, size(mmwDemoCliPrompt,2)); % Get the prompt back
end

% 读取数据
RX_num = 4;
TX_num = 1;
Per_Frame_Chirps_Num =10;
ADC_Sample_Num = 256;

% 读取数据
[bytevec, byteCount] = fread(DATA_sphandle, bytesToRead,RX_num*TX_num*Per_Frame_Chirps_Num*ADC_Sample_Num*2*2, 'uint8');

% 配置文件xxxw.cfg
sensorStop
flushCfg
dfeDataOutputMode 1
channelCfg 15 1 0
adcCfg 2 1
adcbufCfg -1 0 1 1 1
profileCfg 0 77 50 3.59 65.50 4.81 0 61.460 1 256 4300 0 0 30
chirpCfg 0 0 0 0 0 0 0 1
chirpCfg 1 1 0 0 0 0 0 0
frameCfg 0 0 2 1024 5 1 0
lowPower 0 0
guiMonitor -1 1 1 0 0 0 1
cfarCfg -1 0 2 8 4 3 0 15 1
cfarCfg -1 1 0 4 2 3 1 15 1
multiObjBeamForming -1 1 0.5
clutterRemoval -1 0
calibDcRangeSig -1 0 -5 8 256
extendedMaxVelocity -1 0
lvdsStreamCfg -1 0 0 0
compRangeBiasAndRxChanPhase 0.0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
measureRangeBiasAndRxChanPhase 0 1.5 0.2
CQRxSatMonitor 0 3 5 121 0
CQSigImgMonitor 0 127 4
analogMonitor 0 0
aoaFovCfg -1 -90 90 -90 90
cfarFovCfg -1 0 0 8.92
cfarFovCfg -1 1 -1 1.00
calibData 0 0 0
sensorStart



问题三:另外如何实现实时采集数据,我目前想法是设置无限制帧,每次读取一定帧数内容,保存在缓存区内,在继续读取数据,缓存区单独存放在另外变量中,但具体还不知道如何实现。有没有相关文档?