Is it possible to use two different toolboxes at once?
2 次查看(过去 30 天)
显示 更早的评论
Hi!
I need to write a code that allows a Lego Mindstorms Ev3 robot to travel in a straight line until it encounters a magnetic field. The problem is that I have one toolbox for the code that the magnetic sensor uses and another toolbox that makes the robot travel in a straight line. Is it possible to make use of both toolboxes at once?
The toolbox I use for the magnetic sensor I got from
https://wiki.qut.edu.au/download/attachments/172135780/EV3.zip?version=1&modificationDate=1391352088000&api=v2
And the toolbox for the movement of the robot is Mathlabs own Lego Mindstorms toolbox and the code I use is the one you get when you type edit('gostraight_closeloop.m')
When I need to use the toolbox for the magnetic sensor I need to type:
b = Brick('ioType','usb');
And when I need to use mathlabs own toolbox to move the robot I need to type:
mylego = legoev3('usb');
Is it possible that I can use both of these toolboxes at once?
0 个评论
回答(1 个)
Image Analyst
2018-1-4
Yes. Nearly everyone here has multiple toolboxes and uses functions from several of them in the same program. It won't be a problem.
3 个评论
Image Analyst
2018-1-5
I don't know anything about the Lego functionality. What does "at the same time" mean to you? In the same program, like one line of code after the other? Or truly at the same time like you have the Parallel Processing Toolbox and you have completely separate threads running different code on each CPU?
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 ROS Toolbox Supported Hardware 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!