<s>
Asynchronous	B-Application
multi-body	I-Application
framework	I-Application
(	O
AMBF	O
)	O
is	O
an	O
open-source	B-License
3D	O
versatile	O
simulator	O
for	O
robots	O
developed	O
in	O
April	O
2019	O
.	O
</s>
<s>
The	O
framework	O
integrates	O
a	O
real	O
surgeon	O
master	O
console	O
,	O
haptic	O
or	O
not	O
,	O
to	O
control	O
simulated	B-Application
robots	I-Application
in	O
real-time	O
.	O
</s>
<s>
It	O
also	O
provides	O
a	O
Python	B-Language
Client	O
to	O
interact	O
easily	O
with	O
the	O
simulated	O
bodies	O
and	O
train	O
neural	B-Architecture
networks	I-Architecture
on	O
real-time	O
data	O
with	O
in-loop	O
simulation	O
.	O
</s>
<s>
The	O
AMBF	O
simulator	O
uses	O
several	O
external	O
packages	O
including	O
CHAI-3D	O
for	O
the	O
integration	O
of	O
input	O
devices	O
,	O
Bullet	B-Application
Physics	I-Application
for	O
simulating	O
rigid	O
and	O
soft	O
bodies	O
,	O
Open-GL	B-Application
,	O
GLFW	B-Language
.	O
</s>
<s>
It	O
is	O
compatible	O
with	O
Ubuntu	B-Operating_System
16.04	O
and	O
Ubuntu	B-Operating_System
18.04	O
but	O
it	O
has	O
been	O
also	O
tested	O
on	O
macOs	B-Application
Maverick	O
and	O
macOS	B-Application
Mojave	O
.	O
</s>
<s>
The	O
asynchronous	B-Application
multi-body	I-Application
framework	I-Application
introduces	O
a	O
new	O
robot	O
description	O
file	O
format	O
:	O
the	O
AMBF	O
description	O
format	O
or	O
ADF	O
.	O
</s>
<s>
The	O
description	O
format	O
is	O
based	O
on	O
YAML	B-Protocol
which	O
allows	O
to	O
modify	O
,	O
create	O
or	O
test	O
multi-bodies	O
in	O
an	O
easy	O
way	O
thanks	O
to	O
its	O
human	O
readability	O
.	O
</s>
<s>
The	O
simulator	O
is	O
integrated	O
with	O
ROS	B-Application
(	O
Robot	B-Application
Operating	I-Application
System	I-Application
)	O
,	O
a	O
middle-ware	B-General_Concept
that	O
handles	O
the	O
communication	O
with	O
robots	O
.	O
</s>
<s>
ROS	B-Application
allows	O
to	O
control	O
the	O
simulated	B-Application
robot	I-Application
through	O
external	O
codes	O
,	O
and	O
it	O
also	O
offers	O
useful	O
plotting	O
(	O
RQT	O
Plot	O
)	O
and	O
logging	O
(	O
ROS	B-Application
Bag	O
)	O
tools	O
.	O
</s>
<s>
The	O
Asynchronous	O
Framework	O
remains	O
isolated	O
from	O
ROS-based	O
run-time	O
mechanics	O
while	O
being	O
able	O
to	O
leverage	O
its	O
tools	O
.	O
</s>
<s>
High-speed	O
asynchronous	O
communication	O
is	O
implemented	O
via	O
ROS-topic	O
in	O
the	O
AMBF	O
framework	O
library	O
.	O
</s>
<s>
Both	O
C++	B-Language
and	O
Python	B-Language
can	O
be	O
used	O
to	O
interact	O
with	O
simulated	B-Application
robots	I-Application
,	O
multi	O
bodies	O
,	O
kinematic	O
and	O
visual	O
objects	O
in	O
the	O
simulator	O
.	O
</s>
<s>
The	O
Python	B-Language
Client	O
provides	O
the	O
possibility	O
to	O
control	O
different	O
afObject	O
while	O
keeping	O
a	O
high	O
communication	O
speed	O
.	O
</s>
<s>
This	O
allows	O
managing	O
the	O
ROS	B-Application
communication	O
making	O
the	O
process	O
of	O
controlling	O
simulated	O
bodies	O
much	O
easier	O
compared	O
to	O
any	O
other	O
simulator	O
.	O
</s>
<s>
The	O
communication	O
between	O
the	O
Client	O
and	O
the	O
AMBF	O
simulator	O
is	O
managed	O
through	O
ROS	B-Application
as	O
middle-ware	B-General_Concept
.	O
</s>
<s>
The	O
Client	O
uses	O
bidirectional	O
communication	O
such	O
that	O
it	O
is	O
possible	O
to	O
set	O
commands	O
to	O
the	O
bodies	O
and	O
at	O
the	O
same	O
time	O
to	O
read	O
their	O
states	O
using	O
a	O
library	O
of	O
Python	B-Language
functions	O
.	O
</s>
<s>
This	O
creates	O
callable	O
objects	O
from	O
ROS	B-Application
topics	O
and	O
initiates	O
a	O
shared	O
pool	O
of	O
threads	O
for	O
bidirectional	O
communication	O
.	O
</s>
<s>
Each	O
callable	O
object	O
has	O
a	O
WatchDog	B-Application
timer	I-Application
that	O
resets	O
commands	O
if	O
the	O
timing	O
condition	O
fails	O
.	O
</s>
<s>
Moreover	O
,	O
the	O
Python	B-Language
Client	O
is	O
used	O
for	O
the	O
training	O
of	O
reinforcement	O
learning	O
agents	O
on	O
real-time	O
data	O
.	O
</s>
<s>
Others	O
can	O
be	O
easily	O
included	O
in	O
the	O
simulator	O
by	O
defining	O
them	O
in	O
the	O
input_device.yaml	O
file	O
.	O
</s>
<s>
The	O
interaction	O
between	O
bodies	O
is	O
provided	O
by	O
the	O
Bullet	B-Application
's	I-Application
solver	O
,	O
which	O
handles	O
the	O
dynamics	O
of	O
both	O
rigid	O
and	O
soft	O
bodies	O
.	O
</s>
<s>
The	O
position	O
of	O
each	O
node	O
is	O
computed	O
using	O
the	O
symplectit	B-Algorithm
Euler	I-Algorithm
method	I-Algorithm
at	O
each	O
time-step	O
.	O
</s>
<s>
AMBF	O
includes	O
an	O
add-on	O
with	O
Blender	B-Application
that	O
allows	O
the	O
user	O
to	O
create	O
new	O
models	O
or	O
modify	O
existing	O
models	O
according	O
to	O
their	O
purpose	O
.	O
</s>
<s>
Blender	B-Application
has	O
large	O
community	O
support	O
for	O
graphic	O
designers	O
and	O
represents	O
an	O
immediate	O
and	O
intuitive	O
interface	O
for	O
the	O
user	O
to	O
create	O
or	O
modify	O
bodies	O
.	O
</s>
<s>
The	O
Blender-to-AMBF	O
add-on	O
is	O
bidirectional	O
meaning	O
that	O
the	O
user	O
can	O
both	O
import	O
objects	O
defined	O
through	O
the	O
AMBF	O
file	O
format	O
and	O
create	O
both	O
high	O
and	O
low-resolution	O
files	O
and	O
subsequently	O
AMBF	O
YAML	B-Protocol
configuration	O
files	O
of	O
complex	O
robots	O
and	O
multi-bodies	O
.	O
</s>
