]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/lib/net/blip/interfaces/Tcp.nc
commit svn HEAD of blip into core to start merge testing
[tinyos-2.x.git] / tos / lib / net / blip / interfaces / Tcp.nc
index 25f66ecba87e5b787447247e835289d921caf271..a87bb019663e464cc67858eec34219a2f7379c31 100644 (file)
@@ -4,14 +4,16 @@ interface Tcp {
 
   /*
    * Bind the socket to a local address
+   * 
    */
   command error_t bind(uint16_t port);
 
   /*
    * Accept an incomming connection.
+   *
+   * the app should return FALSE to reject the connection attempt
    */
   event bool accept(struct sockaddr_in6 *from, 
-                    void **rx_buf, int *rx_buf_len,
                     void **tx_buf, int *tx_buf_len);
 
   /*
@@ -20,7 +22,6 @@ interface Tcp {
    * The socket should not be used until connectDone is signaled.
    */
   command error_t connect(struct sockaddr_in6 *dest,
-                          void *rx_buf, int rx_buf_len,
                           void *tx_buf, int tx_buf_len);
   event void connectDone(error_t e);
 
@@ -36,6 +37,7 @@ interface Tcp {
    * terminate a connection.
    */
   command error_t close();
+  command error_t abort();
 
   /*
    * notify the app that the socket connection has been closed or
@@ -43,4 +45,11 @@ interface Tcp {
    * local side has given up.
    */
   event void closed(error_t e);
+
+  /* 
+   * returns TRUE if all previously sent data has been ACKed
+   */
+  event void acked();
+
+
 }