Hey, see inline.
On Wed, Oct 5, 2016 at 2:52 PM, Kevin Miller wrote:
> I'm connecting a IOIO to a hobbyist robot which also has a UART. I plan to
> use the IOIOService because there will be other sensors attached to the
> IOIO by UART and I want to be able to handle I/O in a timely manner. Is
> there a full, simple example of using a UART (or 2) in a service?
>
Not that I'm aware of, but there's not much to it. If you look at the
HelloIOIOService example app together with the UART JavaDocs and/or wiki
page, you should be able to get going fairly easily (at least as far as
using the UART).
> I have several questions:
>
> 1. If there is a temporary loss of connection, say a Bluetooth hiccup,
> what disconnected() do with the UARTs? There may be data in the buffers,
> will it be lost? Will the uart created by openUart() be destroyed/undefined?
>
Upon disconnect, the IOIO instance and all the interfaces created from it
(Uart included) become invalid. If there's any unread data it will be lost.
> Should the setup() skip openUart() if it was opened in a previous setup()?
>
No. The next setup() gets a fresh instance of the IOIO, that is, it start
from a clean state again.
>
> Thanks,
> Kevin
>
> --
> You received this message because you are subscribed to the Google Groups
> "ioio-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ioio-users+unsubscr...@googlegroups.com.
> To post to this group, send email to ioio-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/ioio-users.
> For more options, visit https://groups.google.com/d/optout.
>
--
You received this message because you are subscribed to the Google Groups
"ioio-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to ioio-users+unsubscr...@googlegroups.com.
To post to this group, send email to ioio-users@googlegroups.com.
Visit this group at https://groups.google.com/group/ioio-users.
For more options, visit https://groups.google.com/d/optout.