| | Ir transmission Benoit Cerrina
|
| | Hi, is there any way to send IR messages using pbForth. This is in order to use the IR proximity detector commonly used with nqc programs. Also I think that with alternative firmware such as pbForth and nqc, it should be possible to do it without (...) (26 years ago, 29-Mar-99, to lugnet.robotics.rcx.pbforth)
|
| | |
| | | | RE: Ir transmission Ralph Hempel
|
| | | | (...) YES!!! The standard FORTH word U. prints an insigned integer, while EMIT sends out an arbitrary byte. So, for a simple IR proximity detector, you would write something like: HEX 0 SENSOR_ACTIVE (labelled sensor #1) 3 1 SENSOR_TYPE (light (...) (26 years ago, 30-Mar-99, to lugnet.robotics.rcx.pbforth)
|
| | | | |
| | | | | | Re: Ir transmission John Cooper
|
| | | | | | (...) Perhaps EMIT? would do (...) I'm nearly done with my NQC to pbFORTH port of the IR proximity detector, but I'm stuck where I have at present got a 30ms delay (Sleep(3) in NQC). I expect it isn't critical but the current detector works so well (...) (26 years ago, 14-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | | |
| | | | | | | | RE: Ir transmission Ralph Hempel
|
| | | | | | | (...) Alas, I only used the firmware timers available as core RCX firmware calls. I can look through Kekoa's disassembly to see if there are higher resolution timers available ( I think the motor timers might be useful ) In general, NQC hooks in (...) (26 years ago, 15-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | | | |
| | | | | | | | | Re: Ir transmission John Cooper
|
| | | | | | | (...) The bytecode interpreter does it, which is what NQC maps to (opcode 43). I'd prefer a timer (or access to a clock) with millisecond resolution rather than a delay because things will get interesting whan multitasking. What is the CPU clock (...) (26 years ago, 16-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | | | |
| | | | | | | | | RE: Ir transmission Ralph Hempel
|
| | | | | | | (...) I think its around 16 Mhz for the crystal and 4 MHz for the cycle time. I think there is a msec timer buried in the OC1A handler (see Kekoa's disassembly) I agree that we want something to trigger a run flag instead of having to check the (...) (26 years ago, 16-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | | | |
| | | | | | | | | Re: Ir transmission John Cooper
|
| | | | | | | (...) Well, in the spirit of FORTH there should be no finite number, just create and destroy them on the fly as and whan you need them. I have been wandering around the internet looking and found that hForth has one already: \ hForth multitasker \ \ (...) (26 years ago, 17-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | | | |
| | | | | | Re: Ir transmission John Cooper
|
| | | | | (...) I can't get EMIT to work, in NQC I do this: SendMessage(255); // Flash Sleep(3); ThisRaw = RAW_LIGHT; and the raw light sensor reading has big spikes for IR reflections. but: [ HEX ] FF EMIT 30 msWait RawLight LIGHT? does not, I think that (...) (26 years ago, 10-May-99, to lugnet.robotics.rcx.pbforth)
|
| | | | | |
| | | | Re: Ir transmission John Cooper
|
| | | | (...) My next project is to port the IR proximity dectector originally posted by Mark R. David (markdavid@mediaone.net) in sort-of-Spirit code which I reposted in NQC whan I had got it working. It is the best performing detector I have found so far. (26 years ago, 4-Apr-99, to lugnet.robotics.rcx.pbforth)
|
| | | | |