There’s a class called Coordinates in this script that uses the get_logger() method. Since Coordinates doesn’t inherit from Node, it has no access to this method.
class Coordinates:
def __init__(self, x, y, z, roll, pitch, yaw):
self.x = x
self.y = y
self.z = z
self.roll = roll
self.pitch = pitch
self.yaw = yaw
def print_coordinates(self):
self.get_logger().info("[ x, y, z] = [" + str(self.x) + ", " +
str(self.y) + ", " + str(self.z) + "]")
self.get_logger().info("[ roll, pitch, yaw] = [" + str(self.roll) +
", " + str(self.pitch) + ", " + str(self.yaw) + "]")