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: RN52.h
- Revision:
- 7:2df2c6e8c0df
- Parent:
- 6:c454f88524d6
- Child:
- 8:beb6c399490a
--- a/RN52.h Wed Jan 13 22:11:50 2016 +0000 +++ b/RN52.h Thu Jan 14 22:20:38 2016 +0000 @@ -1,8 +1,6 @@ #ifndef RN52_H #define RN52_H -#define STRING_BUFFER_LENGTH 255 - typedef enum { RN52_REBOOT, @@ -44,6 +42,7 @@ RN52_NO_EVENT, RN52_CALLER_ID_EVENT, RN52_TRACK_CHANGE_EVENT, + RN52_OTHER_EVENT, RN52_EVENT_LAST @@ -55,14 +54,14 @@ bool media_connected; bool phone_connected; RN52_CONNECTION connection; - char title[STRING_BUFFER_LENGTH]; - char artist[STRING_BUFFER_LENGTH]; - char album[STRING_BUFFER_LENGTH]; - char genre[STRING_BUFFER_LENGTH]; + char title[255]; + char artist[255]; + char album[255]; + char genre[255]; int duration; int track_number; int track_count; - char response[STRING_BUFFER_LENGTH]; + char response[255]; } RN52_RESULT; @@ -87,6 +86,8 @@ bool get(RN52_COMMAND cmd, RN52_RESULT * rn52_result); bool capture_response(char * str); void clear_serial(); + void copy_response(char * source, char * destination, char offset); + void clear_result(RN52_RESULT * result); }; #endif \ No newline at end of file