smatsuda6 / nav6

Automatically exported from code.google.com/p/nav6
0 stars 0 forks source link

Fix bug in Java IMU class Constructor #6

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Reported by Will Marshall

I think there's a bug in your Java implementation. You use the empty 
constructor for Thread and then call start(), which results in running a thread 
with a NOP run() method. I think you meant to pass the IMU object to the thread 
constructor, which would result in the run() method of the IMU being called.

I could be wrong about this if the sunspot JVM does something weird with the 
empty constructor though. I'll take another look when I get a chance to 
actually run the code.

Original issue reported on code.google.com by scottlib...@gmail.com on 8 Jan 2014 at 3:30

GoogleCodeExporter commented 8 years ago
Fixed, modified Thread constructor to take "this" as a parameter; "this" is the 
reference to the IMU class instance, which implements the Runnable interface.

Original comment by scottlib...@gmail.com on 8 Jan 2014 at 3:33

GoogleCodeExporter commented 8 years ago

Original comment by scottlib...@gmail.com on 8 Jan 2014 at 3:33