argos3-simulator
如何修改控制器:
CVector2:
class CVector2 {
friend class CRotationMatrix2;
friend class CTransformationMatrix2;
public:
/** The <em>x</em> axis */
static const CVector2 X;
/** The <em>y</em> axis */
static const CVector2 Y;
/**
* Class constructor.
* It initializes the vector to (0,0).
* @see ZERO
*/
CVector2() :
m_fX(0.0),
m_fY(0.0) {
}
/**
* Class constructor.
* It initializes the vector from Cartesian coordinates.
* @param f_x The <em>x</em> coordinate.
* @param f_y The <em>y</em> coordinate.
* @see Set()
*/
CVector2(Real f_x,
Real f_y) :
m_fX(f_x),
m_fY(f_y) {
}
/**
* Sums the passed vector to this vector.
* @param c_vector2 The other vector.
* @returns A reference to this vector.
*/
inline CVector2& operator+=(const CVector2& c_vector2) {
m_fX += c_vector2.m_fX;
m_fY += c_vector2.m_fY;
return *this;
}
......
};
struct SReading {
CRadians Angle;
Real Distance; // in cm from the center of the robot (about 10cm from the border)
SReading() :
Angle(0.0f),
Distance(0.0f) {}
SReading(const CRadians& c_angle,
Real f_distance) :
Angle(c_angle),
Distance(f_distance) {
}
};
typedef std::vector<SReading> TReadings;
参考:https://git.mistlab.ca/isvogor/e-pucky/tree/260fc947afde2a04132b71c79d4204629419b576/swarms/controllers/cpp/collision_avoidance
锁定修改文件:footbot_diffusion_reference.cpp
读懂每个文件的函数意义:
Swarmanoid hardware
Foot-bots
The foot-bot is a particular configuration of modules based on the marXbot robotic platform. The foot-bot configuration includes a top CPU and vision module, a distance scnaner, a range and bearing module, a self-assembling module and a basic (mobility & battery) module.
Foot-bot Features:
- Compact size: 直径17 cm x 29 cm, 1.8 kg
- Modular system
- High computational power including float processing
- Distance scanner measuring distance up to 1.5m
- Two cameras, one mounted as omnicamera
- Self-assembling mechanism
- Hot-swappable battery
- Treel mobility system
IR-sensor:https://www.electronicshub.org/ir-sensor/
有8个IR-sensor,搞不明白怎么测量的角度?
The returned data of each sensor is
- A reading (a decaying exponential) that depends on the distance between the sensor and the object being detected. This reading is 0 when nothing is detected, and it increases exponentially to 1 when detected objects are closer.
- The angle is measured between the nose of the robot (local X axis) and the angle at which the sensor is located on the body of the robot.
所以,靠的是机器人身上的传感器的位置来计算的正面与障碍物的角度。
argos3-simulator的更多相关文章
- unable to boot the simulator,无法启动模拟器已解决
突然模拟器报错:unable to boot the simulator(无法启动模拟器) 试了好几种解决办法,删除所有的模拟器重启以后再添加,删除钥匙串登陆中的证书,重新安装Xcode都不行 最后通 ...
- Unable to run app in Simulator
xcode6 beta出现 “Unable to run app in Simulator” 错误提示,之前一直用着好好的,重启xcode就可以了. xcode6 beta出现 “Unable to ...
- 给ros安装arbotix simulator仿真环境
首先下载程序包.编译.安装. cd ~/catkin_ws/src git clone https://github.com/pirobot/rbx1.git cd rbx1 git checkout ...
- XCode6的iOS Simulator 文件保存位置
我现在用的是XCode6.4,模拟器系统是iOS 8.4.其他版本可能会略有差异. 进入Finder,前往"~/Library/Developer/CoreSimulator/Devices ...
- Unable to open liblaunch_sim.dylib. Try reinstalling Xcode or the simulator
关于Xcode7 Beta报错 simulator runtime is not available. Unable to open liblaunch_sim.dylib Try reinstall ...
- iOS Simulator功能介绍关于Xamarin IOS开发
iOS Simulator功能介绍关于Xamarin IOS开发 iOS Simulator功能介绍 在图1.38所示的运行效果中,所见到的类似于手机的模型就是iOS Simulator.在没有iPh ...
- 安装arbotix simulator仿真环境--9
原创博客:转载请表明出处:http://www.cnblogs.com/zxouxuewei/ 周学伟 安装之前:首先确保已经正常制作了ros工作空间并且安装了rbx1功能包: cd ~/catki ...
- NewRelicAgent(CustomAnalyticEvent.cxx.o), building for iOS simulator, but linking in object file built for OSX, for architecture x8(botched)
昨天遇到一个问题,在项目swift1.2适配swift2.0的过程中,修改完毕之后,运行报错如下: /Pods/NewRelicAgent/NewRelic_iOS_Agent_5.1.0/NewRe ...
- 【转】Xcode中的iOS模拟器(iOS Simulator)的介绍和使用心得
iOS模拟器简介 iOS功能简介 iOS模拟器,是在Mac下面开发程序时,开发iOS平台的程序时候,可以使用的辅助工具. 其功能是,帮你模拟iOS平台设备,在模拟器上运行对应的程序,以方便你没有实体设 ...
- TI-Davinci开发系列之二使用CCS5.2TI Simulator模拟环境调试DSP程序
上接博文<TI-Davinci开发系列之一CCS5.2的安装及注意事项>. 如何没有实际的开发板或者仿真器,可以使用CCS自带的TISimulator来学习与熟悉CCS开发调试环境.下面是 ...
随机推荐
- scala容器使用
花了两个小时左右,学习了一下scala语言, 由于scala运行在jvm之上, 可以使用java容器也可以使用scala自带的容器. import java.util import java.util ...
- php中的变量作用域
<?php include_once $_SERVER['DOCUMENT_ROOT'].'/includes/db.inc.php'; function totalJokes() { try{ ...
- vue源码解读1
前言 vue是一个非常典型的MVVM框架,它的核心功能一是双向数据绑定系统,二是组件化开发系统.那么本文是以一种通俗易懂的的角度来实现一个简单 的双向数据绑定系统,如果你用过vue却对vue的实现原理 ...
- SpringBoot非官方教程 | 第十六篇:用restTemplate消费服务
转载请标明出处: 原文首发于:https://www.fangzhipeng.com/springboot/2017/07/11/springboot11-restTemplate/ 本文出自方志朋的 ...
- SpringBoot非官方教程 | 第九篇: springboot整合Redis
转载请标明出处: 原文首发于:https://www.fangzhipeng.com/springboot/2017/07/11/springboot9-redis/ 本文出自方志朋的博客 这篇文章主 ...
- 【2017 ICPC亚洲区域赛沈阳站 K】Rabbits(思维)
Problem Description Here N (N ≥ 3) rabbits are playing by the river. They are playing on a number li ...
- DLL DEF文件编写方法 VC++ 调用、调试DLL的方法 显式(静态)调用、隐式(动态)调用
DLL 文件编写方法: 1.建立DLL工程 2.声明.定义要导出的函数 BOOL WINAPI InitDlg( HWND hTabctrl,TShareMem* pTshare,CRect* prc ...
- 【原创】面向对象作业:选课系统中用pickle储存多个对象间组合引用关系的那些坑
转载请注明出处:https://www.cnblogs.com/oceanicstar/p/9030121.html 想直接看结论先提前列出: 1.存储一个对象,文件不是真的给你存储的了对象这种东西, ...
- rabbitMq install for windows
1.下载,erlang 安装rabbitmq需要erlang,下载erlang:http://www.erlang.org/downloads 2.下载rabbitMq rabbitMQ安装,查看安装 ...
- react脚手架搭建1
23:01:17 react脚手架搭建 (个人用的是webstorm,所以分享下webstorm中的创建react脚手架项目的方法) 1.创建新项目(前提是下载nodejs环境) 2.下载好在webs ...