This extension allows you to invoke GHDL functions, as well as GTKWave to perform simlation of VHDL files. Beyond, it lists the errors that were reported by GHDL in the GHDL Output channel. Using
You will need to have GHDL and GTKWave installed on your system. Furthermore both must be set in your environment variables.
At present it is possible to invoke the following GHDL functions by either rightclicking at the editor or at the explorer on the specific file and then selecting the desired funtion.
Editor Option | GHDL Function |
---|---|
ghdl analyze | ghdl -a [File] |
ghdl elaborate | ghdl -e [Unit] |
ghdl run | ghdl -r [Unit] [export file] |
ghdl make | ghdl -m [unit] (+ run if OK) |
ghdl clear | ghdl -c |
ghdl remove | ghdl --remove |
In addition to that the GHDL analyze function offers you error highlighting in the editor.
To open your simulation files with GTKWave, simply rightclick on them (.ghw or .vcd file required) in the explorer and then select gtkwave
VHDL-Wave recommends VHDL-LS for syntax, and syntax error highlighting. VHDL-Wave automatically generates the configuration file that VHDL-LS needs to
find all references. This feature can be disabled in setting (see vhdl-wave > General: Enable Ls Toml
).
It is still possible to complement the generated vhdl-ls.toml
file with additional data. This must be done below the limit indicated in the file.
It is also possible to invoke the GHDL functions via the following keybindings.
Editor Option | Windows | Linux | MacOS |
---|---|---|---|
ghdl analyze | ctrl + alt + a |
shift + alt + a |
shift + cmd + a |
ghdl elaborate | ctrl + alt + l |
shift + alt + e |
shift + cmd + e |
ghdl run | ctrl + alt + r |
shift + alt + r |
shift + cmd + r |
ghdl make | ctrl + alt + m |
shift + alt + m |
shift + cmd + m |
ghdl clear | ctrl + alt + c |
shift + alt + c |
shift + cmd + c |
ghdl remove | ctrl + alt + d |
shift + alt + d |
shift + cmd + d |
VHDL-Wave recommends VHDL-LS for syntax highlighting. VHDL-Wave automatically generates the configuration file that VHDL-LS needs to
find all references. This feature can be disabled in setting (see vhdl-wave > General: Enable Ls Toml
).
It is still possible to complement the generated vhdl-ls.toml
file with additional data. This must be done below the limit indicated in the file.
When a library is added to the configuration (setting Library Directories
) this directory is searched for files following library naming rule:
<library-name>_obj<vhdl-version>.cf
These library files are then parsed to find the corresponding source files which are then added to vhdl-ls.toml
file.
vhdl-wave
file (new in V1.3.0)The files .vscode/vhdl-wave.json in the workspace folder allows overriding the following settings: Work Library Name
and Work Library Path
.
The aim is to allow switching easily between library development and main application development.
The standard development takes place in the work
library which is the default VHDL-Wave setting. But when you develop a library you must name the working library with the target library name. And you may want to place it in a particular place where you locate your libraries.
By defining specific library name and location in vhdl-wave.json
file of the library development folder you will allow to use the right parameters as soon you enter the library development folder with vscode.
The typical content of vhdl-wave.json
file is :
{
"WorkLibraryPath": "/mylibrary/rootpath/" ,
"WorkLibraryName": "myCustomLibrary"
}
In case you encounter any problems or have suggestions regarding the extension, feel free to open an issue at first.
The extension is licensed under the MIT license.