lkml.org 
[lkml]   [2015]   [May]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC] i2c-tools: i2ctransfer: add new tool

> Having slept over it, I came up with a 3rd proposal:
>
> # i2ctransfer 0 w0x11@0x50 0xc0 0xbd= r1@0x51
>
> That is, combining the slave address, direction and length into a
> single parameter. The advantage is that this is all more explicit and
> the risk of mixing up values is close to zero. Whether it is more or
> less readable than the previous proposals is probably a matter of
> taste. Also I suspect it would make the parsing and state machine more
> simple, but that's only a nice side effect.
>
> Wolfram (and others), please tell me what you think. I am not trying to
> force my views here, just suggesting alternatives for your
> consideration.

I liked your proposal, so thanks for this input. I agree that the risk
of mixing something up is high, I was okay with the printout of the
messages to be sent, but a better syntax is very welcome, too. I need to
think about the flags a little bit, though. Although this isn't
implemented yet, PEC and 10-bit flags might be added in the future?
Handling R/W as "just another" flag made this option extremly simple.
But we probably can work something out.

So much for the quick response, I'll have a closer look later.

[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-05-08 16:41    [W:0.127 / U:0.112 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site