Re: Accessing peripherals from a managed application



Bruce,

Thanks for the post. I do have the drivers for the hardware since they
came with the devevelopment board. What I have not figure out is how
to access to the driver from a managed application. From what I have
gathered, this is the sequence for developing a managed application
with VS2005 and PB (WinCE 5.0)

1. Create an OS image wtih PB.
2. Somehow figure out the headers contained in coredll.dll
3. use dllimport to import coredll.dll in the managed application in
VS2005.
4. Call on the imported functions to access the hardware.

Am I far off? The first experiment that I want to do is just to send
some data through the SPI or UART from a managed app. Again, thanks
for any additional input.

Best Regards,

Mario




Bruce Eitman (eMVP) wrote:
Mario:

Since nobody else replied, I will. I am not a Managed App developer, but I
can tell you how this is typically done.

Typically, the hardware is accessed via a driver written in C/C++, then a
managed app accesses the driver to access the hardware. It is intentionally
difficult, or impossible, to access hardware from managed code.

--
Bruce Eitman (eMVP)
Senior Engineer
beitman AT applieddata DOT net

Applied Data Systems
www.applieddata.net
An ISO 9001:2000 Registered Company
Microsoft WEP Gold-level Member

"Mario" <alphatommy@xxxxxxxxxxx> wrote in message
news:1149526298.777516.168540@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,

I would appreciate it if someone could point me to a link, docs, or
tutorials regarding peripheral access from a managed application.
Things that I am interested in includes simple initialization and usage
of the SPI interface or GPIOs. I am using XScale with Win CE 5.0 and
developing the managed application with VS2005(C#). Thanks in advance.


Best Regards,

Mario


.



Relevant Pages

  • Re: Accessing peripherals from a managed application
    ... You call the Win32 APIs for serial ports. ... beitman AT applieddata DOT net ... Maybe you open the driver with CreateFile, ... Call on the imported functions to access the hardware. ...
    (microsoft.public.windowsce.app.development)
  • [opensuse] openSUSE 10.3 not detecting SATA HD
    ... the sata_sis driver. ... I've tried turning off ACPI in bios and acpi=off which ... openSUSE 10.2 and all my hardware is working fine. ... info.product = 'USB Raw Device Access' ...
    (SuSE)
  • Re: 2008 SBS no longer boots
    ... driver issue initially, the fact that it seems to happen randomly now ... weird with a hardware problem that consistently doesn't get through boot ... other customer, even a 2 week old one, the problem immediately returned. ... There was a time when a server was fired up with a specialized OS and had a battery of tests run against each component to purposefully stress it. ...
    (microsoft.public.windows.server.sbs)
  • Re: Linux, X, ld, gcc, linking, shared libraries and stuff
    ... >> because, originally, video cards / system RAM could NOT afford to have ... > GL actually "copies" everything, but it's done by the graphics card, so ... > anyway if it's not hardware accelerated. ... installed the proper driver, then it zooms around the screen... ...
    (alt.lang.asm)
  • Re: 2008 SBS no longer boots
    ... Any thermal issues and a lot of other hardware problems should show up ... Happen to know a tool to determine driver load order by just having the ... other customer, even a 2 week old one, the problem immediately returned. ... There was a time when a server (even one that had been "burned ...
    (microsoft.public.windows.server.sbs)