Quantcast
Channel: Wireless Connectivity
Viewing all articles
Browse latest Browse all 116964

Forum Post: RE: New problem about write three bytes to simple peripheral characteristic.

$
0
0

Hello Aslak,

Still the code I provided before: 

      //Write the value
      if ( status == SUCCESS )
      {
        VOID osal_memcpy( simpleProfileChar3, pValue, len ); // len == 3  

     if( pAttr->pValue == simpleProfileChar3 )
        {
          notifyApp = simple_Profile_CHAR3;       
        }
      }

      else
      {      
        status = ATT_ERR_ATTR_NOT_FOUND;
      }

Without the code highlighted, the simple peripheral profile can be written with three bytes and the three bytes can be read. However, since there is no "notifyApp", I cannot do operation on the three bytes.

However, if the highlighted code is included, the three bytes read from the CC2540 is different from the one I send out.

Is there any working sample code for writing multiple bytes?


Viewing all articles
Browse latest Browse all 116964

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>