Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: main.cpp
- Revision:
- 11:b62f06b3e398
- Parent:
- 10:02584efdaa39
- Child:
- 12:2f1e8b205d0f
--- a/main.cpp Thu Dec 03 15:37:40 2020 +0000 +++ b/main.cpp Sun Dec 06 21:22:00 2020 +0000 @@ -82,12 +82,12 @@ p_sensor.Barometer_MS5837(); //Depth Holding if (p_sensor.depth()>2.0) { - thruster.pulsewidth(1.0/1000.00); - thruster2.pulsewidth(1.0/1000.00); + thruster.pulsewidth(1.1/1000.00); + thruster2.pulsewidth(1.1/1000.00); } else if(p_sensor.depth()<2.0) { - thruster.pulsewidth(1.6/1000.00); - thruster2.pulsewidth(1.6/1000.00); + thruster.pulsewidth(1.5/1000.00); + thruster2.pulsewidth(1.5/1000.00); } else if(p_sensor.depth()==2.0) { thruster.pulsewidth(1.3/1000.00); @@ -176,13 +176,11 @@ { fp= fopen(fname, "a"); fprintf(fp, "$IMU,3,10, %f, %3.3f, %3.3f, %3.3f, %3.3f, %3.3f, %3.3f, %3.3f, %3.3f, %3.3f;\r\n",t.read(),accel[0],accel[1],accel[2],gyro[0],gyro[1],gyro[2],euler[0],euler[1],euler[2]); + fprintf(fp, "$SCI, 1, 3, %.3f, %.3f, %.3f; %\r\n", t.read(), t_sensor.temp(), Pcell.read()); fclose(fp); - //log system time t.read() - // log imu data, log sciene data + // log pulse width // log pressure sensor data. - //science sensor: temp.temp(), light.light() - //IMU sensor }