diff options
| author | Bdale Garbee <bdale@gag.com> | 2015-02-07 22:39:54 -0700 | 
|---|---|---|
| committer | Bdale Garbee <bdale@gag.com> | 2015-02-07 22:39:54 -0700 | 
| commit | f766a457323268857b3f2dfc7f42427437b71cb7 (patch) | |
| tree | 8afc8a661d682fc34b16fc0b1b44f2844d34f336 /altoslib/AltosCSV.java | |
| parent | db51224af01731e7323f6f696a7397d64eb80b92 (diff) | |
| parent | e2cefd8593d269ce603aaf33f4a53a5c2dcb3350 (diff) | |
Merge branch 'branch-1.6' into debian
Conflicts:
	ChangeLog
	altoslib/AltosTelemetryReader.java
	configure.ac
Diffstat (limited to 'altoslib/AltosCSV.java')
| -rw-r--r-- | altoslib/AltosCSV.java | 19 | 
1 files changed, 6 insertions, 13 deletions
diff --git a/altoslib/AltosCSV.java b/altoslib/AltosCSV.java index 4a9278d9..02f7806f 100644 --- a/altoslib/AltosCSV.java +++ b/altoslib/AltosCSV.java @@ -15,7 +15,7 @@   * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.   */ -package org.altusmetrum.altoslib_5; +package org.altusmetrum.altoslib_6;  import java.io.*;  import java.util.*; @@ -158,21 +158,14 @@ public class AltosCSV implements AltosWriter {  	}  	void write_advanced_header() { -		out.printf("accel_x,accel_y,accel_z,gyro_x,gyro_y,gyro_z"); +		out.printf("accel_x,accel_y,accel_z,gyro_x,gyro_y,gyro_z,mag_x,mag_y,mag_z");  	}  	void write_advanced(AltosState state) { -		AltosIMU	imu = state.imu; -		AltosMag	mag = state.mag; - -		if (imu == null) -			imu = new AltosIMU(); -		if (mag == null) -			mag = new AltosMag();  		out.printf("%7.2f,%7.2f,%7.2f,%7.2f,%7.2f,%7.2f,%7.2f,%7.2f,%7.2f", -			   imu.accel_x, imu.accel_y, imu.accel_z, -			   imu.gyro_x, imu.gyro_y, imu.gyro_z, -			   mag.x, mag.y, mag.z); +			   state.accel_along(), state.accel_across(), state.accel_through(), +			   state.gyro_roll(), state.gyro_pitch(), state.gyro_yaw(), +			   state.mag_along(), state.mag_across(), state.mag_through());  	}  	void write_gps_header() { @@ -381,7 +374,7 @@ public class AltosCSV implements AltosWriter {  				has_basic = true;  			if (state.battery_voltage != AltosLib.MISSING)  				has_battery = true; -			if (state.imu != null || state.mag != null) +			if (state.accel_across() != AltosLib.MISSING)  				has_advanced = true;  			if (state.gps != null) {  				has_gps = true;  | 
