converting fid from MATLAB fopen() to Unix fd suitable for Unix read
4 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
MATLAB's fopen() returns an integer fid for which MATLAB freads() and fwrites() can be made. But this fid integer is not a fd as returned from the UNIX open() system command (that is it cannot be used with the UNIX read() system command). Is there any way to get access to the underly UNIX fd associated with the MATLAB fid so that I can use it with the UNIX read() system routine?
This is a general question. The specific use I have in mind is to be able to read part of a binary file that contains long double (128 bit floats) into MATLAB. I figured I'd just have a short Mex file do the system read() and conversion into a double Mex MATLAB array. The reason I don't want to use the UNIX open() system command to open the file is I am already using MATLAB fread() to read in many other items from the binary file and don't want to rewrite all of that in C.
0 Commenti
Risposte (0)
Vedere anche
Categorie
Scopri di più su Low-Level File I/O in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!