Read State¶
from jacobi import Planner
from jacobi.robots import ABBIRB1200590
from jacobi.drivers import ABBDriver
if __name__ == '__main__':
robot = ABBIRB1200590()
planner = Planner(robot)
driver = ABBDriver(planner, host='192.168.125.1', port=6511)
print('Joint position:', driver.current_state.position)
#include <iostream>
#include <jacobi/planner.hpp>
#include <jacobi/robots/abb_irb1200_5_90.hpp>
#include <jacobi/drivers/abb.hpp>
#include <jacobi/utils/vector.hpp> // E.g. for join method to print vectors easily
using namespace jacobi;
using namespace jacobi::drivers;
using namespace jacobi::robots;
int main() {
auto robot = std::make_shared<ABBIRB1200590>();
auto planner = std::make_shared<Planner>(robot);
auto driver = std::make_shared<ABBDriver>(planner, "192.168.125.1", 6511);
const auto joint_state = driver->get_current_state();
std::cout << "Joint position: " << join(joint_state.position) << std::endl;
}