【问题标题】:Lejos NXT ClassFormatExceptionLejos NXT ClassFormatException
【发布时间】:2018-11-13 15:13:20
【问题描述】:

我正在尝试将我的脚本从我的笔记本电脑上传到我的 NXT Bot。使用电线连接到 NXT。当我按下 Run as NXT 按钮时,出现以下错误:

js.tinyvm.TinyVMException: Invalid byte tag in constant pool: 15
 ....  
Caused by: org.apache.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 15
Linking the file failed with exit status 1

我查看了类似的问题,但他们遇到了我的代码未使用的排队问题。我正在使用的代码:

  public class move {

   public static void main() {

   Motor.B.setSpeed(300);
   Motor.A.setSpeed(720);// 2 RPM
   Motor.C.setSpeed(720);


   Motor.A.forward();
   Motor.C.forward();
   Motor.B.rotateTo(90);
   Delay.msDelay(1000);
   Motor.A.stop();
   Motor.C.stop();
   Motor.B.rotateTo(-90);
   Delay.msDelay(1000);
   Motor.A.rotate( 90);
   Motor.C.rotate(90);


 }

} 

【问题讨论】:

    标签: java lejos-nxj


    【解决方案1】:

    出现问题是因为我的 JDK 是 1.8,而 NXT 需要 1.7 版本的 JDK

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2015-12-19
      • 1970-01-01
      • 2015-09-14
      • 2011-08-14
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多