Subject:
|
Re: is IR considered broken?
|
Newsgroups:
|
lugnet.robotics.rcx.legos
|
Date:
|
Fri, 16 Jul 1999 14:23:34 GMT
|
Viewed:
|
1336 times
|
| |
| |
Yes I would be interested in seeing the libRcx implementation of the IR
functions.
thanks,
Mark
Kekoa Proudfoot wrote:
> Mark Falco <falcom@dialogic.com> wrote:
> > 4. If others have working code that uses IR, can you post it?
>
> I have working IR code, but it does not work with LegOS. It works with
> that "custom, as-yet-unreleased version of Librcx" I mention every so
> often. It probably wouldn't take much to port it to LegOS. Changes would
> be:
>
> - modify hook to get a function called once every ms
> - modify hooks that establish txi, tei, rxi, eri handlers
> - add a cleanup function
>
> The code supports datagrams; framing, complements, and error detection are
> included. I have another version which does not use complements which I
> believe I used to test the supposition that the complements are not really
> needed, back when that discussion was going on. The interface looks like
> this:
>
> /* Encodes and sends buf over the IR link */
> /* Returns 0 on error or if IR port is busy */
> extern int serial_send (void *buf, unsigned int len);
>
> /* Receives a message into buf, if one is ready */
> /* Returns 0 on error or if no message ready */
> extern int serial_recv (void *buf, unsigned int len);
>
> As far as I know, it transmits as reliably as it receives, but I could be
> wrong about that. There is currently no support for asynchronous
> notification of send complete or receive ready, but it would not be hard to
> add callbacks to support this.
>
> I can post the code if anybody is interested.
>
> On a side note, I thought somebody got LegOS's IR code to work with a small
> modification to remove the busy wait during transmit. Search the past
> messages at lugnet to see if that is really the case.
>
> -Kekoa
|
|
Message has 1 Reply:
Message is in Reply To:
| | Re: is IR considered broken?
|
| (...) I have working IR code, but it does not work with LegOS. It works with that "custom, as-yet-unreleased version of Librcx" I mention every so often. It probably wouldn't take much to port it to LegOS. Changes would be: - modify hook to get a (...) (25 years ago, 16-Jul-99, to lugnet.robotics.rcx.legos)
|
6 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|