|
| 1 | +--- |
| 2 | +uid: a_develop_utility_checkdwmapi |
| 3 | +--- |
| 4 | + |
| 5 | +# CheckDwmApi |
| 6 | + |
| 7 | +**Melanchall.CheckDwmApi** tool used to check basic functions of DryWetMIDI library. You may be kindly asked to run it to help investigate issues with the library. |
| 8 | + |
| 9 | +If you have questions regarding the utility, please feel free to create an [issue](https://github.com/melanchall/drywetmidi/issues/new) or [discussion](https://github.com/melanchall/drywetmidi/discussions/new/choose) on GitHub, or send an email. |
| 10 | + |
| 11 | +## Downloading the utility |
| 12 | + |
| 13 | +First of all, you need to download the utility. You can find the latest version of it in the _Artifacts_ section of the [latest build](https://dev.azure.com/Melanchall/DryWetMIDI/_build/latest?definitionId=85&branchName=develop): |
| 14 | + |
| 15 | + |
| 16 | + |
| 17 | +Clicking on the highlighted button you'll see the list of published utilities. You need to find `CheckDwmApi-<OS>-<CPU-Arch>` plates: |
| 18 | + |
| 19 | + |
| 20 | + |
| 21 | +`<OS>` is the operating system you want to run the utility on (_Windows_, _macOS_, _Linux_) and `<CPU-Arch>` is the CPU architecture (_x64_, _ARM64_, etc.). Click on the plate that fits your OS and CPU architecture to download a ZIP archive with the utility: |
| 22 | + |
| 23 | + |
| 24 | + |
| 25 | +If you unsure what your CPU architecture is, you can execute a command in your command line shell: |
| 26 | + |
| 27 | +* **Windows**: |
| 28 | + in cmd: |
| 29 | + ```text |
| 30 | + echo %PROCESSOR_ARCHITECTURE% |
| 31 | + ``` |
| 32 | + in PowerShell: |
| 33 | + ```text |
| 34 | + $env:PROCESSOR_ARCHITECTURE |
| 35 | + ``` |
| 36 | +* **macOS / Linux**: |
| 37 | + ```text |
| 38 | + uname -m |
| 39 | + ``` |
| 40 | + |
| 41 | +If you see, for example, `AMD64` or `x86_64`, your CPU architecture is `x64`. If you see `ARM64` or `aarch64`, your CPU architecture is `arm64`. In general, Intel and AMD processors use `x64` architecture, while Apple Silicon (M1, M2 and so on) processors use `arm64` architecture. |
| 42 | + |
| 43 | +Of course, you can see [the source code](https://github.com/melanchall/drywetmidi/tree/develop/Utilities/CheckDwmApi) of the utility. Also you can see exact commit from which it was built: |
| 44 | + |
| 45 | + |
| 46 | + |
| 47 | +## Running the utility |
| 48 | + |
| 49 | +> [!WARNING] |
| 50 | +> If you're on Windows, you need to have a virtual MIDI device installed to run the utility. For example, you can use [loopMIDI](https://www.tobias-erichsen.de/software/loopmidi.html): |
| 51 | +> |
| 52 | +>  |
| 53 | +> |
| 54 | +>  |
| 55 | +> |
| 56 | +> The tool will ask you for the name of a virtual MIDI device to use during the testing process, so you can specify any name and use any application to create a MIDI device (loopMIDI, loopBe1 and so on). |
| 57 | +
|
| 58 | +Now you're ready to run the tool. First of all, extract the downloaded archive to any folder you want. After that, navigate to the folder and run the program (just double-click it). |
| 59 | + |
| 60 | +The utility will guide you through the testing process. You just need to follow the instructions shown in the console window. |
| 61 | + |
| 62 | +At the end of the testing process, the utility will generate a report file named **CheckDwmApiReport.txt** in the same folder where the utility is located. The file will be opened automatically after the testing process is finished (or you can open it manually). You can send the content of this file to the DryWetMIDI developer to help investigate issues with the library. |
| 63 | + |
| 64 | +Report will contain exactly what you will see in the console window during the testing process with elapsed time prefixes on each line. For example: |
| 65 | + |
| 66 | +```text |
| 67 | +[00:00.008] ================================================================================ |
| 68 | +[00:00.008] [1] Write system information |
| 69 | +[00:00.010] -------------------------------------------------------------------------------- |
| 70 | +[00:00.010] Writes system information to the report. |
| 71 | +[00:00.010] ================================================================================ |
| 72 | +[00:00.011] Retrieving system information... |
| 73 | +[00:00.011] - info providers obtained for the current OS |
| 74 | +[00:00.013] Retrieving CpuArchitecture... |
| 75 | +[00:00.018] Executing command: cmd /C echo %PROCESSOR_ARCHITECTURE% |
| 76 | +[00:00.036] - waiting process exited for 00:00:10... |
| 77 | +[00:00.051] - executed |
| 78 | +[00:00.052] - output received |
| 79 | +[00:00.052] - CPU arch: AMD64 |
| 80 | +``` |
0 commit comments