Having been through this exercise with I2C, let me confirm what Matthias
has stated.

The address sent to the device contains a 1 for WRITE; 0 for READ in the
least significant bit position.

Regards,

Michael
K6MLE


On 11/21/2013 10:49 PM, Matthias Trute wrote:
> Hi Craig,
>
> > In the function <i2c the code begins with twi.start 1+ twi.tx 1-
> > dup 0 >
>
> > Is the 1+ a typo? If not I do not understand why you would add one
> > to the hardware address before sending it out.
>
> This is the way some (most?, all?) i2c devices distinguish between read
> and write access. The datasheet for your i2c device should tell you the
> details
>
> Matthias
>
>
>
------------------------------------------------------------------------------
> Shape the Mobile Experience: Free Subscription
> Software experts and developers: Be at the forefront of tech innovation.
> Intel(R) Software Adrenaline delivers strategic insight and game-changing
> conversations that shape the rapidly evolving mobile landscape. Sign
up now.
>
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
> _______________________________________________
> Amforth-devel mailing list for http://amforth.sf.net/
> Amforth-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/amforth-devel


------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing 
conversations that shape the rapidly evolving mobile landscape. Sign up now. 
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Amforth-devel mailing list for http://amforth.sf.net/
Amforth-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amforth-devel

Reply via email to