Buy(Cart) Contact NSDSP Home

NSZ File Generation

NSZ files are used to customize target devices, for example to program individual serial numbers. The NSZ File generator allows to generate simple NSZ files. If you need more complex NSZ files, you can generate them by yourself using NSZ format specification.

To generate an NSZ file, open NSDS Gang Programmer, select your target device and click on the "New NSZ" button.

NSZ File Generator Screenshot

The NSZ File generation screen describes the memory area which needs to be customized in target devices. The screen is slightly different for different PIC families because of architecture differences. However, the resulting NSZ file is not linked to the specific device and can be used with any devices within the familiy. The only requirement is that the memory location is writable.

The "Program Memory address" specifies the address where the information will be written. This is a physical address. For devices which have separate Data and Program spaces, this address refers to Program Space, but it does not necessarily refer to Program Memory. It may refer to EEPROM, User ID, OTP etc.

The "Size" is specified as the number of instructions. Depending on the PIC family, one instruction may occupy different number of addresses or bytes as follows:

Device FamilyInstruction Size Addresses per Instruction
PIC10/12/1614-bit 1
PIC1816-bit 2
PIC24/30/3324-bit 2
PIC3232-bit 4

The "Quantity" specifies the number of records that are going to be generated. This is how many individual chips can be programmed with the NSZ file before it gets exhausted.

NSZ File Generator uses 64-bit integers (or 19 decimal digits for ASCII/BCD format). For each record, it generates a 64-bit number. The "Content" specifies how these numbers are generated - randomly or in sequence.

The "Format" specifies how the generated numbers are stored inside records. When "ASCII" or "BCD" is selected, the numbers are converted into decimal string. When ""ASCII"" is selected, the numbers are stored as is. There are two varities of the binary format. Both produce the same results. They differ only by the method used by NSDS Gang Programmer or by nsprog to present the number to the user.

The "Endianness" specifies the order of digits. If "Big-Endian" is selected the most significant digits are recorded first - a natural order for ASCII or BCD number presentation. With "Little-Endian", the least significan digits are recorded first, which is typical for binary format.

The "Packing" specifies how the records are packed inside instructions. The packing depends on the PIC family, so the number of choices will be different:

Device Family Bytes Per Instruction
1234
PIC10/12/16 retlw7-bit ASCII N/AN/A
PIC18 retlwpacked N/AN/A
PIC24/30/33 retlwPSV access packedN/A
PIC32 N/AN/A N/Apacked

If the 64-bit integer is not long enough to fill the specified number of instructions, it is padded with zeroes (from the left for big-endian format or from the right for little-endian format). If the number of instructions is less that is necessary to represent the 64-bit number, the most-significant bits are discarded.

When you fill all the options and click on the "Generate" button, you will need to choose where to store the NSZ file and how to name it.

Northern Software Home NSDSP Contact Us Purchase/Vew Cart

© 2007-2021 Northern Software Inc. All Rights Reserved.