dlhdl.Bitstream Class
Namespace: dlhdl
Description
Use dlhdl.Bitstream
objects to register and load your custom bitstream
information.
Creation
creates a bitstream object and sets the hB
= dlhdl.Bistream(Path
)Path
property.
creates a bitstream object and sets the hB
= dlhdl.Bistream(Name
)Name
and
Path
properties.
sets optional properties using one or more name-value arguments.hB
= dlhdl.Bistream(Path
,Name=Value
)
sets optional properties using one or more name-value arguments.hB
= dlhdl.Bistream(Name
,Name=Value
)
Properties
Path
— Path to the folder containing the bitstream files or MAT file
"" (default) | string | character vector
Path to the folder containing the bitstream files or MAT file, specified as a string or character vector.
Example: Path="\user\Bitstream\dlprocessor.bit"
Name
— Name of the bitstream
" " (default) | "zcu102_single" | "zcu102_int8" | "zcu102_lstm_single" | "arria10soc_single" | "arria10soc_int8" | "arria10soc_lstm_single" | "zc706_single" | "zc706_int8" | string | character vector
Name of the bitstream, specified as a string or character vector.
Example: Name="custom_zcu_single"
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN
, where Name
is
the argument name and Value
is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Before R2021a, use commas to separate each name and value, and enclose
Name
in quotes.
MemoryBaseAddress
— Base address of memory that the design uses
" " (default) | string | character vector
Base address of memory that the design uses, specified as a string or character vector.
Example: MemoryBaseAddress="C0000000"
MemoryBaseAddressRange
— Memory address range to use
" " (default) | string | character vector
Memory address range to use, specified as a string or character vector.
Example: MemoryBaseAddressRange="20000"
ProcessorBaseAddress
— Base address of the deep learning processor
" " (default) | string | character vector
Base address of the deep learning processor, specified as a string or character vector.
Example: ProcessorBaseAddress="A0000000"
ProcessorAddressRange
— Address range for deep learning processor to use
'0x10000 ' (default) | character vector
This property is read-only.
Address range for deep learning processor to use, returned as a character vector.
Methods
Public Methods
loadInfoFromPlugin | Load and update bitstream information using board and reference design plugin files |
saveBitstreamInfoFile | Update bitstream MAT file with information from bitstream object |
Examples
Generate and Register Custom Bitstream
Create a generic deep learning processor configuration object. To generate the
bistream faster, turn off the conv
and fc
modules.
Save the object in the variable hPC
.
hPC = dlhdl.ProcessorConfig; hPC.TargetPlatform = 'Generic Deep Learning Processor'; hPC.SynthesisTool = ''; hPC.setModuleProperty("conv",ModuleGeneration="off"); hPC.setModuleProperty("fc",ModuleGeneration="off");
Generate a deep learning processor IP core. Name the processor
myProcessor
and save it in the folder
myProject
.
dlhdl.buildProcessor(hPC,ProjectFolder='myProject', ... ProcessorName="myProcessor");
Create a bitstream object using the information from the deep learning processor MAT
file myProcessor.mat
.
path = fullfile("myProject","myProcessor.mat"); hB = dlhdl.Bitstream(path)
hB = Bitstream with properties: Name: '' Path: 'myProcessor.mat' MemoryBaseAddress: '0' MemoryAddressRange: '0' ProcessorBaseAddress: '0' ProcessorAddressRange: '0x10000'
Update the Name
, MemoryBaseAddress
,
MemoryAddressRange
, and ProcessorBaseAddress
properties of the bistream.
hB = dlhdl.Bitstream(path,Name="myBitstream",MemoryBaseAddress="C0000000",... MemoryAddressRange="20000",ProcessorBaseAddress="A0000000"); hB
hB = Bitstream with properties: Name: 'myBitstream' Path: 'myProcessor.mat' MemoryBaseAddress: 'C0000000' MemoryAddressRange: '20000' ProcessorBaseAddress: 'A0000000' ProcessorAddressRange: '0x10000'
Version History
Introduced in R2024b
See Also
dlhdl.ProcessorConfig
| dlhdl.buildProcessor
| dlhdl.Workflow
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)