From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,2aaba1527862ef22 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!wns14feed!worldnet.att.net!attbi_s72.POSTED!53ab2750!not-for-mail From: "Jeffrey R. Carter" User-Agent: Thunderbird 1.5.0.9 (Windows/20061207) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Reading Float Data from a binary file into ada References: <1170172307.292500.256090@m58g2000cwm.googlegroups.com> <1170180250.735903.10580@a34g2000cwb.googlegroups.com> <1170187015.001438.296780@m58g2000cwm.googlegroups.com> In-Reply-To: <1170187015.001438.296780@m58g2000cwm.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 12.201.97.213 X-Complaints-To: abuse@mchsi.com X-Trace: attbi_s72 1170268245 12.201.97.213 (Wed, 31 Jan 2007 18:30:45 GMT) NNTP-Posting-Date: Wed, 31 Jan 2007 18:30:45 GMT Organization: AT&T ASP.att.net Date: Wed, 31 Jan 2007 18:30:45 GMT Xref: g2news2.google.com comp.lang.ada:8783 Date: 2007-01-31T18:30:45+00:00 List-Id: frikk wrote: >> > We are using simulink and calling ada through s-functions. If we use > C, we'd have to get the data back to the matlab workspace, then pass > it into an ada module. It is prefered to keep all of the data inside > the ada modules without coming back to the workspace. OK. > And yes - it appears that the data dumped is not actually a float but > fixed point. This is how VB apparently handles 'Float' data types. > > Actually - now that I look at it Visual Basic is using a 'Single' > type, not 'Float'. This may make more sense now. I'm not sure what Single is. Are you sure C is using float? You should probably use an Ada fixed-point type with the same representation. -- Jeff Carter "Alms for an ex-leper!" Monty Python's Life of Brian 75