[Mono-devel-list] exposing internalcalls
Vasco Lemoine
vasco.lemoine at imtech.nl
Mon Jan 26 03:53:18 EST 2004
Miguel de Icaza wrote:
>Hello,
>
>
>
>>I want to use some homemade internalcalls. I've read the MonoEmbed
>>tutorial and it works fine.
>>I would like to know if I can expose the internalcalls without starting
>>the runtime from within the c-code.
>>I've tried compiling the c-code into a .so but i end up with the
>>following.
>>
>>** (test.exe:23657): WARNING **: cant resolve internal call to
>>"MyInternalcall::something()" (tested without signature also)
>>
>>Is there anyway of getting it to work.
>>
>>
>
>Can you describe the usage scenario you have in mind? You have to
>register the internal call at some point from C.
>
>
>.
>
>
>
Miguel,
Thanx for your reply ( and al the cool software).
Anyway, what i'm trying todo is the following. The aim is to get some
info from the /proc filesystem to mono land. I gues i could open just a
file handle but i wan't to to see how to expand the mono framework. So
i've made some c-code that gets some cpu-info from /proc end passes it
to mono land in the form of a monostring using an internall call.
Now the code works fine when i start the mono runtime from the c-code
and use add_internal_call() and than mono_jit_exec( ) etc.
What i would like to know is is there a way of using the internal call
without starting the mono runtime from c-code.
e.g. mono myassembly.exe and myassembly uses a internall call in the c-code.
Or is p/invoke the only way? can use p/invoke to register a
internal-call and than use it?
The code i wan't to make is more a proof of concept than highly usable
but what i have in mind in the future is controlling some piece of
hardware maybe a (soft/hard)realtime process in c-code that can be
interfaceded by mono.
Thanx
--
Met vriendelijke groet,
Vasco Lemoine
Imtech ICT Technical Systems
Postbus 1608
3800 BP Amersfoort
Tel. +31 (0)33 454 33 33
Fax +31 (0)33 454 33 35
E-mail vasco.lemoine at imtech.nl
Site www.imtechict.nl
More information about the Mono-devel-list
mailing list