[Linux-Raspian] Warning: The runtime version supported by this application is unavailable

Hi,
I’m running a Raspbian version on linux.
I’ve downloaded the maestro-linux folder from Pololu - 3.b. Installing Linux Drivers and Software
I’ve also installed a latest version of libmono (mono-devel) from Redirecting…
The issue occurred when I run the command ./UscCmd, a warning message that says:
" The runtime version supported by the appliation is unavailable. Using default runtime: v4.0.30319 UscCmd, Version=1.5.3.0, Culture=neutral, PublicKeyToken=null"
Am I right to assume that the UscCmd version is not compatible for the libmono version?
Can someone please help to solve on this issue?? Any constructive advice would be greatly appreciated!!

Hello.

That warning is normal, so you can just ignore it. Our Maestro software was compiled for an earlier version of the Mono runtime, but newer versions are compatible enough that the software works fine on them. From your screenshot, I can see that UscCmd successfully printed its help screen after the warning.

You might consider compiling UscCmd yourself using the Pololu USB SDK if the warning message annoys you.

Please let me know if you have any further questions.

–David

Hi David,

Thank you so much for answering my question!
As of now I having another issue on the usb connection between my pi and the maestro controller. When I try typing the command “./UscCmd --list” to see the available devices there comes an error message says “System.DllNotFoundExpectation”. I’ve followed the instructions in README.txt for USB configuration but it seems like I couldn’t copy the 99-pololu.rules file to /etc/udev/rules.d/.
Is that the reason that caused the error?

The error System.DllNotFoundException: libusb-1.0 makes me think that libusb 1.0 is not installed. Please try running this command to install it:

sudo apt-get install libusb-1.0-0-dev

You will also need to copy the 99-pololu.rules file to /etc/udev/rules.d/. In case you are not familiar with copying files on Linux, the command to run is:

sudo cp 99-pololu.rules /etc/udev/rules.d/

–David

1 Like

Hi David,

Really appreciate the suggestions, it works for me!
However it comes with another problem (sorry I know is annoying), when I try to run a sample python code, an error occurs…
It’s in the line 6 saying “invalid syntax”, I have no idea why the error is there…

#!/usr/bin/python
import serial
import time

class PololuMicroMaestro(object):
  def__init__(self, port= "/dev/ttyACM0"):
     self.ser = serial.Serial(port = port)
  def setAngle(self, channel, angle):
      minAngle = 0.0
      maxAngle = 180.0
      minTarget = 256.0
      maxTarget = 13120.0
      scaledValue = int((angle / ((maxAngle - minAngle) / (maxTarget - minTarget))) + minTarget)
      commandByte = chr(0x84)
      channelByte = chr(channel)
      lowTargetByte = chr(scaledValue & 0x7F)
      highTargetByte = chr((scaledValue >> 7) & 0x7F)
      command = commandByte + channelByte + lowTargetByte + highTargetByte
      self.ser.write(command)
      self.ser.flush()
  def close(self):
      self.ser.close()
if__name__=="__main__":
  robot = PololuMicroMaestro()
  robot.setAngle(0,80)
  robot.setAngle(1,80)
  robot.setAngle(2,80)
  robot.setAngle(3,75)
  time.sleep(1)
#Lean Right
  robot.setAngle(2,90)
  robot.setAngle(0,110)
  time.sleep(1)
#Lean Left
  robot.setAngle(0,70)
  robot.setAngle(2,60)
  time.sleep(1)
#Step Forward Left
  robot.setAngle(2,90)
  robot.setAngle(0,110)
  time.sleep(.5)
  robot.setAngle(3, 100)
  time.sleep(.2)
  robot.setAngle(1,100)
  time.sleep(1)
#Step Forward Right
  robot.setAngle(0,70)
  robot.setAngle(2,60)
  time.sleep(.5)
  robot.setAngle(1, 50)
  time.sleep(.2)
  robot.setAngle(3,50)
  time.sleep(1)
#home position
  robot.setAngle(0,85)
  robot.setAngle(1,80)
  robot.setAngle(2,80)
  robot.setAngle(3,75)

Hello.

It looks like you are missing a space after def on this line:

def__init__(self, port= "/dev/ttyACM0"):

You are also missing a space after if on this line:

if__name__=="__main__":

–David

1 Like