Code responsible for arduino based plc control of end effector
The arduino_control
directory is a Arduino Sketchbook.
Arduino Sketch | Description |
---|---|
P1AM_network_test | Sample demonstration and basic connection test for establishing an TCP/IP connection to the network and connecting to a ROS master running at a defined endpoint IP address. |
To reprogram the P1AM-100 you must perform the below setup steps..
- Setup the Arduino Sketchbook (following section)
- Install programming support for the P1AM-100 platform
- Start the Arduino IDE and select File > Preferences
- Enter
https://raw.githubusercontent.com/facts-engineering/facts-engineering.github.io/master/package_productivity-P1AM-boardmanagermodule_index.json
into the Additional Board Manager URLs field. You can add multiple URLs, separating them with commas. - Open the Boards Manager from Tools > Board > Boards Manager
- Type
P1AM
into the search box and install the P1AM-100 platform - Select Tools > Board > P1AM-100
- Go to Tools > Port and select the COM Port for your P1AM-100
- Compile
- Compile via Arduino IDE (suggested)
- Compile via
catkin_tools
- Upload
- via Arduino IDE (suggested)
- via Arduino IDE CLI
The arduino control code relies upon two libraries.
ros_lib
provides support for the ROS interface.
P1AM
provides hardware interface support.
Build the ros libraries needed by the Arduino controller into this sketchbook. You must build these from your local environment due to ROS verion requirements.
Must have already installed the ros-<distro>-rosserial
and ros-<distro>-rosserial-arduino
packages prior to this step.
cd <package_path>/arduino_control/libraries
rm -rf ros_lib
rosrun rosserial_arduino make_libraries.py .
This package was designed to use AutomationDirect's Productivity Open automation platform, P1AM-100
. Learn more at the P1AM website.
The P1AM libary is included as a submodule in this Sketchbook. Some git-clients will automatically load submodules, but you may need to perform this manually as shown below.
git submodule init
git submodule update
Hardware specific to this system is included below with links to the vendors documentation.
| P1AM-100 | P1AM-ETH | Linear Encoder
WPP-A-H-0400-E
| -------- | -------- |
| | | <img src="https://cdn.automationdirect.com/images/products/views/pv_wppah0400e_01.jpg" width="300" |