且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Windows Iot Core在Raspberry Pi3上挂起

更新时间:2022-05-29 08:01:15

我在Windows RT应用程序中遇到了类似问题几年之前必须不断播放音乐。检查内存泄漏。登录失败设备的设备门户,进入流程>当你的应用程序运行直到它挂起时,性能和内存持续上升
。然后重新启动并再次尝试此测试,但在应用程序挂起之前停止应用程序并查看内存使用量是否会下降。像这样的挂起是内存泄漏。通过更改代码来使用'using'关键字来解决内存泄漏问题,并且可以确保自定义类使用dispose模式和IDisposable接口正确处理其资源和自身。如果在运行应用程序时内存使用率上升但在停止应用程序时没有降低内存,那么
那么内置到windows或您应用程序的某个媒体基础winmd中的媒体基础管道有问题图书馆(如果您已经编写了客户媒体基础代码)。

I had a similar problem with a Windows RT app several years ago that had to play music continuously. Check for a memory leak. Log in to the device portal of the device that is failing and go to Processes > Performance and watch for memory rising continuously while your app runs until it hangs. Then reboot and try this test again but stop the app before it hangs and see if the memory usage drops back down. A hang like this is a memory leak. Address a memory leak by changing your code to use 'using' keywords where possible and make sure your custom classes are properly disposing their resources and themselves using the dispose pattern and IDisposable interface. If the memory usage goes up while you are running the app but doesn't drop back down when you stop the app, then there is something wrong with the media foundation pipeline built into windows or one of your app's media foundation winmd libraries (if you have written customer media foundation code).