Cannot run unit tests for an application developed with Compact Framework for Windows CE 6.0 platform - compact-framework

I'm developing a solution for Windows CE 6.0 using GuD_AtomKit X86 Device emulator.
I'm not able to run any unit tests, because I get following error message:
The test adapter ('Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestAdapter, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.Adapter, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a') required to execute this test could not be loaded. Check that the test adapter is installed properly. Exception of type 'Microsoft.VisualStudio.SmartDevice.TestHostAdapter.DeviceAgent.TestAlreadyRunningException' was thrown.
But there's no unit test running on the device.
I would really appreciate your help.

Did you change the target device in your testrunconfig file? Running against the target device is definitely supported.
You also might have to manually deploy the CF to the device as the Unit Test framework doesn't auto-deploy it.

That was probably caused by a hardware issue. After I updated the flash with the board I was running the test against, it started to work again. So probably a bug in the firmware of the board... :(

Related

STM32CUBEIDE st link gdb debug error in final launch sequence

So, I am learning stm32 mcus, using a nucleo f4 board.
Everything was working fine and now debug launch fails.
Actually, I was doing one debug, closed it and next debug session won't launch.
It starts debug on Linux or on Windows with OpenOCD, but ST-Link GDB debug fails (gdb does work on linux).
This is the error message:
Already did allow the stlink server in the windows firewall.
Avast antivirus was deleting the STLINK server exe file, added an exception and it works.
Also the problem is the mass storage option (that allows use the explorer to grab directly the hex files) and makes conflicts with the ide. I solved the problem using explorer and ejecting the board, then debugger goes fine.

Running Win32 apps compiled for ARM on Windows RT

Say I have a desktop program that uses the Win32 API, but is compiled for the ARM architecture. How do I get it to run on Windows RT (the restricted version of Windows 8 for ARM tablets)? Windows RT refuses to run such apps without a Microsoft signature.
I know there is no official way to do it, but say it is for an in-house deployment, or just for testing purposes. What are my options?
(See this answer for the availability of Win32 API on Windows RT (not neccessarily for Metro apps, but present on the system), and this answer for how to compile Win32 programs for ARM using VS2012.)
Now you can run any app/exe on Windows RT : http://surfsec.wordpress.com/2013/01/06/circumventing-windows-rts-code-integrity-mechanism/
please see this thread,and you can run you exe without a Microsoft signature by CreateProcessA
http://forum.xda-developers.com/showthread.php?t=1944675
And now there is actually a "jailbreak"-like script:
http://forum.xda-developers.com/showthread.php?t=2092158
Usage:
Boot your RT device and log in, allow it to sit on the desktop for about a minute.
Run runExploit.bat, wait for it to do it's thing (shouldn't be more than 20 seconds or so)
Press Volume Down
Wait for runExploit.bat to finish, answer any prompts it gives. They should all be fairly self-explanatory.
It might crash while running the script, and it has to be done after every reboot. Also, I haven't tried it myself. In the post there is a link to a list of recompiled software that might be useful.

Automated testing for Windows Phone 8

Hitting a couple of issues attempting to setup automated testing of our C++ code on Windows Phone 8.
1) I'm hitting the limit of installed applications on our device. Is there any way to automate uninstalling the applications on the device? Via the command line?
2) Is there a recommended method to run unit tests on WinPhone8? Currently, I'm using devenv to load/run the our solution file. This has provided inconsistent results. The Windows Phone debugger doesn't get set in some cases, this causing a 'debugger not set' error when attempting to run.
Here is some good information on unit testing in Windows Phone 8:
http://www.microsofttranslator.com/bv.aspx?from=&to=en&a=http://qmatteoq.com/blog/post/unit-testing-in-windows-phone-8-the-basics
http://wp.qmatteoq.com/unit-testing-in-windows-phone-8-asynchronous-operations-and-mocking/
JustinAngel's answer https://stackoverflow.com/a/13429709/2087252 gives an example how to automate installing, running and deleting of applications on Windows Phone 8.
To make it work you'll need to reference following dlls from your project:
Microsoft.Smartdevice.Connectivity.Interface.dll
Microsoft.Smartdevice.Connectivity.dll
Microsoft.Smartdevice.MultiTargeting.Connectivity.dll
If you want to run your application/test on emulator, you can start it with following command line:
"C:\Program Files (x86)\Microsoft XDE\8.0\xde.exe" /name "Emulator WVGA 512MB.username"
where username is your windows username.

Simple-OpenNI for Processing fatal errors with the Kinect

