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: DS1820 ExtendedTimer SDFileSystem mbed
Fork of FindingTemp by
Diff: main.cpp
- Revision:
- 1:a036633bc3c2
- Parent:
- 0:da5b15595769
- Child:
- 2:98ae1b36758e
--- a/main.cpp Mon Apr 17 19:09:35 2017 +0000
+++ b/main.cpp Mon Apr 17 20:32:43 2017 +0000
@@ -98,21 +98,34 @@
}
pc.printf("Found %d device(s)\r\n\n", num_devicest);
+
+ unsigned long long fullName;
+ unsigned int firstName;
+ unsigned int lastName;
// Write header row to each file with device IDs
//tail
fprintf(outputt,"Time\t");
for(int count = 0; count < num_devicest; count ++) {
- fprintf(outputt, "%x\t", probeTail[count]);
+ fullName = probeTail[count]->whoAmI();
+ firstName = fullName >> 32;
+ lastName = fullName;
+ fprintf(outputt, "%x%x\t", firstName, lastName);
}
//Arm1
fprintf(output1,"Time\t");
for(int count = 0; count < num_devices1; count++) {
- fprintf(output1, "%x\t", probe1[count]);
+ fullName = probe1[count]->whoAmI();
+ firstName = fullName >> 32;
+ lastName = fullName;
+ fprintf(output1, "%x%x\t", firstName, lastName);
}
fprintf(output2,"Time\t");
//Arm2
for(int count = 0; count < num_devices2; count++) {
- fprintf(output2, "%x\t", probe2[count]);
+ fullName = probe2[count]->whoAmI();
+ firstName = fullName >> 32;
+ lastName = fullName;
+ fprintf(output2, "%x%x\t", firstName, lastName);
}
fprintf(outputt,"\r\n");
fprintf(output1,"\r\n");
