SnoBotics981 / RaspberryPi

1 stars 0 forks source link

Unable to view images #14

Open steelewool opened 5 years ago

steelewool commented 5 years ago

I'm getting the following errors in vision.err

java.io.IOException: /linux/nativearm/ntcorejni.hash Resource not found at edu.wpi.first.wpiutil.RuntimeLoader.loadLibrary(RuntimeLoader.java:69 ) at edu.wpi.first.networktables.NetworkTablesJNI.(NetworkTablesJN I.java:23) at edu.wpi.first.networktables.NetworkTableInstance.getDefault(NetworkTa bleInstance.java:97) at Main.(Main.java:17) pi@raspberrypi:~/RaspberryPi/output $

Also, my successes were using an old version of the software. This was the new one in master.

steelewool commented 5 years ago

captureforzach

zcsteele commented 5 years ago

I'm able to reproduce that error on my end. I'll poke at it & see if I can find some relevant information.

steelewool commented 5 years ago

It looks like the error is on line 17:

public class Main { private static VisionProcessor vision; (17) public static final NetworkTableInstance netTable = NetworkTableInstance.getDefault(); private static NetworkTable data; private static CameraServer manager = CameraServer.getInstance();

I'm looking into that as well.

steelewool commented 5 years ago

It looks like the error is that the java program can't find: /linux/nativearm/ntcorejni.hash

This does exist on my machine - but I don't know the syntax for how to change the runCameraVision script to be able to find it.

steelewool commented 5 years ago

Created a branch, updates-to-build-gradle, that is at least pushing images to the network interface. I made two major changes. One in the build.grade file:

// old code: // from (ntcoreUnzipLocation + "/linux/nativearm") { from (ntcoreUnzipLocation + "/linux/raspbian") {

and in main.java:

public static void main(String[] args) { // Loads our OpenCV library. This MUST be included System.loadLibrary("opencv_java310"); //** System.loadLibrary("ntcore");

So it looks like I just need to figure out how to get the system.loadLibrary of ntcore working.