I have been using SimpleOpenNI, a wrapper for Processing, all summer now. I use it for the Kinect to make games and demos. Last week, I have been getting a fatal error in my processing window and none of the SimpleOpenNI projects will work. Here is the error:
SimpleOpenNI Version 0.20
A fatal error has been detected by the Java Runtime Environment:
EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x72e8f955, pid=4596, tid=4624
JRE version: 6.0_24-b07
Java VM: Java HotSpot(TM) Client VM (19.1-b02 mixed mode windows-x86 )
Problematic frame:
C [OpenNI.dll+0xf955]
An error report file with more information is saved as:
C:\Users\mss042\Desktop\processing-1.5.1\hs_err_pid4596.log
If you would like to submit a bug report, please visit:
http://java.sun.com/webapps/bugreport/crash.jsp
The crash happened outside the Java Virtual Machine in native code.
See problematic frame for where to report the bug.
It appears as if the new OpenNI/NITE/SensorKinect drivers do not work with the SimpleOpenNI wrapper. I have tried it with people using the old drivers and everything still works. Problem is, you cannot download the old drivers off of the websites so I cannot test if it's that or not. You can see everything I've downloaded from the simpleopenni site: http://code.google.com/p/simple-openni/
Any help with this error would be appreciated. Thanks.
Mike
It looks like there's a problem with OpenNI.dll. Make sure that:
You have the dll (It should be in Program Files where you've installed OpenNI)
Make sure you've got the Environment Variables for the Open NI paths and that the paths are correct, otherwise, you might have the .dll file, but the .jnilib wouldn't know where it is.
Had a Kinect Workshop in Uni, and my colleagues using Windows all had issues with the drivers,
so I'm just passing on what they did:
Even though they had 64-bit versions of Windows they used the 32-bit version, and used Brekel OpenNI Kinect Auto Installer - Developer Edition v1.3.2.3.exe(direct link via developkinect.com) after reading this message:
Comment 4 by tijmenva...#gmail.com, Oct 21, 2011 Hey all I have Solved
the unsatisfied link dll error on windows 7 64 bits by installing java
runtime (jre-7u1-windows-i586.exe)and (Brekel OpenNI Kinect Auto
Installer - Developer Edition v1.3.2.3.exe) I uninstalled everything
and than it worked :)
hope this helpes
in Issue#17 on the SimpleOpenNI project issues page.
Another colleague used Synapse and OSC in Processing instead of SimpleOpenNI, but she had loads of errors with the drivers (basically spent a few good hours uninstalling/installing different versions). In her case, uninstalling any previous partial or complete drivers from the machine and deleting any registry entries related to PrimeSense(Sensor, Nite) and OpenNI, then using the installers from the links on the Synapse page, worked for her.
HTH
This is a long shot, but that exact error is also given if the Kinect USB and/or power supply simply becomes unplugged. Thought it was worth mentioning as it is not obvious from the error message itself and it may help someone out if they kicked their power supply and started searching for the above exception :)

running .net(mono) application in both linux and windows

I have created a c# application in ubuntu using monodevelop. It is running well in ubuntu.
I tried to run that application(firstgtk.exe file created after running in ubuntu)in windows.But it showing error message.How can i make to portable in both linux and windows?
The error message is:
when i click the firstgtk.exe file, a command prompt has come.It is blank. At the same moment microsoft message(send Error report or don't send):
firstgtk has encountered a problem and needs to close.
When i click don't send button, command prompt and message box are gone.
Mono compiles down to CIL code and is completely portable to .NET or Mono on other platforms. I can compile my C# code on a Mac and run the resulting EXE on Linux or Windows under either .NET or Mono.
Without the actual error message we can only guess the issue here. That said, in my experience, the most common reasons an application written in Mono on Linux/UNIX would create an error on Windows are pathnames with platform specific path separators or case sensitivity issues. The Windows file system is not case sensitive but they are on Linux/UNIX.
Another possibility is that you are using Mono on one platform and trying to run it on .NET on the other. Mono ships with a number of libraries that are not present in .NET on Windows.
Actually, I guess a final possibility is that GTK# is a common way to produce GUI code on Mono. GTK# relies on the GTK+ C library being present which is very common on Linux but unlikely on Windows unless it has been explicitly installed.
We really need to know what the error message was.
If you're using Gtk#, your app is portable between Windows and Linux. My guess is that you don't have Gtk# installed correctly (or at all?) on Windows. You can download from here. As of this time the latest version is 2.12.10.
Your code should be portable between Linux and Windows. Alas, the binaries are not. ...
Edit: As commenters have pointed out, Mono does produce and use PE executables, though other issues may limit portability.