Get Effective Robotics Programming With ROS Anil Mahtani PDF Ebook With Full Chapters Now
Get Effective Robotics Programming With ROS Anil Mahtani PDF Ebook With Full Chapters Now
com
https://textbookfull.com/product/effective-
robotics-programming-with-ros-anil-mahtani/
https://textbookfull.com/product/data-structures-with-c-
programming-2nd-edition-anil-kumar-yadav/
textbookfull.com
https://textbookfull.com/product/a-systematic-approach-to-learning-
robot-programming-with-ros-1st-edition-wyatt-newman/
textbookfull.com
https://textbookfull.com/product/measures-integrals-and-martingales-
solution-manual-2nd-edition-rene-l-schilling/
textbookfull.com
The China Study Revised and Expanded Edition The Most
Comprehensive Study of Nutrition T. Colin Campbell
https://textbookfull.com/product/the-china-study-revised-and-expanded-
edition-the-most-comprehensive-study-of-nutrition-t-colin-campbell/
textbookfull.com
Alone of All Her Sex: The Myth and Cult of the Virgin Mary
Marina Warner
https://textbookfull.com/product/alone-of-all-her-sex-the-myth-and-
cult-of-the-virgin-mary-marina-warner/
textbookfull.com
https://textbookfull.com/product/proceedings-of-the-national-
aerospace-propulsion-conference-chetan-s-mistry/
textbookfull.com
https://textbookfull.com/product/surviving-singlehood-1st-edition-
hephzibah-frances/
textbookfull.com
https://textbookfull.com/product/for-the-love-of-humanity-the-world-
tribunal-on-iraq-pennsylvania-studies-in-human-rights-1st-edition-
cubukcu/
textbookfull.com
Performance Generating Systems in Dance: Dramaturgy,
Psychology, and Performativity 1st Edition Hansen
https://textbookfull.com/product/performance-generating-systems-in-
dance-dramaturgy-psychology-and-performativity-1st-edition-hansen/
textbookfull.com
Effective Robotics Programming with ROS
Third Edition
Table of Contents
Effective Robotics Programming with ROS Third Edition
Credits
About the Authors
About the Reviewer
www.PacktPub.com
eBooks, discount offers, and more
Why subscribe?
Customer Feedback
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
1. Getting Started with ROS
PC installation
Installing ROS Kinetic using repositories
Configuring your Ubuntu repositories
Setting up your source.list file
Setting up your keys
Installing ROS
Initializing rosdep
Setting up the environment
Getting rosinstall
How to install VirtualBox and Ubuntu
Downloading VirtualBox
Creating the virtual machine
Using ROS from a Docker image
Installing Docker
Getting and using ROS Docker images and containers
Installing ROS in BeagleBone Black
Prerequisites
Setting up the local machine and source.list file
Setting up your keys
Installing the ROS packages
Initializing rosdep for ROS
Setting up the environment in the BeagleBone Black
Getting rosinstall for BeagleBone Black
Basic ROS example on the BeagleBone Black
Summary
2. ROS Architecture and Concepts
Understanding the ROS Filesystem level
The workspace
Packages
Metapackages
Messages
Services
Understanding the ROS Computation Graph level
Nodes and nodelets
Topics
Services
Messages
Bags
The ROS master
Parameter Server
Understanding the ROS Community level
Tutorials to practise with ROS
Navigating through the ROS filesystem
Creating our own workspace
Creating an ROS package and metapackage
Building an ROS package
Playing with ROS nodes
Learning how to interact with topics
Learning how to use services
Using Parameter Server
Creating nodes
Building the node
Creating msg and srv files
Using the new srv and msg files
The launch file
Dynamic parameters
Summary
3. Visualization and Debugging Tools
Debugging ROS nodes
Using the GDB debugger with ROS nodes
Attaching a node to GDB while launching ROS
Profiling a node with valgrind while launching ROS
Enabling core dumps for ROS nodes
Logging messages
Outputting logging messages
Setting the debug message level
Configuring the debugging level of a particular node
Giving names to messages
Conditional and filtered messages
Showing messages once, throttling, and other combinations
Using rqt_console and rqt_logger_level to modify the logging level on the fly
Inspecting the system
Inspecting the node's graph online with rqt_graph
Setting dynamic parameters
Dealing with the unexpected
Visualizing nodes diagnostics
Plotting scalar data
Creating a time series plot with rqt_plot
Image visualization
Visualizing a single image
3D visualization
Visualizing data in a 3D world using rqt_rviz
The relationship between topics and frames
Visualizing frame transformations
Saving and playing back data
What is a bag file?
Recording data in a bag file with rosbag
Playing back a bag file
Inspecting all the topics and messages in a bag file
Using the rqt_gui and rqt plugins
Summary
4. 3D Modeling and Simulation
A 3D model of our robot in ROS
Creating our first URDF file
Explaining the file format
Watching the 3D model on rviz
Loading meshes to our models
Making our robot model movable
Physical and collision properties
Xacro – a better way to write our robot models
Using constants
Using math
Using macros
Moving the robot with code
3D modeling with SketchUp
Simulation in ROS
Using our URDF 3D model in Gazebo
Adding sensors to Gazebo
Loading and using a map in Gazebo
Moving the robot in Gazebo
Summary
5. The Navigation Stack – Robot Setups
The navigation stack in ROS
Creating transforms
Creating a broadcaster
Creating a listener
Watching the transformation tree
Publishing sensor information
Creating the laser node
Publishing odometry information
How Gazebo creates the odometry
Using Gazebo to create the odometry
Creating our own odometry
Creating a base controller
Creating our base controller
Creating a map with ROS
Saving the map using map_server
Loading the map using map_server
Summary
6. The Navigation Stack – Beyond Setups
Creating a package
Creating a robot configuration
Configuring the costmaps – global_costmap and local_costmap
Configuring the common parameters
Configuring the global costmap
Configuring the local costmap
Base local planner configuration
Creating a launch file for the navigation stack
Setting up rviz for the navigation stack
The 2D pose estimate
The 2D nav goal
The static map
The particle cloud
The robot's footprint
The local costmap
The global costmap
The global plan
The local plan
The planner plan
The current goal
Adaptive Monte Carlo Localization
Modifying parameters with rqt_reconfigure
Avoiding obstacles
Sending goals
Summary
7. Manipulation with MoveIt!
The MoveIt! architecture
Motion planning
The planning scene
World geometry monitor
Kinematics
Collision checking
Integrating an arm in MoveIt!
What's in the box?
Generating a MoveIt! package with the Setup Assistant
Integration into RViz
Integration into Gazebo or a real robotic arm
Simple motion planning
Planning a single goal
Planning a random target
Planning a predefined group state
Displaying the target motion
Motion planning with collisions
Adding objects to the planning scene
Removing objects from the planning scene
Motion planning with point clouds
The pick and place task
The planning scene
The target object to grasp
The support surface
Perception
Grasping
The pickup action
The place action
The demo mode
Simulation in Gazebo
Summary
8. Using Sensors and Actuators with ROS
Using a joystick or a gamepad
How does joy_node send joystick movements?
Using joystick data to move our robot model
Using Arduino to add sensors and actuators
Creating an example program to use Arduino
Robot platform controlled by ROS and Arduino
Connecting your robot motors to ROS using Arduino
Connecting encoders to your robot
Controlling the wheel velocity
Using a low-cost IMU – 9 degrees of freedom
Installing Razor IMU ROS library
How does Razor send data in ROS?
Creating an ROS node to use data from the 9DoF sensor in our robot
Using robot localization to fuse sensor data in your robot
Using the IMU – Xsens MTi
How does Xsens send data in ROS?
Using a GPS system
How GPS sends messages
Creating an example project to use GPS
Using a laser rangefinder – Hokuyo URG-04lx
Understanding how the laser sends data in ROS
Accessing the laser data and modifying it
Creating a launch file
Using the Kinect sensor to view objects in 3D
How does Kinect send data from the sensors, and how do we see it?
Creating an example to use Kinect
Using servomotors – Dynamixel
How does Dynamixel send and receive commands for the movements?
Creating an example to use the servomotor
Summary
9. Computer Vision
ROS camera drivers support
FireWire IEEE1394 cameras
USB cameras
Making your own USB camera driver with OpenCV
ROS images
Publishing images with ImageTransport
OpenCV in ROS
Installing OpenCV 3.0
Using OpenCV in ROS
Visualizing the camera input images with rqt_image_view
Camera calibration
How to calibrate a camera
Stereo calibration
The ROS image pipeline
Image pipeline for stereo cameras
ROS packages useful for Computer Vision tasks
Visual odometry
Using visual odometry with viso2
Camera pose calibration
Running the viso2 online demo
Performing visual odometry with viso2 with a stereo camera
Performing visual odometry with an RGBD camera
Installing fovis
Using fovis with the Kinect RGBD camera
Computing the homography of two images
Summary
10. Point Clouds
Understanding the Point Cloud Library
Different point cloud types
Algorithms in PCL
The PCL interface for ROS
My first PCL program
Creating point clouds
Loading and saving point clouds to the disk
Visualizing point clouds
Filtering and downsampling
Registration and matching
Partitioning point clouds
Segmentation
Summary
Index
Effective Robotics Programming with ROS
Third Edition
Visit https://textbookfull.com
now to explore a rich
collection of eBooks, textbook
and enjoy exciting offers!
Effective Robotics Programming with ROS
Third Edition
Copyright © 2016 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or
transmitted in any form or by any means, without the prior written permission of the
publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the
information presented. However, the information contained in this book is sold without
warranty, either express or implied. Neither the authors, nor Packt Publishing, and its dealers
and distributors will be held liable for any damages caused or alleged to be caused directly or
indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the
companies and products mentioned in this book by the appropriate use of capitals. However,
Packt Publishing cannot guarantee the accuracy of this information.
Livery Place
35 Livery Street
ISBN 978-1-78646-365-4
www.packtpub.com
Credits
Authors
Anil Mahtani
Luis Sánchez
Enrique Fernández
Aaron Martinez
Reviewer
Lentin Joseph
Commissioning Editor
Kartikey Pandey
Acquisition Editor
Narsimha Pai
Abhishek Jadhav
Technical Editor
Gaurav Suri
Copy Editors
Safis Editing
Dipti Mankame
Project Coordinator
Judie Jose
Proofreader
Safis Editing
Indexer
Pratik Shirodkar
Graphics
Kirk D'Penha
Production Coordinator
Shantanu N. Zagade
Cover Work
Shantanu N. Zagade
About the Authors
Anil Mahtani is a computer scientist who has dedicated an important part of his career to
underwater robotics. He first started working in the field with his master thesis, where he
developed a software architecture for a low-cost ROV. During the development of his thesis,
he also became the team leader and lead developer of AVORA, a team of university students
that designed and developed an autonomous underwater vehicle for the Students Autonomous
Underwater Challenge – Europe (SAUC-E) in 2012. That same year, Anil Mahtani completed
his thesis and his MSc in Computer Science at the University of Las Palmas de Gran Canaria
and then became a Software Engineer at SeeByte Ltd, a world leader in smart software
solutions for underwater systems. In 2015, he joined Dell Secureworks as a Software
Engineer, where he applies his knowledge and skills toward developing intrusion detection
and prevention systems.
During his time at SeeByte Ltd, Anil Mahtani played a key role in the development of several
semi-autonomous and autonomous underwater systems for the military and oil and gas
industries. In those projects, he was heavily involved in the development of autonomy
systems, the design of distributed software architectures, and low-level software development
and also contributed in providing Computer Vision solutions for front-looking sonar
imagery. At SeeByte Ltd, he also achieved the position of project manager, managing a team
of engineers developing and maintaining the internal core C++ libraries.
His professional interests lie mainly in software engineering, algorithms, data structures,
distributed systems, networks, and operating systems. Anil's main role in robotics is to
provide efficient and robust software solutions, addressing not only the current problems at
hand but also foreseeing future problems or possible enhancements. Given his experience, he
is also an asset when dealing with Computer Vision, machine learning, or control problems.
Anil has also interests in DIY and electronics, and he has developed several Arduino libraries,
which he has contributed back to the community.
First of all, I would like to thank my family and friends for their support and for always being
there when I needed them. I would also like to thank my girlfriend Alex for her support and
patience, and for being a constant source of inspiration. Finally, I would like to thank my
colleagues Ihor Bilyy and Dan Good, who have taught me a lot, both personally and
professionally, during these new steps in my career as a software engineer.
Luis Sánchez has completed his dual master's degree in electronics and telecommunication
engineering at the University of Las Palmas de Gran Canaria.
He has collaborated with different research groups as the Institute for Technological
Development and Innovation (IDETIC), the Oceanic Platform of Canary Islands (PLOCAN),
and the Institute of Applied Microelectronics (IUMA) where he actually researches on
imaging super-resolution algorithms.
His professional interests lie in Computer Vision, signal processing, and electronic design
applied on robotics systems. For this reason, he joined the AVORA team, a group of young
engineers and students working on the development of Underwater Autonomous Vehicles
(AUV) from scratch. Inside this project, Luis has started developing acoustic and Computer
Vision systems, extracting information from different sensors such as hydrophones, sonar, or
camera.
Here's what Dario Sosa Cabrera, a marine technologies engineer and entrepreneur (and the
cofounder and maker of LPA Fabrika: Gran Canaria Maker Space) has to say about Luis:
"He is very enthusiastic and an engineer in multiple disciplines. He is responsible for his
work. He can manage himself and can take up responsibilities as a team leader, as
demonstrated at the euRathlon competition. His background in electronics and
telecommunications allows him to cover a wide range of expertise from signal processing
and software, to electronic design and fabrication."
Luis has participated as a technical reviewer of the previous version of Learning ROS for
Robotics Programming and as a cowriter of the second edition.
First, I have to acknowledge Aaron, Anil, and Enrique for inviting me to participate in this
book. It has been a pleasure to return to work with them. Also, I want to thank the Subsea
Mechatronics team for the great experience working with heavy underwater robots, we grew
together during these years. I have to mention LPA Fabrika – Gran Canaria Maker Space for
the enthusiasm preparing and teaching educational robotics and technological projects;
sharing a workspace with kids can be really motivating.
Finally, I will have to thank my family and my girlfriend for the big support and
encouragement in every project where I'm involved. I want to dedicate my contribution in this
book to them.
During his PhD, Enrique published several conference papers and publications to top robotics
conferences, such as the International Conference of Robotics and Automation (ICRA). He has
also authored some book chapters and ROS books.
Later, Enrique joined PAL Robotics as a SLAM engineer in June 2013. There he worked with
the REEM and REEM-C humanoid robots using ROS software and also contributed to the
open source community, mainly to ROS Control repository, being one of the maintainers
nowadays. In 2015, he joined Clearpath Robotics to work on the Autonomy team, developing
perception algorithms. He has worked on the software that runs on the industrial mobile
robots OTTO 1500 and OTTO 100, which has been deployed into the facilities of multiple
large industry companies, such as General Electric and John Deere.
I would like to thank the coauthors of the book for their dedication. I also want to say thanks
to the members of my research group in Las Palmas de Gran Canaria and the Center of
Underwater Robotics Research in Girona. I learned a lot about robotics then, and I started to
work with ROS. Thanks also to the ex-colleagues from PAL Robotics, who received me with
open hands, and have given me the opportunity to learn even more from ROS and (humanoid)
robots. Last by not least, to my current colleagues at Clearpath Robotics, where I have
mastered ROS and contributed to the software that runs 24/7 in the self-driving robots we
have sold for the Industry 4.0. Finally, thanks to my family and friends for their help and
support, especially Eva.
Recently, Aaron created his own company named SubSeaMechatronics, SL. This company
works with projects related with underwater robotics and telecontrol systems. They are also
designing and manufacturing subsea sensors. The company manufactures devices for other
companies and research and development institutes.
Aaron has experience in many fields, such as programming, robotics, mechatronics, and
digital fabrication as well as many devices, such as Arduino, BeagleBone, Servers, and
LIDAR, and nowadays he is designing in SubSeaMechatronics SL some robotics platforms
for underwater and aerial environments.
I would like to thank my girlfriend who has supported me while writing this book and gave
me motivation to continue growing professionally. I also want to thank Donato Monopoli,
Head of Biomedical Engineering Department at ITC (Canary-Islands Institute of Technology),
and all the staff there. Thanks for teaching me all I know about digital fabrication, machinery,
and engineering tissue. I spent the best years of my life in your workshop.
Thanks to my colleagues in the university, especially Alexis Quesada, who gave me the
opportunity to create my first robot in my master's thesis. I have learned a lot about robotics
working with them.
Finally, thanks to my family and friends for their help and support.
About the Reviewer
Lentin Joseph is an author, entrepreneur, electronics engineer, robotics enthusiast, machine
vision expert, embedded programmer, and the founder and CEO of Qbotics Labs
(http://www.qboticslabs.com) in India.
After his graduation, for 3 years he worked at a start-up company focusing on robotics and
image processing. In the meantime, he learned famous robotic software platforms, such as
Robot Operating System (ROS), V-REP, Actin (a robotic simulation tool), and image
processing libraries, such as OpenCV, OpenNI, and PCL. He also knows about robot 3D
designing and embedded programming on Arduino and Tiva Launchpad.
After 3 years of work experience, he started a new company named Qbotics Labs, which
mainly focuses on research to build up some great products in domains, such as robotics and
machine vision. He maintains a personal website (http://www.lentinjoseph.com) and a
technology blog named technolabsz (http://www.technolabsz.com). He publishes his works on
his tech blog. He was also a speaker at PyCon2013, India, on the topic Learning Robotics
using Python.
Lentin is the author of the books Learning Robotics using Python (refer to http://learn-
robotics.com to find out more) and Mastering ROS for Robotics Programming (refer to
http://mastering-ros.com to find out more) by Packt Publishing. The first book was about
building an autonomous mobile robot using ROS and OpenCV. This book was launched in
ICRA 2015 and was featured in the ROS blog, Robohub, OpenCV, the Python website, and
various other such forums. The second book is for mastering robot operating system; this
was also launched ICRA 2016, and it is one of the best seller book in ROS.
Lentin and his team was a winner of HRATC 2016 challenge conducted as a part of ICRA
2016, and he was Also a finalist in the ICRA 2015 challenge, HRATC
(http://www.icra2016.org/conference/challenges/).
www.PacktPub.com
eBooks, discount offers, and more
Did you know that Packt offers eBook versions of every book published, with PDF and ePub
files available? You can upgrade to the eBook version at www.PacktPub.com and as a print
book customer, you are entitled to a discount on the eBook copy. Get in touch with us at
<[email protected]> for more details.
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a
range of free newsletters and receive exclusive discounts and offers on Packt books and
eBooks.
https://www.packtpub.com/mapt
Get the most in-demand software skills with Mapt. Mapt gives you full access to all Packt
books and video courses, as well as industry-leading tools to help you plan your personal
development and advance your career.
Visit https://textbookfull.com
now to explore a rich
collection of eBooks, textbook
and enjoy exciting offers!
Why subscribe?
Fully searchable across every book published by Packt
Copy and paste, print, and bookmark content
On demand and accessible via a web browser
Customer Feedback
Thank you for purchasing this Packt book. We take our commitment to improving our content
and products to meet your needs seriously—that's why your feedback is so valuable.
Whatever your feelings about your purchase, please consider leaving a review on this book's
Amazon page. Not only will this help us, more importantly it will also help others in the
community to make an informed decision about the resources that they invest in to learn.
You can also review for us on a regular basis by joining our reviewers' club. If you're
interested in joining, or would like to learn more about the benefits we offer, please
contact us: <[email protected]>.
Preface
Effective Robotics Programming with ROS, Third Edition gives you a comprehensive review
of ROS, the Robot Operating System framework, which is used nowadays by hundreds of
research groups and companies in the robotics industry. More importantly, ROS is also the
painless entry point to robotics for nonprofessionals and students. This book will guide you
through the installation process of ROS, and soon enough, you will be playing with the basic
tools and understanding the different elements of the framework.
The content of the book can be followed without any special devices, and each chapter comes
with a series of source code examples and tutorials that you can run on your own computer.
This is the only thing you need to follow the book.
However, we also show you how to work with hardware so that you can connect your
algorithms with the real world. Special care has been taken in choosing devices that are
affordable for amateur users, but at the same time, the most typical sensors or actuators in
robotics research are covered.
Finally, the potential of ROS is illustrated with the ability to work with whole robots in a real
or simulated environment. You will learn how to create your own robot and integrate it with a
simulation by using the Gazebo simulator. From here, you will have the chance to explore the
different aspects of creating a robot, such as perceiving the world using computer vision or
point cloud analysis, navigating through the environment using the powerful navigation stack,
and even being able to control robotic arms to interact with your surroundings using the
MoveIt! package. By the end of the book, it is our hope that you will have a thorough
understanding of the endless possibilities that ROS gives you when developing robotic
systems.
What this book covers
Chapter 1, Getting Started with ROS, shows the easiest way you must follow in order to have a
working installation of ROS. You will see how to install ROS on different platforms, and you
will use ROS Kinetic throughout the rest of the book. This chapter describes how to make an
installation from Debian packages, compile the sources, and make installations in virtual
machines, Docker, and ARM CPU.
Chapter 2, ROS Architecture and Concepts, is concerned with the concepts and tools provided
by the ROS framework. We will introduce you to nodes, topics, and services, and you will
also learn how to use them. Through a series of examples, we will illustrate how to debug a
node and visualize the messages published through a topic.
Chapter 3, Visualization and Debugging Tools, goes a step further in order to show you
powerful tools to debug your nodes and visualize the information that goes through the
node's graph along with the topics. ROS provides a logging API that allows you to diagnose
node problems easily. In fact, we will see some powerful graphical tools, such as rqt_console
and rqt_graph, as well as visualization interfaces, such as rqt_plot and rviz. Finally, this
chapter explains how to record and play back messages using rosbag and rqt_bag.
Chapter 4, 3D Modeling and Simulation, constitutes one of the first steps in order to
implement your own robot in ROS. It shows you how to model a robot from scratch and run
it in simulation using the Gazebo simulator. You will simulate sensors, such as cameras and
laser range sensors. This will later allow you to use the whole navigation stack provided by
ROS and other tools.
Chapter 5, The Navigation Stack – Robot Setups, is the first of two chapters concerned with the
ROS navigation stack. This chapter describes how to configure your robot so that it can be
used with the navigation stack. In the same way, the stack is explained, along with several
examples.
Chapter 6, The Navigation Stack – Beyond Setups, continues the discussion of the previous
chapter by showing how we can effectively make our robot navigate autonomously. It will use
the navigation stack intensively for that. This chapter shows the great potential of ROS using
the Gazebo simulator and RViz to create a virtual environment in which we can build a map,
localize our robot, and do path planning with obstacle avoidance.
Chapter 7, Manipulation with MoveIt!, is a set of tools for mobile manipulation in ROS. This
chapter contains the documentation that you need to install this package. The chapter also
contains example demonstrations with robotic arms that use MoveIt! for manipulation tasks,
such as grasping, picking and placing, or simple motion planning with inverse kinematics.
Chapter 8, Using Sensors and Actuators with ROS, literally connects ROS with the real world.
This chapter goes through a number of common sensors and actuators that are supported in
ROS, such as range lasers, servo motors, cameras, RGB-D sensors, and GPS. Moreover, we
explain how to use embedded systems with microcontrollers, similar to the widely known
Arduino boards.
Chapter 9, Computer Vision, shows the support for cameras and computer vision tasks in
ROS. This chapter starts with drivers available for FireWire and USB cameras so that you can
connect them to your computer and capture images. You will then be able to calibrate your
camera using the ROS calibration tools. Later, you will be able to use the image pipeline,
which is explained in detail. Then, you will see how to use several APIs for vision and
integrate OpenCV. Finally, the installation and usage of a visual odometry software is
described.
Chapter 10, Point Clouds, shows how to use Point Cloud Library in your ROS nodes. This
chapter starts with the basics utilities, such as read or write a PCL snippet and the conversions
needed to publish or subscribe to these messages. Then, you will create a pipeline with
different nodes to process 3D data, and you will downsample, filter, and search for features
using PCL.
Random documents with unrelated
content Scribd suggests to you:
“I can give you the names of several other influential men who know
me. The Marquis de Pinsara, Visconte de Linto,” and I rattled off a
number of the men to whom I had been introduced on the night of
the reception.
“You can communicate with them in the morning and call them as
witnesses,” he sneered. He had the sardonic habit strongly
developed. “But I haven’t done questioning you yet.”
“I shall not answer any more questions. You don’t believe what I tell
you. My object was to avoid the unpleasantness of being thrust into
one of your filthy gaols; and that has evidently failed.”
“You will tell me where the men are hidden who were here with
you,” he said very threateningly.
“I repeat, I know no more than you do. You were already in the
house when they left this room.”
“That won’t do for me,” he answered bluntly. He motioned to the
two men who pulled my hands behind my back and slipped a pair of
handcuffs on my wrists, while he himself sat down at the desk and
made a list of the things the men had taken from me. “Is this all?”
he asked the fellow who had searched me.
“All but a cigarette case.”
“Anything in it?”
“Nothing but cigarettes. I made sure of that.”
“All right.” I breathed more freely.
“Now, prisoner, show me the secret hiding-place in this room.”
“There is none. The men left the room.”
He came close up and glared so fiercely into my face that I thought
he was going to strike me. He was the sort of brute to enjoy hitting
a defenceless man. “If you lie to me, I’ll——” he ground his teeth
and left me to finish the sentence out of my own fears.
“I do not lie,” I said meeting his look steadily. “And you will do well
to bear in mind in all you do now that in the morning you will find
every word I have said as to my friendship with M. Volheno is true.”
I spoke very calmly thinking it would have the better effect. But it
appeared to enrage him and this time he actually raised his hand for
a blow. It was therefore clearly time to try a change of manner.
So I shoved my head forward until our noses were nearly touching
and with a fierce oath, I cried: “You dare to lay a hand on me, you
infernal bully, and it shall cost you dear. M. Volheno shall know of
this. Do your duty whatever that may be, but not one jot more, or
——” and I adopted his tactic of an unfinished sentence.
The result was a surprising success. His hand fell to his side, his
eyes wavered, and his threatening truculence of manner dropped
from him like a cloak. The reason was, of course, that he was a
miserable coward and had mistaken my coolness for fear.
“I am only doing my duty,” he muttered.
“You lie,” I thundered back, quick to take advantage of his mood.
“You dare to handcuff me like a felon, when I tell you I am a British
subject and give you ample means of testing what I say. You’ll have
to reckon with the British Legation for this. Do what you will, while
you have me in your power; but don’t think for an instant you won’t
have to pay for your bullying in the morning.”
“I have——”
“Don’t try to excuse yourself. If you want to bully any one, do it with
the unfortunate devils under your orders. As for me, do what you
dare—but remember, it will be my turn to-morrow.”
“If you’ll give your word not to offer resistance, you shall be freed.”
“You didn’t ask that before you handcuffed me. I call these men to
witness that. Take me in them to M. Volheno—if you dare. Or haul
me off to gaol in them. It’s all one to me—until to-morrow.”
He paused and then signed to the men who freed me, and he left
the room. I sat down and the men stood near the door whispering
and sniggering together. They appeared to be rather pleased at their
chief’s discomfiture.
He was away so long that I fell asleep and was in the middle of a
realistic dream that I was in prison among the scum of the city when
I was roused by some one thundering my name in my ear.
I started up and found the official had returned with a companion
who was shaking me and calling me by name.
“Mr. Donnington! Mr. Donnington!”
“Well, what is it?” I grumbled, blinking at him like an owl until I
recognized him as a man I had seen at Volheno’s bureau.
“M. Volheno desired me to come to you, sir.”
“Oh, ho,” I chuckled, turning to the official, “so you thought
discretion was the better part of bullying, eh?”
“My name is Dagara, Mr. Donnington. I am M. Volheno’s private
secretary. He instructed me to say that he desires to see you as soon
as you can call on him.”
“I have to go to gaol first,” I said with a snarl for my old enemy. “I
was already there in my dreams when you roused me. But if I am to
be shot or hanged or beheaded as this man decides, I’ll leave
directions for my corpse to be packed up neatly and sent to M.
Volheno.” I was winning so I could afford a small jibe.
“You are of course at liberty to go where you will,” said Dagara.
“Then I’ll go back to bed,” I declared as I rose, “and will see M.
Volheno in the morning. I have to tell him how this brute has treated
me.”
The official had wilted like an unwatered flower in the noon sunlight.
He returned me my belongings and began to mumble an apology. “I
much regret——”
“I’ve no doubt of it. I know your kind,” I cut in drily, and then left the
house with Dagara, feeling that I was well out of an ugly business.
I had come off with all the honours of war, too, for my letters had
not been read and the two little secret papers were safely stowed
away in my cigarette case.
The secretary walked with me to my rooms and I found him an
exceedingly close-lipped individual. The house where the drastic test
of my good faith had been applied was in the Rua Formosa, about
half a mile from the Rua de Palma; and during the walk I could get
little else than monosyllables from my companion. He did go so far
as to tell me that he had been at work all night with Volheno and
that that was the reason he had not gone home and had been able
to come so promptly to identify me.
But when I asked him about the police official he replied that he
knew nothing.
I soon ceased to question him, and as we reached my rooms, he
said suddenly: “You will understand of course that M. Volheno never
allows me to speak of any of his affairs. I will give him your
message, and wish you good-morning, Mr. Donnington;” and with
this abrupt apology in explanation of his silence, he raised his hat
and went off.
A useful and silently working wheel, no doubt, in the complicated
machinery of the Dictator’s system of government, was my mental
verdict as I entered my rooms, eager to examine my prizes at
leisure.
I put back some of the things Barosa’s men had left littered about,
brewed myself some strong coffee, and set to work.
I first read through again very carefully the forged letter which had
been sent to Volheno. That it was the work of an enemy who was
well versed in my movements was of course on the surface. My
friendship with the man to whom it was addressed, my secret
knowledge of the house in the Rua Catania, my business in regard to
these Beira concessions, these three points told their story as plainly
as the attempt proved the ingenious malignity of the writer, and his
intention to cause Barosa and his friends to suspect me of treachery.
The blow was aimed at my life.
There was only one man in all Lisbon who could have the needed
information and would have the motive.
Sampayo.
Jealousy was one motive, and fear of what I knew about him
another. And he was just the sort of cunning beast to go to work in
this mole-like way. He had reckoned that Barosa’s people would
accept without question such a proof of my treachery and act upon
it. And in all probability they would have done so, but for my
conversation with Barosa on the night of the reception and his
conviction of my good faith.
But there was another point. He must have known that the contents
of the letter would be at once passed on to Barosa. There was
therefore some one about Volheno in league with the revolutionary
party, and that some one must be sufficiently high in his confidence
to be able to get the letter and send it to his friends.
I must find that man out; and then I studied the little slip of paper
which Maral had inadvertently given me with the letter.
The line of nonsense ran as follows.
“Real effects to you truly. You know what this only can
mean. 134”
Absolute gibberish of course. But I had the key.
I noticed that the sentence exactly fitted a line of the same length as
the strip of paper with the holes in it; and when I laid the first line of
holes on the top of the words the meaning was clear.
All the letters were covered by it except the following:
RETURN AT ONCE
“Return at once.”
A simple direction to send the letter back; and 134 was probably the
number by which the man was known to his companions. I had had
my trouble for nothing—or next to nothing; for the cipher key did
not cover the figures at the end of the message.
Then a thought struck me. The numerals might stand for letters: 134
would be “A. C. D.;” or 13 and 4, “M.D.”
“M.D.!” I uttered the letters aloud in my surprise. They were
Miralda’s initials. “Miralda Dominguez.”
The coincidence mazed me; but a moment’s reflection made the
inference appear grotesque, preposterous, idiotic; and I laughed at
it.
But my nerves were out of balance. The ordeal of the last few hours,
following so close upon the tense interview with Miralda on the
Stella, had tried me severely. Everybody appeared to be playing at
make-believe to cause me to misread everything I saw and heard.
Even as I laughed at the thought that Miralda could have had even
the remotest connexion with the cipher message, the disconcerting
possibility suggested by the coincidence would not be shaken off.
Furious with myself, for the subconscious distrust of her which this
depression of spirits implied, I huddled the papers together and
went off to bed.
CHAPTER XII
THE REAL “M. D.”