Re: Installable ISR - general questions



"Ole" <ole@xxxxxxxxxx> wrote in
news:OeCqMGu4GHA.4820@xxxxxxxxxxxxxxxxxxxx:

Hi,

Before digging to deep in trying to implement and learn about IISR
I would like to get some advises/answers if possible:

- Is it possible to use e.g. math functions like e.g. sin() etc.
in an ISR? - Is it possible to use memcpy()?

Those function may be used, provided that their implementation
doesn't involve some particulare hardware interaction (using DMA for
memcpy or using a math co-processor for sin). I think that you can
exclude this for the versions provided in the CE standard library.

- Is it possible to use the IoControl of the ISR to pass
parameters/data FROM the IST?
- Is it possible to use the IoControl of the ISR to pass
parameters/data TO the IST (lpOutBuf in KernelLibIoControl)?

This is what the IoControl mechanism is meant for.
The only issue is that the memory should be caller allocated so, if
the library needs to return a variable-lenght structure you'll have
to "over-allocate" it to the maximum size or provide 2 IO control
codes: one to retrieve the data size and one to read the actual data
(or provide a mechanism to handle the return of the size if the
buffer is too small from a single Io control code).

- I understand that the KLibAllocShareMem can be used to allocate
a common buffer of ISR and IST but what is the parameter nPages
defined - what if I would like to allocate e.g. 3000 bytes -what
should nPages then be set to?

This depends on your hardware architecture. You can retrieve it
using the GetSystemInfo API (from an application or driver, not
inside the kernel lib).


--
Valter Minute
(the reply address of this message is invalid)
(l'indirizzo di reply di questo messaggio non è valido)
.



Relevant Pages

  • Installable ISR - general questions
    ... Is it possible to use e.g. math functions like e.g. sinetc. in an ISR? ... Is it possible to use the IoControl of the ISR to pass parameters/data TO ... I understand that the KLibAllocShareMem can be used to allocate a common ... buffer of ISR and IST but what is the parameter nPages defined - what if I ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Does .S files defines and implements some fuctions for the ISR?
    ... Is ISR moving the data from the register to memory? ... The ISR should simply recognize the interrupt, disable it, and return ... You may find a sample of it in your BSP! ... (l'indirizzo di reply di questo messaggio non è ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Does .S files defines and implements some fuctions for the ISR?
    ... Is ISR moving the data from the register to memory? ... some platform you have ASM functions called by your ISR. ... The code you sent looks like startup code and not an ISR. ... (l'indirizzo di reply di questo messaggio non ?valido) ...
    (microsoft.public.windowsce.platbuilder)

Loading