Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

handwriting recognition system

Status
Not open for further replies.

J.pradeep

Newbie level 1
Newbie level 1
Joined
Aug 2, 2011
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,290
hi every one
Anyone knows how to accessing .dat file can be dealt with. I am trying to access a handwritten character images which is in dat format. It is giving me errors like:
1. load spine.dat;
??? Error using ==> load
Number of columns on line 4 of ASCII file G:\TIES-project\spine.dat
must be the same as previous lines.
2. f = textread('spine.dat');
??? Error using ==> dataread
Trouble reading number from file (row 1, field 1) ==>

Error in ==> textread at 176
[varargout{1:nlhs}]=dataread('file',varargin{:});
3. even using fopen and fscanf is not working.

I can't access the dat file ffrom database, It would be great if someone could help me as my work is hanging on due to this. I can't go ahead before I get this done.
.
Thank You
 

hi pradeep,

you have not mention on what your are trying this.

if it is matllab ...normal fopen will work
here is the matlab example
Copy 5 bytes from the file test1.dat, starting at the tenth byte, and append to the end of test2.dat:

% Create files test1.dat and test2.dat
% Each character uses 8 bits (1 byte)

fid1 = fopen('test1.dat', 'w+');
fwrite(fid1, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ');

fid2 = fopen('test2.dat', 'w+');
fwrite(fid2, 'Second File');

% Seek to the 10th btye ('J'), read 5
fseek(fid1, 9, 'bof');
A = fread(fid1, 5, 'uint8=>char');
fclose(fid1);

% Append to test2.dat
fseek(fid2, 0, 'eof');
fwrite(fid2, A);
fclose(fid2);
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top