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: Picaso_4DGL-32PTU_Response.cpp
- Revision:
- 23:dd2c28fa4dfd
- Parent:
- 22:cea582ea74c1
- Child:
- 26:c6a803706a42
diff -r cea582ea74c1 -r dd2c28fa4dfd Picaso_4DGL-32PTU_Response.cpp
--- a/Picaso_4DGL-32PTU_Response.cpp Tue Sep 27 08:48:08 2016 +0000
+++ b/Picaso_4DGL-32PTU_Response.cpp Tue Sep 27 10:45:38 2016 +0000
@@ -276,3 +276,22 @@
return error;
}
+//**************************************************************************
+short PICASO_4DGL :: getFilenameResponse(char *out) {
+
+ int i, j = 3;
+#if DEBUGMODE
+ pc.printf("\n\r DEBUG: Wait for filename answer");
+#endif
+ while (index < 3) wait_ms(100); // wait for screen answer
+ short len = rxBuf[1] << 8 | rxBuf[2];
+ //char *filename;
+ //filename = (char *)malloc(sizeof(char) * len);
+ //for(i = 0; i < size; i++) filename[i] = 0;
+ while (index < 3 + len) wait_ms(100); // wait for whole answer
+ for (i = 0; i < len; i++)
+ out[i] = rxBuf[j++]; // build filename string
+
+ return len;
+}
+