old_contents: from can import Listener
  import socket
  
  class UDPSender(Listener):
      dataConvert = {"0x600": {"String":"RPM:",
                               "Slot":0,
                               "Conversion":1},
                     "0x601": {"String":"OIL:",
                               "Slot":2,
                               "Conversion":(1/81.92)}}
      
      def __init__(self, IP="10.0.0.4", PORT=5555):
          self.ip = IP
          self.port = PORT
          self.sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
          
      def on_message_received(self, msg):
          udpMessage = self.can_to_udp_message(msg)
          if udpMessage:
              self.sock.sendto(udpMessage.encode(), (self.ip, self.port))
          
      def can_to_udp_message(self, msg):
          hexId = msg.arbritation_id
          if self.dataConvert.get(hexId):
              dataId = self.dataConvert[hexId]["String"]
              dataSlot = self.dataConvert[hexId]["Slot"]
              dataConversion = self.dataConvert[hexID]["Conversion"]
              data = ( (msg.data[dataSlot] << 8) + msg.data[dataSlot + 1] ) * dataConversion
              udpMessage = dataId + data
              return udpMessage
          else:
              return None
          
      def __del__(self):
          self.sock.close()
  
new_contents: from can import Listener
  from socket import socket
  
  class UDPSender(Listener):
      dataConvert = {"0x600": {"String":"RPM:",
                               "Slot":0,
                               "Conversion":1},
                     "0x601": {"String":"OIL:",
                               "Slot":2,
                               "Conversion":(1/81.92)}}
      
      def __init__(self, IP="10.0.0.4", PORT=5555):
          self.ip = IP
          self.port = PORT
          self.sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
          
      def on_message_received(self, msg):
          udpMessage = self.can_to_udp_message(msg)
          if udpMessage:
              self.sock.sendto(udpMessage.encode(), (self.ip, self.port))
          
      def can_to_udp_message(self, msg):
          hexId = msg.arbritation_id
          if self.dataConvert.get(hexId):
              dataId = self.dataConvert[hexId]["String"]
              dataSlot = self.dataConvert[hexId]["Slot"]
              dataConversion = self.dataConvert[hexID]["Conversion"]
              data = ( (msg.data[dataSlot] << 8) + msg.data[dataSlot + 1] ) * dataConversion
              udpMessage = dataId + data
              return udpMessage
          else:
              return None
          
      def __del__(self):
          self.sock.close()
  
subject: Change of import of libraries.