Trond Enger / d7a_1x

Fork of d7a_1x by WizziLab

Revision:
53:3e4aa4b57090
Parent:
51:644de6fe1ee7
Child:
55:5ea18a3a01b9
--- a/src/d7a.cpp	Tue Sep 06 15:23:39 2016 +0000
+++ b/src/d7a.cpp	Tue Sep 06 15:42:42 2016 +0000
@@ -12,15 +12,7 @@
 bool g_open = false;
 bool g_local_fs = false;
 
-//======================================================================
-// d7a_open
-//----------------------------------------------------------------------
-/// @brief                      Open D7A driver and start the modem
-/// @param d7a_com_config_t*    Com port configuration structure
-/// @param PinName              Reset pin
-/// @param d7a_fs_callbacks_t*  File system callbacks (You declare files if this is not specified)
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_open(const d7a_com_config_t* com_config, PinName reset_pin, const d7a_callbacks_t* callbacks)
 {
     FPRINT("\r\n");
@@ -58,12 +50,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_close
-//----------------------------------------------------------------------
-/// @brief                      Close D7A driver and stop the modem
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_close(void)
 {
     FPRINT("\r\n");
@@ -80,12 +67,6 @@
 }
 
 
-//======================================================================
-// d7a_start
-//----------------------------------------------------------------------
-/// @brief                      Start the modem
-/// @return d7a_errors_t        Error code
-//======================================================================
 d7a_errors_t d7a_start(void)
 {
     FPRINT("\r\n");
@@ -97,12 +78,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_stop
-//----------------------------------------------------------------------
-/// @brief                      Stop the modem (goes to low power)
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_stop(void)
 {
     FPRINT("\r\n");
@@ -114,18 +90,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_create
-//----------------------------------------------------------------------
-/// @brief                      Creates a file on the modem
-/// @param d7a_fs_storage_t     Type of file
-/// @param d7a_fs_perm_t        Access permissions
-/// @param uint32_t             Length of the created file
-/// @param uint32_t             Maximum size of the file
-/// @param uint8_t              File ID to an eventual Action file
-/// @param uint8_t              File ID to an eventual Interface file
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_create(const uint8_t file_id, d7a_fs_storage_t prop, d7a_fs_perm_t perm, uint32_t size, uint32_t alloc, uint8_t action_file, uint8_t interface)
 {
     FPRINT("\r\n");
@@ -152,19 +117,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_declare
-//----------------------------------------------------------------------
-/// @brief                      Declare a file stocked on the host to the modem (need to have implemented the fs_callbacks)
-/// @param uint8_t              File ID of file to declare
-/// @param d7a_fs_storage_t     Type of file
-/// @param d7a_fs_perm_t        Access permissions
-/// @param uint32_t             Length of the created file
-/// @param uint32_t             Maximum size of the file
-/// @param uint8_t              File ID to an eventual Action file
-/// @param uint8_t              File ID to an eventual Interface file
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_declare(const uint8_t file_id, d7a_fs_storage_t prop, d7a_fs_perm_t perm, uint32_t length, uint32_t alloc, uint8_t action_file, uint8_t interface)
 {
     FPRINT("\r\n");
@@ -193,18 +146,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_read
-//----------------------------------------------------------------------
-/// @brief                      Read data from a file
-/// @param uint8_t              File ID of file to read
-/// @param uint32_t             Offset from which to start reading
-/// @param uint32_t             Size of data to read
-/// @param uint8_t*             Buffer to retrieve data
-/// @param d7a_addressee_t*     Addressee to an eventual distant device
-/// @param alp_rpol_t           Index to the retry policy to use
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_read(const uint8_t file_id, const uint32_t offset, const uint32_t size, const uint8_t* buf, d7a_addressee_t* addressee, alp_rpol_t retry)
 {
     FPRINT("\r\n");
@@ -220,18 +162,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_write
-//----------------------------------------------------------------------
-/// @brief                      Write data to a file
-/// @param uint8_t              File ID of file to write
-/// @param uint32_t             Offset from which to start writing
-/// @param uint32_t             Size of data to write
-/// @param uint8_t*             Buffer of the data to write
-/// @param d7a_addressee_t*     Addressee to an eventual distant device
-/// @param alp_rpol_t           Index to the retry policy to use
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_write(const uint8_t file_id, const uint32_t offset, const uint32_t size, const uint8_t* const buf, d7a_addressee_t* addressee, alp_rpol_t retry, bool resp)
 {
     FPRINT("\r\n");
@@ -247,16 +178,7 @@
     return err;
 }
 
-//======================================================================
-// d7a_write
-//----------------------------------------------------------------------
-/// @brief                      Write data to a file
-/// @param uint8_t              File ID of file to write
-/// @param uint32_t             Offset from which to start writing
-/// @param uint32_t             Size of data to write
-/// @param uint8_t*             Buffer of the data to write
-/// @return d7a_errors_t        Error code
-//======================================================================
+
 d7a_errors_t d7a_notify(const uint8_t file_id, const uint32_t offset, const uint32_t size)
 {
     FPRINT("\r\n");
@@ -279,11 +201,6 @@
 }
 
 
-//======================================================================
-// d7a_modem_print_infos
-//----------------------------------------------------------------------
-/// @brief                      Prints the modem infos
-//======================================================================
 void d7a_modem_print_infos(void)
 {
     uint8_t uid[8];