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.
Dependencies: mbed tsi_sensor FreescaleIAP MMA8451Q MPL3115A2
Revision 1:3a57bceb88f8, committed 2018-11-23
- Comitter:
- tuscasp
- Date:
- Fri Nov 23 17:07:30 2018 +0000
- Parent:
- 0:642dcee532b6
- Child:
- 2:1bd31ca8a126
- Commit message:
- base code for beer_project
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Mon Nov 12 22:13:57 2018 +0000
+++ b/main.cpp Fri Nov 23 17:07:30 2018 +0000
@@ -40,7 +40,7 @@
#define SECTOR_SIZE 1024
#define RESERVED_SECTOR 32
-#define ACQ_TIMER_PERIOD 0.010 // Time between 2 acquisitions in seconds
+#define ACQ_TIMER_PERIOD 0.20 // Time between 2 acquisitions in seconds
// Structure of sensors Data !!!!! SIZE MUST BE A MULTIPLE OF 4 bytes !!!!!
typedef struct{
@@ -105,7 +105,7 @@
float vdac;
uint16_t dac_value; // Local variable in 16 bits
- vdac = 0.3; // Voltage output value
+ vdac = 0; // Voltage output value
dac_value = (uint16_t) ((vdac * 65536) / KL25Z_VDD); // Transform desired voltage to fraction of 0xFFFF
myDAC.write_u16(dac_value); // DAC value in range 0x0000 - 0xFFFF (see mbed's AnalogOut classe ref.)
@@ -356,7 +356,7 @@
Record_Counter = 0;
Flash_Record_Ptr = 0;
- Host_Comm.printf("\n\rAccX AccY AccZ Temp PTE20 PTE21 PTE22");
+ Host_Comm.printf("\n\rti AccX AccY AccZ Temp PTE20 PTE21 PTE22");
while (Record_Counter < Max_Record)
{