Skip to content

logsoft/Mowgli-open_mower_ros

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MOWGLI Changes compared to OM

  • More debug statements
  • pause() is in reality abort() so it and its related functions have been renamed
  • the new (real) pause() will interrupt an ongoing MBF mow path
  • while in Mowing Behaviour - HOME will abort, then go to the Docking Behaviour, START will continue a manually pause, S1 will pause a mow path

TODO

  • use async functions only for navigation

ROS Workspace

This folder is the ROS workspace, which should be used to build the OpenMower ROS software. This repository contains the ROS package for controlling the OpenMower.

There are references to other repositories (libraries) needed to build the software. This way, we can track the exact version of the packages used in each release to ensure package compatibility. Currently, the following repositories are included:

  • slic3r_coverage_planner: A coverage planner based on the Slic3r software for 3d printers. This is used to plan the mowing path.
  • teb_local_planner: The local planner which allows the robot to avoid obstacles and follow the global path using kinematic constraints.
  • xesc_ros: The ROS interface for the xESC motor controllers.

Getting started

Running on your machine

OpenMower requires ROS Noetic. (installation instruction) There is no distributed release package yet, for development and test purpose it's best to build the workspace on your own.

By default, OpenMower is supposed to run on an ARM-based Raspberry boards: https://x-tech.online/2022/01/installing-ros-noetic-on-a-headless-raspberry-pi-4-with-ubuntu-20-04/

Fetch Dependencies

Before building, you need to fetch this project's dependencies. Some dependencies are distributed as git submodules, others can be installed using rosdep:

First, fetch the Git submodules:

# Fetch Git Submodules
git submodule update --init --recursive

Then, install the remaining dependencies using rosdep:

sudo apt install python3-rosdep
sudo rosdep init

Run in the repository's root:

rosdep update
rosdep install --from-paths src --ignore-src --default-yes

Build workspace

Just build as any other ROS workspace: catkin_make Once it's done, another step is to source workspace env vars:

source devel/setup.bash

Launch OpenMower

OpenMower ROS package is distributed with roslaunch launch files. There are few in: src/open_mower/open_mower/launch, however the open_mower.launch runs everything needed to mow.

roslaunch open_mower open_mower.launch

Before you launch open_mower package, env vars with configuration have to be set.

cp src/open_mower/open_mower/config/mower_config.sh.example mower_config.sh
source mower_config.sh # it's expected to adjust the file

Running in a container

TBD (no automated image build yet)

Contribution

How to Build Using CLion IDE

First, launch CLion in a sourced environment. For this I use the following bash file:

#!/bin/zsh

source <your_absolute_path_to_repository>/devel/setup.zsh

# You can find this path in the Jetbrains Toolbox
nohup <your_absolute_path_to_clion>/clion.sh >/dev/null 2>&1 &

Then, open the src directory. CLion will prompt with the following screen:

CLion CMake Settings

Copy the settings for Build directory and CMake options. Everything else can stay the same. This is all you need!

Notes / ToDos

  • For local navigation, I have tried to use the teb_local_planner. Unfortunately, it seems that (at least for me) the noetic version is VERY broken. Therefore I added the current melodic dev version as git submodule to this repo. It seems to work fine with ROS noetic and this setup here.
  • If the map has no docking point set, planning crashes as soon as we try to approach the docking point. TODO: check, before even starting to mow.

License

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Feel free to use the design in your private/educational projects, but don't try to sell the design or products based on it without getting my consent first. The idea here is to share knowledge, not to enable others to simply sell my work. Thank you for understanding.

About

Mowgli Development of Open Mower ROS

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 72.6%
  • CMake 22.9%
  • Python 1.9%
  • C 1.7%
  • Other 0.9%