-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document how to debug C# modules #15
Comments
I'm starting to understand how to integrate this with Omnisharp. I now have this: Note the gray up top, indicating I'm not using particular modules. Also, note that mouseover gives information on arguments. And if I control-click on a symbol, it brings me to a useful screen describing it: In order to get this, create a Click to show `peripherals.csproj`<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<PlatformTarget>AMD64</PlatformTarget>
<RenodePath>..\..\..\..\Software\Renode\bin</RenodePath>
</PropertyGroup>
<ItemGroup>
<Reference Include="AdvancedLoggerViewerPlugin">
<HintPath>$(RenodePath)/AdvancedLoggerViewerPlugin.dll</HintPath>
</Reference>
<Reference Include="AntShell">
<HintPath>$(RenodePath)/AntShell.dll</HintPath>
</Reference>
<Reference Include="AsyncIO">
<HintPath>$(RenodePath)/AsyncIO.dll</HintPath>
</Reference>
<Reference Include="CookComputing.XmlRpcV2">
<HintPath>$(RenodePath)/CookComputing.XmlRpcV2.dll</HintPath>
</Reference>
<Reference Include="cores-arm">
<HintPath>$(RenodePath)/cores-arm.dll</HintPath>
</Reference>
<Reference Include="cores-arm-m">
<HintPath>$(RenodePath)/cores-arm-m.dll</HintPath>
</Reference>
<Reference Include="cores-i386">
<HintPath>$(RenodePath)/cores-i386.dll</HintPath>
</Reference>
<Reference Include="cores-ppc">
<HintPath>$(RenodePath)/cores-ppc.dll</HintPath>
</Reference>
<Reference Include="cores-ppc64">
<HintPath>$(RenodePath)/cores-ppc64.dll</HintPath>
</Reference>
<Reference Include="cores-riscv">
<HintPath>$(RenodePath)/cores-riscv.dll</HintPath>
</Reference>
<Reference Include="cores-riscv64">
<HintPath>$(RenodePath)/cores-riscv64.dll</HintPath>
</Reference>
<Reference Include="cores-sparc">
<HintPath>$(RenodePath)/cores-sparc.dll</HintPath>
</Reference>
<Reference Include="CxxDemangler">
<HintPath>$(RenodePath)/CxxDemangler.dll</HintPath>
</Reference>
<Reference Include="Dynamitey">
<HintPath>$(RenodePath)/Dynamitey.dll</HintPath>
</Reference>
<Reference Include="ELFSharp">
<HintPath>$(RenodePath)/ELFSharp.dll</HintPath>
</Reference>
<Reference Include="Emulator">
<HintPath>$(RenodePath)/Emulator.dll</HintPath>
</Reference>
<Reference Include="Extensions">
<HintPath>$(RenodePath)/Extensions.dll</HintPath>
</Reference>
<Reference Include="FdtSharp">
<HintPath>$(RenodePath)/FdtSharp.dll</HintPath>
</Reference>
<Reference Include="IronPython">
<HintPath>$(RenodePath)/IronPython.dll</HintPath>
</Reference>
<Reference Include="IronPython.Modules">
<HintPath>$(RenodePath)/IronPython.Modules.dll</HintPath>
</Reference>
<Reference Include="libtftp">
<HintPath>$(RenodePath)/libtftp.dll</HintPath>
</Reference>
<Reference Include="LLVMDisassembler">
<HintPath>$(RenodePath)/LLVMDisassembler.dll</HintPath>
</Reference>
<Reference Include="Lucene.Net">
<HintPath>$(RenodePath)/Lucene.Net.dll</HintPath>
</Reference>
<Reference Include="LZ4">
<HintPath>$(RenodePath)/LZ4.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Dynamic">
<HintPath>$(RenodePath)/Microsoft.Dynamic.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Scripting">
<HintPath>$(RenodePath)/Microsoft.Scripting.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Scripting.Metadata">
<HintPath>$(RenodePath)/Microsoft.Scripting.Metadata.dll</HintPath>
</Reference>
<Reference Include="Migrant">
<HintPath>$(RenodePath)/Migrant.dll</HintPath>
</Reference>
<Reference Include="Mono.Cecil">
<HintPath>$(RenodePath)/Mono.Cecil.dll</HintPath>
</Reference>
<Reference Include="NetMQ">
<HintPath>$(RenodePath)/NetMQ.dll</HintPath>
</Reference>
<Reference Include="Nini">
<HintPath>$(RenodePath)/Nini.dll</HintPath>
</Reference>
<Reference Include="OptionsParser">
<HintPath>$(RenodePath)/OptionsParser.dll</HintPath>
</Reference>
<Reference Include="PacketDotNet">
<HintPath>$(RenodePath)/PacketDotNet.dll</HintPath>
</Reference>
<Reference Include="Renode">
<HintPath>$(RenodePath)/Renode.exe</HintPath>
</Reference>
<Reference Include="Renode-peripherals">
<HintPath>$(RenodePath)/Renode-peripherals.dll</HintPath>
</Reference>
<Reference Include="SampleCommandPlugin">
<HintPath>$(RenodePath)/SampleCommandPlugin.dll</HintPath>
</Reference>
<Reference Include="Sprache">
<HintPath>$(RenodePath)/Sprache.dll</HintPath>
</Reference>
<Reference Include="TermSharp">
<HintPath>$(RenodePath)/TermSharp.dll</HintPath>
</Reference>
<Reference Include="TracePlugin">
<HintPath>$(RenodePath)/TracePlugin.dll</HintPath>
</Reference>
<Reference Include="UI">
<HintPath>$(RenodePath)/UI.dll</HintPath>
</Reference>
<Reference Include="VerilatorPlugin">
<HintPath>$(RenodePath)/VerilatorPlugin.dll</HintPath>
</Reference>
<Reference Include="WiresharkPlugin">
<HintPath>$(RenodePath)/WiresharkPlugin.dll</HintPath>
</Reference>
<Reference Include="Xwt">
<HintPath>$(RenodePath)/Xwt.dll</HintPath>
</Reference>
<Reference Include="Xwt.WPF">
<HintPath>$(RenodePath)/Xwt.WPF.dll</HintPath>
</Reference>
</ItemGroup>
</Project> This obviously has a lot of platform-specific cruft. And I'm not sure on the At any rate, this gives me syntax checking, autocomplete, and rudimentary documentation. It also doesn't require me to compile Renode, since I'm just using the binaries directly. Edit: The |
I updated the |
Hey @xobs, this is really cool. We'll take a look internally and then maybe we'd be able to somehow include it in our packages, so that everyone can use it with simple instructions (like |
Writing C# modules unlocks a lot of functionality in Renode, however it's very difficult to debug these modules.
For example, in this module:
It's difficult to know:
machine
Machine
is defined (which package does it come from?)ClockSource
and how does it work?Antmicro.Renode.Peripherals
?IDoubleWordPeripheral
?Many of these questions could be answered by connecting this
.cs
file to an IDE of some sort. I'm not sure how2
could be answered, because I gather that's a feature of C#.7
can only be answered by restarting Renode.With C# modules being documented, it would also be nice to know how to implement modules and debug issues within them.
The text was updated successfully, but these errors were encountered: