Re: Remote a CCD by a Matrox Frabe grabber [message #42665 is a reply to message #42630] |
Fri, 18 February 2005 13:58   |
Marc Reinig
Messages: 30 Registered: June 2004
|
Member |
|
|
You program a dll (Windows) or an so (UNIX) in 'C' that implements the
functionality you want. You do this in a specific way so IDL can use it.
(see the docs on DLM's and get Ronn Kling's book "Calling C from IDL",
http://www.rlkling.com.
Then , you can create a custom IDL function of procedure that implements all
the external calls you would have made. I have one for capturing images
that looks like:
res = lao_get_phx_image ( camera_number, rawimg, $
averaging, binning, roi_xstart, roi_ystart, $
roi_xsize, roi_ysize )
It captures an image (or a part of an image) from a camera. The code behind
it is about three pages of C, but I never have to do anything and it's
always there just like a regular IDL built-in function.
Marco
________________________
Marc Reinig
UCO/Lick Observatory
Laboratory for Adaptive Optics
"Fabrice Monti" <fabrice.monti@espci.fr> wrote in message
news:ba06b53f.0502180053.798e70c6@posting.google.com...
> just because i don't know the procedure and the reason to do this...
> could you expain what is the DLM and what is my avantage to create this
> file?
> thanks
>
> "Marc Reinig" <mreinig@ucolick.org> wrote in message
> news:<42152710$1@darkstar>...
>> Why not write a DLM?
>>
>> -- Marco
>>
>> ========================
>> Marc Reinig
>> UCO/Lick Observatory
>> Laboratory for Adaptive Optics
>>
>>
>> "Fabrice Monti" <fabrice.monti@espci.fr> wrote in message
>> news:ba06b53f.0502170048.47a67960@posting.google.com...
>>> Hi,
>>>
>>> I use IDL for a lot a applications, but now I have a Big problem.
>>> I would like to capture an image from a CCD. I use a frame grabber
>>> (matrox meteor2).
>>>
>>> For the moment, i use Matlab with a external call to the "Mil". It's a
>>> library which remote the frame grabber. Whit matlab, i can see, save
>>> and modify my image.
>>> But i wrote a IDL to calculate a lot of think on this image.
>>> I must save the image in a file with Matlab and read it with IDL...
>>> Grrrr...
>>>
>>> Do you think is it possible to replace to call external of Matlab by
>>> the same function in IDL... i tried to use "call_external" and
>>> "socket" function whitout succes....
>>> is it possible to call a external library like "Mil" whit IDL, and
>>> how?
>>> Thanks
>>> FM
|
|
|