Jump to content
43oh

(Hopefully) Simple i2c/Wire Library Question


Recommended Posts

I noticed the Energia i2c Library doesn't support sending multiple bytes through Wire.write().

 

Additionally, when the master requests 2 bytes, using Wire.write() twice on the slave will only send one byte...

 

Is this due to a technical limitation of the MSP430-line device?  Is there a good work around?

 

Thanks

Link to post
Share on other sites

Alright, in case anyone is wondering, yes, these are the kinds of questions when I get both a little tired and pretty frustrated.

 

I dug through the twi.c & wire.cpp files to of course find the both Wire.write(data) and Wire.write(data, length) functions.  For whatever reason, the compiler didn't like what I was sending to it in the Wire.length(data, length) function when I originally asked the question.  I played around with it, and, truth be told I'm not entirely sure what I did differently, but, I was able to compile a sketch.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...