FPGA API Low-level API

Old Content - visit altium.com/documentation

Parent page: Technical Reference - FPGA API

FPGA API: LowLevel API Reference

Contents of this reference:

FPGA Constants
FPGA types
FPGA Functions
FPGA Classes

 

FPGA Constants

FPGAVendorKindStrings

FPGAVendorKindStrings : Array [TFPGAVendorKind] Of TDynamicString =
('Altera',
 'Xilinx',
 'Actel',
 'Lattice');

FPGAVendorPinFilterStrings

FPGAVendorPinFilterStrings : Array[TFPGAVendorKind] Of TDynamicString =
('Altera Pin, Report files (*.pin, *.fit.rpt)|*.PIN;*.FIT.RPT',
 'Xilinx UCF, PAD, CSV files (*.ucf; *.pad; *.csv)|*.UCF;*.PAD;*.CSV',
 'Actel Report files (*.rpt)|*.RPT',
 'Lattice PAD Files (*.pad)|*.PAD'
);

FPGAAttributeNameStrings

FPGAAttributeNameStrings : Array[TFPGAAttributes] Of TDynamicString =
('ARRAY_TO_NUMERIC',
 'CLOCK_BUFFER',
 'CRITICAL',
 'ENUM_ENCODING',
 'FPGA_GSR',
 'INHIBIT_BUF',
 'MACROCELL',
 'NUMERIC_TO_ARRAY',
 'PART_NAME',
 'PINNUM',
 'PROPERTY',
 'UNGROUP',
 'XILINX_BUFG',
 'XILINX_GSR'
);

FPGA types

TFPGAVendorKind

TFPGAVendorKind = (eFPGAVendor_Altera,
                   eFPGAVendor_Xilinx,
                   eFPGAVendor_Actel,
                   eFPGAVendor_Lattice);

TFPGAAttributes

TFPGAAttributes = (eFPGA_ArrayToNumeric   ,
                   eFPGA_ClockBuffer      ,
                   eFPGA_Critical         ,
                   eFPGA_EnumerateEncoding,
                   eFPGA_GSR              ,
                   eFPGA_InhibitBuffer    ,
                   eFPGA_Macrocell        ,
                   eFPGA_NUmericToArray   ,
                   eFPGA_PartName         ,
                   eFPGA_PinNumber        ,
                   eFPGA_Property         ,
                   eFPGA_Ungroup          ,
                   eFPGA_XilinxBUFG       ,
                   eFPGA_XilinxGSR);

FPGA Functions

CreatePinMapForVendorKind

Function CreatePinMapForVendorKind (AVendorKind : TFPGAVendorKind) : TFPGAVendorPinMap;

GetVendorKindFromFileName

Function GetVendorKindFromFileName (AFileName : TDynamicString)  : TFPGAVendorKind;

GetFPGAVendorKind

Function GetFPGAVendorKind(AVendorKind : TDynamicString)  : TFPGAVendorKind;

GetFPGAPinMapFileFromUser

Function GetFPGAPinMapFileFromUser(Var AFileName   : TDynamicString;
                                   Var AVendorKind : TFPGAVendorKind;
                                       LimitFiltersToVendor : Boolean = False) : Boolean;

UpperCasePos

Function UpperCasePos (ASubStr, AString : TDynamicString) : Integer;

GetFPGAPinMap

Function GetFPGAPinMap(AConfirmWarningsFlag     : Boolean;
                       AVendorName, ADeviceName : TDynamicString;
                       APinCount                : Integer) : TFPGAVendorPinMap;

GetConstraintMapper

Function GetConstraintMapper : TConstraintMapper;

FPGA Classes

The FPGA Classes include:

  • TFPGAVendorPin class
  • TFPGAVendorMap class
  • TFPGAAlteraPinMap class
  • TFPGAXilinxPinMap class
  • TFPGAActelPinMap class
  • TFPGALatticePinMap class
  • TConstraintMapper class

TFPGAVendorPin class

Overview

TFGPAVEndorPin Fields
Number
NetName
Mode
PinType
Voltage
SlewRate
DriveStrength
Bank
IsUserNet
TFPGAVendorPin methods
GetDescription
HasPinElectrical
GetPinElectrical
GetPinElectricalString
Destroy
Create
TFPGAVendorPin properties

See also

Fields

