OpenCores
URL https://opencores.org/ocsvn/yac/yac/trunk

Subversion Repositories yac

[/] [yac/] [trunk/] [c_octave/] [cordic_iterative_code.m] - Diff between revs 4 and 13

Show entire file | Details | Blame | View Log

Rev 4 Rev 13
Line 66... Line 66...
fid = fopen( outfile, 'w' );
fid = fopen( outfile, 'w' );
 
 
% TODO: calculate these values
% TODO: calculate these values
K0 = 0.607252935009;
K0 = 0.607252935009;
K1 = 0.207497067763;
K1 = 0.207497067763;
<<<<<<< HEAD
 
<<<<<<< HEAD
 
%prod( sqrt( 1-2.^(-2 .* [ 1 : 100000 ] ) ) )
%prod( sqrt( 1-2.^(-2 .* [ 1 : 100000 ] ) ) )
 
 
=======
 
>>>>>>> initial commit
 
=======
 
%prod( sqrt( 1-2.^(-2 .* [ 1 : 100000 ] ) ) )
 
 
 
>>>>>>> Updated C and RTL model as well as the documentation
 
 
 
signs = get_rm_gain_shifts( K0, 30 );
signs = get_rm_gain_shifts( K0, 30 );
print_rm_gain_code( fid, signs, K0, 1, 1, 0 );
print_rm_gain_code( fid, signs, K0, 1, 1, 0 );
 
 
signs = get_rm_gain_shifts( K1, 30 );
signs = get_rm_gain_shifts( K1, 30 );
Line 90... Line 82...
 
 
signs = get_rm_gain_shifts( K1, 30 );
signs = get_rm_gain_shifts( K1, 30 );
print_rm_gain_code( fid, signs, K1, 1, 0, 1 );
print_rm_gain_code( fid, signs, K1, 1, 0, 1 );
 
 
MAX_A_WIDTH = 32;
MAX_A_WIDTH = 32;
<<<<<<< HEAD
 
<<<<<<< HEAD
 
print_angular_lut( fid, MAX_A_WIDTH );
print_angular_lut( fid, MAX_A_WIDTH );
=======
 
print_angular_lut( fid, MAX_A_WIDTH )
 
>>>>>>> initial commit
 
=======
 
print_angular_lut( fid, MAX_A_WIDTH );
 
>>>>>>> Updated C and RTL model as well as the documentation
 
 
 
 
 
fclose( fid );
fclose( fid );
 
 
end
end
Line 209... Line 193...
                else
                else
                    fprintf( fid,  '   case %d: x = ', i_shift );
                    fprintf( fid,  '   case %d: x = ', i_shift );
                end
                end
 
 
                for y = 1 : length( tmp2 )
                for y = 1 : length( tmp2 )
<<<<<<< HEAD
 
<<<<<<< HEAD
 
                    fprintf( fid,  '%c ( x >> %d ) ', tmp2{ y }, index( y ) );
 
=======
 
                    fprintf( fid,  '%c ( x >> %d ) ', tmp2{ y }, index( y ) )
 
>>>>>>> initial commit
 
=======
 
                    fprintf( fid,  '%c ( x >> %d ) ', tmp2{ y }, index( y ) );
                    fprintf( fid,  '%c ( x >> %d ) ', tmp2{ y }, index( y ) );
>>>>>>> Updated C and RTL model as well as the documentation
 
                end
                end
                fprintf( fid,  '; break; /* error: %.10f */ \n', err );
                fprintf( fid,  '; break; /* error: %.10f */ \n', err );
            else
            else
 
 
                % VHDL CODE
                % VHDL CODE

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.