|A : D||Addr[A] = D||2 : 4 Address: 01234567 Data: 00400000|
|[A0..A1] : D
I](See note below.)
|Addr[A0] to [A1] contain data D||[0..7] : 6 Address: 01234567 Data: 66666666|
|[A0..A1] : D0 D1
I](See note below.)
|Addr[A0] = D0, Addr[A0+1] = D1, Addr[A0+2] = D0, Addr[A0+3] = D1, until A0+n = A1||[0..7] : 5 6 Address: 01234567 Data: 56565656|
|A : D0 D1 D2||Addr[A] = D0, Addr[A+1] = D1, Addr[A+2] = D2||2 : 4 5 6 Address: 01234567 Data: 00456000|
B]Note: The address range forms are limited in SRecord, the range must be less than 255 bytes. SRecord will never write an address range.
B]Note: When reading MIF file, SRecord will round up the number of bits in the WIDTH to be a multiple of 8. Multi[hy]byte values will be laid down in memory as big[hy]endian.
An ASCII text file (with the extension .mif) that specifies the initial content of a memory block (CAM, RAM, or ROM), that is, the initial values for each address. This file is used during project compilation and/or simulation. A MIF contains the initial values for each address in the memory. In a MIF, you are also required to specify the memory depth and width values. In addition, you can specify the radixes used to display and interpret addresses and data values.
In general, binary data will expand in sized by approximately 3.29 times when 8[hy]bit data is represented with this format (16 bit = 2.75, 32 bit = 2.47, 64 bit = 2.34).
Following is a sample MIF:DEPTH = 32; % Memory depth and width are required % % DEPTH is the number of addresses % WIDTH = 14; % WIDTH is the number of bits of data per word % % DEPTH and WIDTH should be entered as decimal numbers % ADDRESS_RADIX = HEX; % Address and value radixes are required % DATA_RADIX = HEX; % Enter BIN, DEC, HEX, OCT, or UNS; unless % % otherwise specified, radixes = HEX % --Specify values for addresses, which can be single address or range CONTENT BEGIN [0..F]: 3FFF; % Range: Every address from 0 to F = 3FFF % 6 : F; % Single address: Address 6 = F % 8 : F E 5; % Range starting from specific address % -- % Addr = F, Addr = E, Addr[A] = 5 % END;
The above information was gleaned from the following sources:
srec_mif version 1.64
Copyright © 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Peter Miller
The srec_mif program comes with ABSOLUTELY NO WARRANTY; for details use the srec_mif -VERSion License command. This is free software and you are welcome to redistribute it under certain conditions; for details use the srec_mif -VERSion License command.
Scott Finneran E[hy]Mail: firstname.lastname@example.org Peter Miller E[hy]Mail: email@example.com
|Reference Manual||*(N) (5)||SRecord|