0

So there are a lot of guides for this topic, like:

And I set up my project like described in those guides.

Project Settings>Player:

  • Scripting Backend is IL2CPP
  • Api Compatibility Level is .NET 4.x
  • The capabilities PrivateNetworkClientServer, InternetClientServer are checked

Build Settings:

  • Build Conf is Release

  • Architecture is ARM64

  • Copy References, Development Build, Script Debugging, Wait For Managed Debugger are checked

VS|HoloLens:

  • is connected via Wifi (not usb)
  • after deployment and start of the application I get the notification to start debugging, which I do. I open a script, that I want to debug, in unity which leads to a new instance of VS where I go to Debug>Attach unity debugger and choose one instance of my process (I get only one process, some ppl have more than one).

Issue:

  1. I placed some brakepoints an they get not triggered. I dont know why.
  2. Second question I have is - If this debugging would work, would it be possible to debug/step through code that is wrapped in a macro like #if UWP or WINMD?
Perazim
  • 1,501
  • 3
  • 19
  • 42
  • 1
    `I go to Debug>Attach unity debugger and choose one instance of my process (I get only one process, some ppl have more than one).` did you select the one from your device's IP? if it is not listed you can still try and explicitely search for it via IP manually -> `Input IP` – derHugo Feb 14 '22 at 13:46
  • I guess thats the reason! But VS cant find the process on the HL2, even if I type in the right IP :/ – Perazim Feb 14 '22 at 16:09
  • I tried "attach process" and selected under "Connection target" the HL2 and got the message: "Unable to connecto to the Microsoft Visual Studio Remote Debugger name 'xxx.xxx.xx.xx:port'. The Visual Studio 2019 Remote Debugger does not appear to be running on the remote computer. This may be because a firewall is preventing... so I guess I have a network problem – Perazim Feb 14 '22 at 16:29
  • 1
    @derHugo I found the reason! As everyone is working from home, we have a vpn switch which allows me for example to deploy from my working station (which is not at home) to my HoloLens (which is at home and connected with the vpn switch). And even though the deployment works, this switch does not allow debugging. – Perazim Feb 15 '22 at 12:47
  • good catch! That's a pity of course but at least I am sure that's most probably the issue – derHugo Feb 15 '22 at 13:21

0 Answers0