matlab_gps_example.m
来自「matlab开发的GPS信号simulator」· M 代码 · 共 19 行
M
19 行
% Create a serial port object.
obj1 = instrfind('Type', 'serial', 'Port', 'COM4', 'Tag', '');
% Create the serial port object if it does not exist
% otherwise use the object that was found.
if isempty(obj1)
obj1 = serial('COM4');
else
fclose(obj1);
obj1 = obj1(1);
end
% Set the BaudRate
obj1.BaudRate = 4800;
% Connect to instrument object, obj1.
fopen(obj1);
% We only want the strings with $GPGLL
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?