From: Alexander Graf <alexander.graf@ilr.tu-berlin.de>
To: Paolo Bonzini <pbonzini@redhat.com>,
Peter Maydell <peter.maydell@linaro.org>,
Alexander Graf <graf@campus.tu-berlin.de>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] hw/arm: add Lego NXT board
Date: Tue, 15 Jul 2014 12:26:37 +0200 [thread overview]
Message-ID: <53C501DD.3090805@ilr.tu-berlin.de> (raw)
In-Reply-To: <53C4D2FC.50402@redhat.com>
On 07/15/2014 12:48 AM, Peter Maydell wrote:
> Right, but this is an optional part of Paolo's proposal as I understand
> it. You could just have your fake sensors be implemented by some
> userspace process on the other end of a filedescriptor, as you do now
> but with i2c rather than custom protocol. This would also let you run
> the same bit of firmware in the guest as would be on the real h/w.
>
Ah, thank you, I finally realised that you are talking about the
-chardev argument (I just discovered that option.) and not only about
linux character devices. It seems I reinvented the wheel while
implementing the pipes. What a waste of time :)
On 07/15/2014 09:06 AM, Paolo Bonzini wrote:
> As to the protocol, I found a datasheet of an I2C-to-UART bridge that
> could provide ideas:
> http://www.nxp.com/documents/data_sheet/SC18IM700.pdf chapter 7, it's
> very simple (just two commands, start and stop).
Thanks for the idea. I still don't get why it should be better to fake
an I2C device rather than a universal memory IO. I don't want to emulate
the controllers hardware, but only communicate the abstract
sensor/actuator values. In addition not all Sensors are I2C devices, so
there is no value in doing it via an I2C bus. Even the simple I2C
protocol mentioned in the data sheet is more complex than mine.
Could you point me to the code where the chardev devices are defined in
qemu?
Alexander
next prev parent reply other threads:[~2014-07-15 10:24 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-13 14:20 [Qemu-devel] hw/arm: add Lego NXT board Alexander Graf
2014-07-14 11:23 ` Peter Crosthwaite
2014-07-14 11:46 ` Paolo Bonzini
2014-07-14 18:09 ` Alexander Graf
2014-07-14 20:37 ` Paolo Bonzini
2014-07-14 21:10 ` Alexander Graf
2014-07-14 22:48 ` Peter Maydell
2014-07-15 7:06 ` Paolo Bonzini
2014-07-15 10:26 ` Alexander Graf [this message]
2014-07-15 10:53 ` Paolo Bonzini
2014-07-15 18:55 ` Alexander Graf
2014-07-15 20:09 ` Paolo Bonzini
2014-07-16 8:40 ` Alexander Graf
2014-07-16 8:50 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53C501DD.3090805@ilr.tu-berlin.de \
--to=alexander.graf@ilr.tu-berlin.de \
--cc=graf@campus.tu-berlin.de \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).