BlueRov2- Method for additional sensor integration

The Pixhawk Aux outputs can be configured as GPIO. In fact, I think you can control this board (the control signal looks to be just HIGH/LOW) without writing any code or adding any additional hardware. You can assign joystick buttons to control up to toggle up to 4 GPIO on the pixhawk (use the relay functions and set BRD_PWM_COUNT parameter to 2 to disable pwm on aux3 and aux4 and reconfigure for GPIO).

Okay. The longer the thread the easier it gets… :wink:

I’m using this method for two analog sensors and am able to read the data through Putty just fine, but I am trying to find a way to have Putty send the data directly to Matlab so that I can import into a real-time GUI I have made. Does anyone have experience doing something of this sort? I am not sure if there is a way to do this using port forwarding from Putty?

Are you using putty with SSH, serial or telnet ?
I’m pretty sure that matlab have all this interfaces already implemented.

I’m using SSH, I have attempted to connect directly with Matlab via SSH but was unable to ever receive packets from the pi. To do this I was attempting to use some functions which access the Ganymed-SSH2 javalib. Through the use of Plink I can get the sensor data to appear in the command window of Matlab, but I would ideally like to be able to read the data instead of just printing to the command window.

It sounds like you need some help with matlab, and you might get some more information if you asked about this in a matlab forum.

My favorite way to transfer data between two computers is with udp sockets, and nc is an easy command line tool to do this in linux (on the raspberry pi).