-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #110 from neufieldrobotics/dev
This merge from dev to master add the following major changes: Add external triggering ROI settings for images Bring Travis CI to master Adding gain settings to code Bump up version to 1.1.0 Number of little improvements and bug fixes.
- Loading branch information
Showing
33 changed files
with
928 additions
and
916 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
language: minimal | ||
|
||
services: | ||
- docker | ||
|
||
matrix: | ||
include: | ||
- arch: amd64 | ||
env : DOCKER_IMAGE=ros:melodic-perception-bionic SPINNAKER_VERSION=2.0.0.147 | ||
- arch: amd64 | ||
env : DOCKER_IMAGE=ros:kinetic-perception-xenial SPINNAKER_VERSION=2.0.0.147 | ||
- arch: amd64 | ||
env : DOCKER_IMAGE=ros:melodic-perception-bionic SPINNAKER_VERSION=2.2.0.48 | ||
- arch: amd64 | ||
env : DOCKER_IMAGE=ros:kinetic-perception-xenial SPINNAKER_VERSION=1.24.0.60 | ||
- arch: amd64 | ||
env : DOCKER_IMAGE=ros:melodic-perception-bionic SPINNAKER_VERSION=1.24.0.60 | ||
- arch: arm64 | ||
env : DOCKER_IMAGE=arm64v8/ros:kinetic-perception-xenial SPINNAKER_VERSION=2.0.0.147 | ||
- arch: arm64 | ||
env : DOCKER_IMAGE=arm64v8/ros:melodic-perception-bionic SPINNAKER_VERSION=2.0.0.147 | ||
|
||
before_install: | ||
- docker pull $DOCKER_IMAGE | ||
|
||
script: | ||
- echo TRAVIS_BUILD_DIR is $TRAVIS_BUILD_DIR | ||
- > | ||
docker run | ||
-v $TRAVIS_BUILD_DIR:/ros_ws/src/spinnaker_sdk_camera_driver/ | ||
--env SPINNAKER_VERSION=$SPINNAKER_VERSION | ||
--env SPINNAKER_LINUX_ARCH=$TRAVIS_CPU_ARCH | ||
$DOCKER_IMAGE | ||
/bin/bash -c | ||
" | ||
/ros_ws/src/spinnaker_sdk_camera_driver/download_and_install_spinnaker.sh; | ||
cd /ros_ws; | ||
catkin_make | ||
" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# Set the default ros output to warning and higher | ||
log4j.logger.ros=INFO | ||
log4j.logger.ros.datacollection_neu=DEBUG | ||
log4j.logger.ros.spinnaker_sdk_camera_driver=DEBUG | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/usr/bin/env bash | ||
set -x | ||
|
||
CWD=`pwd` | ||
|
||
export DEBIAN_FRONTEND=noninteractive | ||
|
||
# install basic packages | ||
apt-get update | ||
apt-get install -q -y --no-install-recommends \ | ||
build-essential tree wget dirmngr gnupg2 vim nano git debconf-utils libunwind-dev iputils-ping dialog apt-utils | ||
|
||
wget https://coe.northeastern.edu/fieldrobotics/spinnaker_sdk_archive/spinnaker-$SPINNAKER_VERSION-$SPINNAKER_LINUX_ARCH-pkg.tar.gz -nv | ||
|
||
tar -zxvf spinnaker-$SPINNAKER_VERSION-$SPINNAKER_LINUX_ARCH-pkg.tar.gz | ||
cd spinnaker-$SPINNAKER_VERSION-$SPINNAKER_LINUX_ARCH | ||
|
||
# fix issue with 'logname' command on docker, required by spinnaker 2.2.0.48 | ||
mv /usr/bin/logname /usr/bin/logname_old | ||
echo "echo root" > /usr/bin/logname | ||
chmod +x /usr/bin/logname | ||
|
||
# auto accept spinnaker license agreements | ||
echo libspinnaker libspinnaker/present-flir-eula note '' | debconf-set-selections | ||
echo libspinnaker libspinnaker/accepted-flir-eula boolean true | debconf-set-selections | ||
|
||
dpkg -i *.deb | ||
|
||
cd .. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
// | ||
// Created by pushyami on 1/15/19. | ||
// | ||
//cpp | ||
#include <iostream> | ||
// ROS | ||
#include <ros/ros.h> | ||
#include <image_transport/image_transport.h> | ||
//#include <cv_bridge/cv_bridge.h> | ||
// msgs | ||
#include "sensor_msgs/Image.h" | ||
//#include "sensor_msgs/CameraInfo.h" | ||
|
||
// nodelets | ||
#include <nodelet/nodelet.h> | ||
#include <pluginlib/class_list_macros.h> | ||
|
||
|
||
|
||
namespace subscriber_nodelet_ns | ||
{ | ||
class subscriber_nodelet: public nodelet::Nodelet | ||
{ | ||
//This is a test nodelet for measuring nodelet performance | ||
public: | ||
subscriber_nodelet(){} | ||
~subscriber_nodelet() | ||
{ | ||
it_.reset(); | ||
} | ||
|
||
std::shared_ptr<image_transport::ImageTransport> it_; | ||
image_transport::Subscriber image_sub_; | ||
|
||
virtual void onInit() | ||
{ | ||
NODELET_INFO("Initializing Subscriber nodelet"); | ||
ros::NodeHandle& node = getNodeHandle(); | ||
ros::NodeHandle& private_nh = getPrivateNodeHandle(); | ||
|
||
it_.reset(new image_transport::ImageTransport(node)); | ||
image_sub_ = it_->subscribe("/camera_array/cam0/image_raw",1, &subscriber_nodelet::imgCallback, this); | ||
NODELET_INFO("onInit for Subscriber nodelet Initialized"); | ||
} | ||
|
||
void imgCallback(const sensor_msgs::Image::ConstPtr& msg) | ||
{ | ||
// dont modify the input msg in any way | ||
sensor_msgs::Image tmp_img = *msg; | ||
NODELET_INFO_STREAM("diff time is "<< ros::Time::now().toSec() - tmp_img.header.stamp.toSec()); | ||
// copy input img to cv::mat and do any cv stuff | ||
// dont do time intense stuff in callbacks | ||
} | ||
}; | ||
} | ||
|
||
PLUGINLIB_EXPORT_CLASS(subscriber_nodelet_ns::subscriber_nodelet, nodelet::Nodelet) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.