フィルターのクリア

why i cant use "occupancyMap", it looks like a dont recognize it as a function.

1 回表示 (過去 30 日間)
clc
clear all
close all
map = robotics.BinaryOccupancyGrid(20,20);
setOccupancy(map,[8 8],0.2);
setOccupancy(map,[8 9],0.2);
setOccupancy(map,[8 7],0.2);
setOccupancy(map,[7 8],0.2);
setOccupancy(map,[6 8],0.2);
figure
show(map)
title('Warehouse Floor Plan')
% Create map that will be updated with sensor readings
estMap = occupancyMap(occupancyMatrix(map));
% Create a map that will inflate the estimate for planning
inflateMap = occupancyMap(estMap);
vMap = validatorOccupancyMap;
vMap.Map = inflateMap;
vMap.ValidationDistance = .1;
planner = plannerHybridAStar(vMap, 'MinTurningRadius', 4);
entrance = [1 40 0];
packagePickupLocation = [63 44 -pi/2];
route = plan(planner, entrance, packagePickupLocation);
route = route.States;
% Get poses from the route.
rsConn = reedsSheppConnection('MinTurningRadius', planner.MinTurningRadius);
startPoses = route(1:end-1,:);
endPoses = route(2:end,:);
rsPathSegs = connect(rsConn, startPoses, endPoses);
poses = [];
for i = 1:numel(rsPathSegs)
lengths = 0:0.1:rsPathSegs{i}.Length;
[pose, ~] = interpolate(rsPathSegs{i}, lengths);
poses = [poses; pose];
end
figure
show(planner)
title('Initial Route to Package')

採用された回答

Steven Lord
Steven Lord 2022 年 6 月 1 日
The occupancyMap function was introduced in Navigation Toolbox in release R2019b. It's not clear whether you have this product licensed and installed from the Products and Releases information on this post, but even if you do the release you're using predates the introduction of this function. You will need to upgrade to release R2019b or later and have Navigation Toolbox installed and licensed to use it.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeIntroduction to Installation and Licensing についてさらに検索

製品


リリース

R2017b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by