Compare commits

..
12 Commits
Author SHA1 Message Date
Pablo Garrido 0e41ea6522 3.0.4 2022-09-28 15:57:21 +02:00
Pablo Garrido d1b916ced2 Changelog 2022-09-28 15:57:04 +02:00
Pablo Garrido 4f686e8dc1 Fix Datawriter destruction (#169)
Signed-off-by: Pablo Garrido <pablogs9@gmail.com>

Signed-off-by: Pablo Garrido <pablogs9@gmail.com>
2022-08-23 12:42:03 +02:00
cmraaron d4be840332 Synchronise predicate (#160)
* ensure synchronised access to our predicate

Signed-off-by: Aaron <aaron.lipinski@cm-robotics.com>

* release lock before signalling

Signed-off-by: Aaron <aaron.lipinski@cm-robotics.com>

Signed-off-by: Aaron <aaron.lipinski@cm-robotics.com>
2022-08-19 09:17:36 +02:00
Pablo Garrido da7fb682e9 3.0.3 2022-06-13 07:46:16 +02:00
Pablo Garrido c1e0ce9df7 Changelog
Signed-off-by: Pablo Garrido <pablogs9@gmail.com>
2022-06-13 07:46:11 +02:00
Antonio Cuadros 5f36f4c943 Build ROS2 from source on snap (#153)
* Build ROS2 from source on snap

* Update
2022-06-09 15:38:17 +02:00
Pablo Garrido c89776e1fd Fix memory leak in graph manager (#147)
Signed-off-by: Pablo Garrido <pablogs9@gmail.com>
2022-06-08 14:12:55 +02:00
Pablo Garrido 4a750220d2 3.0.2 2022-05-25 09:09:39 +02:00
Pablo Garrido b5a0d0b6ee Update changelog 2022-05-25 09:09:27 +02:00
Antonio Cuadros 114a043ee2 Revert test humble release (#142) 2022-05-24 11:11:32 +02:00
Antonio CuadrosandPablo Garrido b0ebf5ab3f Humble release (#135)
* Modify CI

* Update

Signed-off-by: Pablo Garrido <pablogs9@gmail.com>

* Update

Signed-off-by: Pablo Garrido <pablogs9@gmail.com>

* Update .github/workflows/ci.yml

* Update .github/workflows/ci.yml

* Modify CI

* Update to ubuntu latest

* Use pre-release repository

* Use ubuntu-20.04

* Fix

* Revert changes

Co-authored-by: Pablo Garrido <pablogs9@gmail.com>
2022-05-20 12:35:11 +02:00
11 changed files with 84 additions and 85 deletions
+10 -10
View File
@@ -3,27 +3,27 @@ name: CI micro-ROS Agent
on:
pull_request:
branches:
- 'jazzy'
- 'humble'
schedule:
- cron: '33 6 * * *'
jobs:
microros_agent_ci:
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest ]
ros_distribution: [ jazzy ]
os: [ ubuntu-20.04 ]
ros_distribution: [ humble ]
include:
- docker_image: ubuntu:24.04
ros_distribution: jazzy
- docker_image: ubuntu:jammy
ros_distribution: humble
container:
image: ${{ matrix.docker_image }}
image: ubuntu:jammy
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/setup-ros@0.7.7
- uses: actions/checkout@v2
- uses: ros-tooling/setup-ros@0.3.2
with:
use-ros2-testing: false
required-ros-distributions: ${{ matrix.ros_distribution }}
@@ -31,7 +31,7 @@ jobs:
run: |
apt-get install ros-${{ matrix.ros_distribution }}-micro-ros-msgs
apt-get install ros-${{ matrix.ros_distribution }}-rmw-fastrtps-cpp
- uses : ros-tooling/action-ros-ci@0.3.13
- uses : ros-tooling/action-ros-ci@0.2.5
with:
package-name: "micro_ros_agent"
target-ros2-distro: ${{ matrix.ros_distribution }}
+6 -20
View File
@@ -2,30 +2,16 @@
Changelog for package micro-ros_agent
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5.0.2 (2024-05-31)
3.0.4 (2022-09-28)
------------------
* Jazzy Release
* Bump Micro XRCE-DDS Agent (`#226 <https://github.com/micro-ROS/micro-ROS-Agent/issues/226>`_)
* Fix Datawriter destruction (`#169 <https://github.com/micro-ROS/micro-ROS-Agent/issues/169>`_)
* Synchronise predicate (`#160 <https://github.com/micro-ROS/micro-ROS-Agent/issues/160>`_)
5.0.1 (2024-01-29)
3.0.3 (2022-06-13)
------------------
* Fix thread include (`#216 <https://github.com/micro-ROS/micro-ROS-Agent/issues/216>`_) (`#218 <https://github.com/micro-ROS/micro-ROS-Agent/issues/218>`_)
* Fix memory leak in graph manager (`#147 <https://github.com/micro-ROS/micro-ROS-Agent/issues/147>`_)
5.0.0 (2023-06-06)
------------------
* Add empty type key hash to GraphCache (`#189 <https://github.com/micro-ROS/micro-ROS-Agent/issues/189>`_)
* Contributors: Antonio Cuadros
4.0.2 (2022-09-28)
------------------
* Fix Datawriter destruction (`#169 <https://github.com/micro-ROS/micro-ROS-Agent/issues/169>`_) (`#170 <https://github.com/micro-ROS/micro-ROS-Agent/issues/170>`_)
* Synchronise predicate (`#160 <https://github.com/micro-ROS/micro-ROS-Agent/issues/160>`_) (`#165 <https://github.com/micro-ROS/micro-ROS-Agent/issues/165>`_)
4.0.1 (2022-06-13)
------------------
* Fix memory leak in graph manager (`#147 <https://github.com/micro-ROS/micro-ROS-Agent/issues/147>`_) (`#148 <https://github.com/micro-ROS/micro-ROS-Agent/issues/148>`_)
4.0.0 (2022-05-25)
3.0.2 (2022-05-25)
------------------
3.0.1 (2022-03-25)
+1 -1
View File
@@ -26,7 +26,7 @@ if(NOT xrceagent_FOUND)
GIT_REPOSITORY
https://github.com/eProsima/Micro-XRCE-DDS-Agent.git
GIT_TAG
v2.4.3
ros2
PREFIX
${PROJECT_BINARY_DIR}/agent
INSTALL_DIR
@@ -65,7 +65,6 @@
#include <string>
#include <memory>
#include <map>
#include <thread>
namespace uros {
namespace agent {
+1 -1
View File
@@ -2,7 +2,7 @@
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>micro_ros_agent</name>
<version>5.0.2</version>
<version>3.0.4</version>
<description>micro-ROS Agent package</description>
<maintainer email="pablogarrido@eprosima.com">Pablo Garrido</maintainer>
<maintainer email="antoniocuadros@eprosima.com">Antonio Cuadros</maintainer>
@@ -374,8 +374,8 @@ void GraphManager::add_datawriter(
"rmw_fastrtps_cpp", participant_guid);
const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(writer_qos);
graphCache_.add_entity(datawriter_gid, topic_name, type_name,
rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, false);
graphCache_.add_entity(datawriter_gid, topic_name,
type_name, participant_gid, qos_profile, false);
}
void GraphManager::remove_datawriter(
@@ -411,13 +411,8 @@ void GraphManager::add_datareader(
"rmw_fastrtps_cpp", participant_guid);
const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(reader_qos);
// TODO(acuadros95): Use typesupport to calculate type hash on micro-ROS and save and get it from reader_qos.user_data.
// Related PRs:
// https://github.com/ros2/rmw_dds_common/pull/70
// https://github.com/ros2/rmw_fastrtps/pull/671
// https://github.com/ros2/rmw_fastrtps/pull/680
graphCache_.add_entity(datareader_gid, topic_name, type_name,
rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, true);
graphCache_.add_entity(datareader_gid, topic_name,
type_name, participant_gid, qos_profile, true);
}
void GraphManager::remove_datareader(
@@ -54,14 +54,14 @@ bool ParticipantEntitiesInfoTypeSupport::serialize(
eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast<char *>(payload->data),
payload->max_size);
eprosima::fastcdr::Cdr scdr(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN,
eprosima::fastcdr::DDS_CDR);
eprosima::fastcdr::Cdr::DDS_CDR);
scdr.serialize_encapsulation();
if (callbacks_->cdr_serialize(data, scdr))
{
payload->encapsulation = (scdr.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS) ?
CDR_BE : CDR_LE;
payload->length = static_cast<uint32_t>(scdr.get_serialized_data_length());
payload->length = static_cast<uint32_t>(scdr.getSerializedDataLength());
return true;
}
else
@@ -77,7 +77,7 @@ bool ParticipantEntitiesInfoTypeSupport::deserialize(
eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast<char *>(payload->data),
payload->length);
eprosima::fastcdr::Cdr dcdr(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN,
eprosima::fastcdr::DDS_CDR);
eprosima::fastcdr::Cdr::DDS_CDR);
dcdr.read_encapsulation();
return callbacks_->cdr_deserialize(dcdr, data);
@@ -146,14 +146,14 @@ bool MicrorosGraphInfoTypeSupport::serialize(
eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast<char *>(payload->data),
payload->max_size);
eprosima::fastcdr::Cdr scdr(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN,
eprosima::fastcdr::DDS_CDR);
eprosima::fastcdr::Cdr::DDS_CDR);
scdr.serialize_encapsulation();
if (callbacks_->cdr_serialize(data, scdr))
{
payload->encapsulation = (scdr.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS) ?
CDR_BE : CDR_LE;
payload->length = static_cast<uint32_t>(scdr.get_serialized_data_length());
payload->length = static_cast<uint32_t>(scdr.getSerializedDataLength());
return true;
}
else
@@ -169,7 +169,7 @@ bool MicrorosGraphInfoTypeSupport::deserialize(
eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast<char *>(payload->data),
payload->length);
eprosima::fastcdr::Cdr dcdr(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN,
eprosima::fastcdr::DDS_CDR);
eprosima::fastcdr::Cdr::DDS_CDR);
dcdr.read_encapsulation();
return callbacks_->cdr_deserialize(dcdr, data);
+19
View File
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8" ?>
<profiles xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles" >
<transport_descriptors>
<transport_descriptor>
<transport_id>CustomUdpTransport</transport_id>
<type>UDPv4</type>
</transport_descriptor>
</transport_descriptors>
<participant profile_name="participant_profile" is_default_profile="true">
<rtps>
<userTransports>
<transport_id>CustomUdpTransport</transport_id>
</userTransports>
<useBuiltinTransports>false</useBuiltinTransports>
</rtps>
</participant>
</profiles>
+1 -1
View File
@@ -24,4 +24,4 @@ if [ -n "$p2p_port" ]; then
set -- --p2p "$p2p_port" "$@"
fi
exec "$SNAP/lib/micro_ros_agent/micro_ros_agent" "$transport" "$@"
exec "$SNAP/opt/ros/snap/lib/micro_ros_agent/micro_ros_agent" "$transport" "$@"
+35 -35
View File
@@ -71,16 +71,6 @@ description: |
$ snap set micro-ros-agent device="device path"
If connecting the micro-ROS Agent using an IP based connection mode,
that is, `udp4`, `udp6`, `tcp4` or `tcp6`, care must be taken to
connect first the `micro-ros-agent-shm-netplug` plug.
This is due to the fact that ROS 2 Foxy is using Fast-DDS as the
default DDS middleware, and Fast-DDS comes with *shared memory transport*.
Thus, this plugin must be enabled, in order to gain access to the
`/dev/shm` folder from the snap image, prior to running it:
$ sudo snap connect micro-ros-agent:micro-ros-agent-shm-netplug
When using the snap with a serial device, some steps need to be taken
in order to establish a successful connection:
@@ -120,49 +110,59 @@ architectures:
- build-on: armhf
- build-on: ppc64el
package-repositories:
- components: [main]
formats: [deb]
key-id: C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
key-server: keyserver.ubuntu.com
suites: [focal]
type: apt
url: http://repo.ros2.org/ubuntu/main
parts:
ros2-foxy-extension:
build-packages: [ros-foxy-ros-core]
override-build: install -D -m 0755 launch ${SNAPCRAFT_PART_INSTALL}/snap/command-chain/ros2-launch
plugin: nil
source: $SNAPCRAFT_EXTENSIONS_DIR/ros2
uros-agent:
plugin: colcon
source: .
override-build: |
set +u
git clone https://github.com/eProsima/Micro-XRCE-DDS-Agent.git -b $ROS_DISTRO
git clone https://github.com/eProsima/Micro-CDR.git -b $ROS_DISTRO
git clone https://github.com/micro-ROS/micro_ros_msgs.git -b $ROS_DISTRO
git clone https://github.com/micro-ROS/rosidl_typesupport_microxrcedds.git -b $ROS_DISTRO
git clone https://github.com/micro-ROS/rmw-microxrcedds.git -b $ROS_DISTRO
git clone https://github.com/micro-ROS/micro-ROS-Agent.git -b $ROS_DISTRO
. /opt/ros/$ROS_DISTRO/setup.sh
colcon build --merge-install --install-base $SNAPCRAFT_PRIME --cmake-args "-DUAGENT_BUILD_EXECUTABLE=OFF -DUAGENT_USE_SYSTEM_FASTDDS=ON" --packages-up-to micro_ros_agent
set -u
colcon-cmake-args:
- -DMICROROSAGENT_SUPERBUILD=ON
- --cmake-force-configure
override-pull: |
snapcraftctl pull
version="$(git describe --always --tags| sed -e 's/^v//;s/-/+git/;y/-/./')"
[ -n "$(echo $version | grep "+git")" ] && grade=devel || grade=stable
snapcraftctl set-version "$version"
snapcraftctl set-grade "$grade"
build-packages: [make, gcc, g++]
stage-packages: [ros-foxy-ros2launch]
build-environment:
- ROS_VERSION: '2'
- ROS_DISTRO: foxy
runner:
plugin: dump
source: snap/local/
organize:
'*': usr/bin/
plugs:
micro-ros-agent-shm-netplug:
interface: system-files
allow-auto-connection: true
write:
- /dev/shm
'micro-ros-agent-daemon': usr/bin/
'fastdds_no_shared_memory.xml': usr/share/
apps:
micro-ros-agent:
command: lib/micro_ros_agent/micro_ros_agent
command: opt/ros/snap/lib/micro_ros_agent/micro_ros_agent
environment:
LD_LIBRARY_PATH: "$LD_LIBRARY_PATH:$SNAP/lib"
plugs: [network, network-bind, serial-port, micro-ros-agent-shm-netplug]
extensions: [ros2-foxy]
FASTRTPS_DEFAULT_PROFILES_FILE: ${SNAP}/usr/share/fastdds_no_shared_memory.xml
plugs: [network, network-bind, serial-port]
daemon:
command: usr/bin/micro-ros-agent-daemon
environment:
LD_LIBRARY_PATH: "$LD_LIBRARY_PATH:$SNAP/lib"
FASTRTPS_DEFAULT_PROFILES_FILE: ${SNAP}/usr/share/fastdds_no_shared_memory.xml
daemon: simple
plugs: [network, network-bind, serial-port, micro-ros-agent-shm-netplug]
plugs: [network, network-bind, serial-port]