Number        : TDynamicString;
NetName       : TDynamicString;
Mode          : TDynamicString;
PinType       : TDynamicString;
Voltage       : TDynamicString;
SlewRate      : TDynamicString;
DriveStrength : TDynamicString;
Bank          : TDynamicString;
IsUserNet     : Boolean;

Methods

Constructor Create(ANumber, ANetName : TDynamicString);
Function    GetDescription         : TDynamicString;
Function    HasPinElectrical       : Boolean;
Function    GetPinElectrical       : TPinElectrical;
Function    GetPinElectricalString : TDynamicString;

Properties

N/A

TFPGAVendorMap class

Overview

TFGPAVendorMap Fields
FAllins
FStatus
FDeviceName
Pins
Chip
Designator
TFPGAVendorMap methods
ConvertName
SkipLine
Create
Destroy
SortBy_Number
SortBy_Name
SetDeviceName
Load
AddPin
GetLongestNetName
TFPGAVendorMap properties

See also

Fields

Private fields
FAllPins    : Boolean;
FStatus     : Boolean;Methods
FDeviceName : TDynamicString;
Public fields
Pins       : TList;
Chip       : TDynamicString;
Designator : TDynamicString;

Methods

Function    ConvertName(AName : TDynamicString) : TDynamicString; Virtual;
Function    SkipLine   (ALine : TDynamicString) : Boolean;        Virtual;
Constructor Create;
Destructor  Destroy; Override;
Procedure   SortBy_Number;
Procedure   SortBy_Name;
Procedure   SetDeviceName(ADeviceName : TDynamicString);
Function    Load(AFileName : TDynamicString) : Boolean;    Virtual;
Function    AddPin(ANumber, ANetName : TDynamicString): TFPGAVendorPin;
Function    GetLongestNetName : TDynamicString;
Function    ContainsAllPins   : Boolean;
Function    GetPinByNumber       (ANumber  : TDynamicString) : TFPGAVendorPin;
Function    GetPinByNetname      (ANetName : TDynamicString) : TFPGAVendorPin;
Function    GetPinNumberForNet   (ANetName : TDynamicString) : TDynamicString; Virtual;
Function    GetPinNumberForBusNet(ANetName : TDynamicString; Range1, Range2 : Integer) : TDynamicString; Virtual;

TFPGAAlteraPinMap class

Overview

TFGPAAlteraPinMap Fields
 
TFPGAAlteraPinMap methods
ConvertName
ConvertMode 
ConvertDrive 
SkipLine         
ParsePinToken
ParseInputToken
ParseOutputToken
ParseBiDirToken
ParseChipStatement
TFPGAAlteraPinMap properties

See also

Fields

N/A

Methods

Function    ConvertName       (AName : TDynamicString) : TDynamicString; Override;
Function    ConvertMode       (AMode     : TDynamicString) : TDynamicString; Virtual;
Function    ConvertDrive      (ADrive    : TDynamicString) : TDynamicString; Virtual;
Function    SkipLine          (ALine : TDynamicString) : Boolean;        Override;
Procedure   ParsePinTokens    (Tokens : TStringList);                    Virtual;
Procedure   ParseInputTokens  (Tokens : TStringList);
Procedure   ParseOutputTokens (Tokens : TStringList);
Procedure   ParseBiDirTokens  (Tokens : TStringList);
Procedure   ParseChipStatement(ALine : TDynamicString);                  Virtual;
Function   Load(AFileName : TDynamicString) : Boolean;    Override;

TFPGAXilinxPinMap class

Overview

TFGPAVendorMap Fields
FDelimiter
TFPGAVendorMap methods
ConvertName     
SkipLine        
ConvertBank     
ConvertMode     
ConvertSlew     
ConvertDrive    
ParseUCFPinTokens
ParsePADPinTokens
LoadUCFFile     
LoadPADFile     
Load
GetPinNumberForNet
StripPinNumberPrefix
TFPGAVendorMap properties

See also

Fields

FDelimiter : Char;

Methods

