Card structure of a LEGIC card
Overview
- A LEGIC card memory consists of several segments, e.g. for access control, cafeteria payment, etc.
- To access data on the card you'll basically need to know:
- In which segment is the relevant data stored?
- What's the location of the data within the segment?
- In what format is the data encoded?
Mapping to configuration values
Each segment consists of 2 data areas:
- Administration data area, which contains the stamp used to identify the segment
- User-specific application data area
BALTECH ConfigEditor uses an abstraction for both LEGIC advant and prime cards, which maps the stamp into the addressable data memory range. The first stamp byte corresponds to address 0, the first data byte follows immediately after the stamp.
Below, the card structure is illustrated in more detail. Move your mouse over a question mark to get details about each element and how it corresponds to the values in the configuration components Autoread LEGIC Number in File and LEGIC VHL File in BALTECH ConfigEditor.
A LEGIC card contains multiple segments for different applications (e.g., access control, cafeteria payment). Each segment is organized in bytes, starting with a segment stamp — a 1–12 byte identifier for the application.
Specify the stamp of the segment that contains the programmed card number (PCN).
Each segment has a unique number starting at 1, which you can use instead of the stamp to identify the segment containing the programmed card number (PCN). To do so, check the box Search by Segment Number Instead of Stamp.
Segment content is organized in bytes. To indicate the position of the programmed card number (PCN) within the segment, specify the following:
- PCN start position, i.e. the number of the byte in which the PCN starts. Byte numbering is unique within the segment and starts at 0, which corresponds to the first byte of the stamp.
- PCN length, i.e. how many bytes the PCN consists of.
Data format in which the programmed card number (PCN) is encoded on the card. It tells the reader how to interprete the data on the card, so the correct number is transmitted to your host system.
Download request form
Send the following form to your card issuer to request the card structure details needed for reading a programmed card number (PCN) from your LEGIC cards.
A LEGIC card contains multiple segments for different applications (e.g., access control, cafeteria payment). Each segment is organized in bytes, starting with a segment stamp — a 1–12 byte identifier for the application.
Specify the stamp of the segment that contains the relevant data.
Each segment has a unique number starting at 1, which you can use instead of the stamp to identify the segment containing the relevant data. To do so, check the box Search by Segment Number Instead of Stamp.
Segment content is organized in bytes. To indicate the position of the relevant data within the segment, specify the following:
- PCN start position, i.e. the number of the byte in which the PCN starts. Byte numbering is unique within the segment and starts at 0, which corresponds to the first byte of the stamp.
- PCN length, i.e. how many bytes the PCN consists of.
Analyze card structure yourself
If it's not feasible for you to request the card structure details from your card issuer, you can analyze the card structure yourself using BALTECH ID-engine Explorer.