Loading files
This file is pinned to the selected release. Download the original to open it in your design tool.
7f9864208This file is pinned to the selected release. Download the original to open it in your design tool.
using Hast.Xilinx.Drivers;
using Microsoft.Extensions.FileProviders;
using System.IO;
using System.Reflection;
namespace Hast.Xilinx;
public static class ResourceHelper
{
public static string GetTimingReport(string tsvName, Assembly assembly = null)
{
var provider = new EmbeddedFileProvider(assembly ?? typeof(AlveoU250Driver).Assembly);
using var stream = provider.GetFileInfo($"TimingReports.{tsvName}.tsv").CreateReadStream();
using var streamReader = new StreamReader(stream);
return streamReader.ReadToEnd();
}
}