Function  ConvertName         (AName     : TDynamicString) : TDynamicString; Override;
Function  SkipLine            (ALine     : TDynamicString) : Boolean;        Override;
Function  ConvertBank         (ABank     : TDynamicString) : TDynamicString; Virtual;
Function  ConvertMode         (AMode     : TDynamicString) : TDynamicString; Virtual;
Function  ConvertSlew         (ASlew     : TDynamicString) : TDynamicString; Virtual;
Function  ConvertDrive        (ADrive    : TDynamicString) : TDynamicString; Virtual;
Procedure ParseUCFPinTokens   (Tokens    : TStringList);                     Virtual;
Procedure ParsePADPinTokens   (Tokens    : TStringList);                     Virtual;
Procedure LoadUCFFile         (AFileName : TDynamicString);                  Virtual;
Procedure LoadPADFile         (AFileName : TDynamicString);                  Virtual;
Function  Load(AFileName : TDynamicString) : Boolean;                        Override;
Function  GetPinNumberForNet   (ANetName : TDynamicString) : TDynamicString; Override;
Function  StripPinNumberPrefix(APrefix   : TDynamicString) : Boolean;

TFPGAActelPinMap class

Overview
This class represents the Pin Mapping information of an Actel device. The FPGAActelPinmap class is inherited from the generic TFPGAVendorPinMap class.

TFGPAActelPinMap Fields
 
TFPGAActelPinMap methods TFPGAActelPinMap properties

See also
TFPGAVendorPinMap class.

Fields

N/A

Methods

Function  ConvertName   (AName : TDynamicString) : TDynamicString; Override;
Procedure ParsePinTokens(Tokens : TStringList);                    Virtual;
Function Load(AFileName : TDynamicString) : Boolean;     Override;

TFPGALatticePinMap class

Overview

TFGPALatticePinMap Fields
 
TFPGALatticePinMap methods
ConvertName
ExtractPinNumAndBank 
ExtractStandardAndType
ExtractDriveAndSlew
ParsePADPinTokens
ExtractDriveAndSlew
ParsePADPinTokens
Load
TFPGALatticePinMap properties

See also

Methods

Function  ConvertName (AName : TDynamicString) : TDynamicString; Override;
Function  ExtractPinNumAndBank  (AString : TDynamicString; Var Pin, Bank:         TDynamicString) : Boolean;
Function  ExtractStandardAndType(AString : TDynamicString; Var Standard, PinType: TDynamicString) : Boolean;
Function  ExtractDriveAndSlew   (AString : TDynamicString; Var Drive, Slew:       TDynamicString) : Boolean;
Procedure ParsePADPinTokens     (Tokens : TStringList);
Function  Load(AFileName : TDynamicString) : Boolean;     Override;

TConstraintMapper class

Overview

TConstraintMapper methods
GetVendorConstraintValue
GetGenericConstraintValueForDevice
GetGenericConstraintValueForVendor
Destroy
Create
TConstraintMapper properties

See also

Fields
Methods

Function GetVendorConstraintValue(
             ADeviceName : TDynamicString;
             AConstraintName  : TDynamicString;
             AConstraintValue : TDynamicString) : TDynamicString;
 
Function GetGenericConstraintValueForDevice(
             ADeviceName : TDynamicString;
             AConstraintName  : TDynamicString;
             AConstraintValue : TDynamicString) : TDynamicString;
 
Function GetGenericConstraintValueForVendor(
             AVendorName : TDynamicString;
             AConstraintName  : TDynamicString;
             AConstraintValue : TDynamicString) : TDynamicString;
 
Destructor  Destroy; Override;
Constructor Create(AFileName : TDynamicString);

You are reporting an issue with the following selected text and/or image within the active document:
ALTIUM DESIGNER FREE TRIAL
Altium Designer Free Trial
Let’s get started. First off, are you or your organization already using Altium Designer?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

In that case, why do you need an evaluation license?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Got it. You actually don’t need an evaluation license for that.

Click the button below to download the latest Altium Designer installer.

Download Altium Designer Installer

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Please fill out the form below to get a quote for a new seat of Altium Designer.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

If you are on Altium Subscription, you don’t need an evaluation license.

If you are not an active Altium Subscription member, please fill out the form below to get your free trial.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Why are you looking to evaluate Altium Designer?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

You came to the right place! Please fill out the form below to get your free trial started.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Sounds exciting! Did you know we offer special discounted student licenses? For more information, click here.

In the meantime, feel free to request a free trial by filling out the form below.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Got it. You can download a free Altium Designer Viewer license which is valid for a 6 months.

Please fill out the form below to request one.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

That’s great! Making things is awesome. We have the perfect program for you.

Upverter is a free community-driven platform designed specifically to meet the needs of makers like you.

Click here to give it a try!

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Got it. You can download a free Altium Designer Viewer license which is valid for a 6 months.

Please fill out the form below to request one.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.