two different cards within computer - cudaGetDeviceCount() returns "1" only cannot use CUD

Hi, I finally managed to install the drivers for my GeForce 8400 GS. There are two problems:

  1. When I plug in my monitor (TFT, VGA interface) to the nVidia card the monitor switches to stand-by mode

when being connected to the GeForce 8400 GS card although I enabled ‘use this card [8400 GS] for primary screen’

in the Windows display properties.

  1. I have the following code:



bool InitCUDA(void){return true;}


bool InitCUDA(void)


int count = 0;

int i = 0;


if(count == 0) {

	fprintf(stderr, "There is no device.\n");

	return false;


for(i = 0; i < count; i++) {

	cudaDeviceProp prop;

	if(cudaGetDeviceProperties(&prop, i) == cudaSuccess) {

		if(prop.major >= 1) {





if(i == count) {

	fprintf(stderr, "There is no device supporting CUDA.\n");

	return false;



printf("CUDA initialized.\n");

return true;




I stepped through the code using F11. When cudaGetDeviceCount() is called, VS or whatever seems

to load drivers (I see it in the status bar of my Visual Studio). But the function returns 1 only,

although I have 2 cards (one ATI Rage 128 Pro AGP and on nVidia GeForce 8400 GS PCI).

NOTE: I DO have installed the drivers, I have the nVidia System Control in the SysTray.

What’s the error here?


Why not read Programming Manual?

cudaGetDeviceCount() return number of CUDA-comptible devices. Do you believe your ATI Rage can really handle CUDA? )))

I’m sorry, I read it several times but I can’t remember every detail of a few hundred pages :(

Ok but something’s wrong here. Before I installed my GeForce 8400 GS this function returned “1”, too.

I set up a post here and someone said there’d be a bug inside cudaGetDeviceCount().

So I thought the “1” is the 1 that already appeared, I expected the function to return “2” after I plugged in the GeForce card.

But still there’s something wrong, the program exits as soon as memory is to be copied from host to device.

So the CUDA stuff does not seem to ‘find’ the GeForce card.

Also I don’t understand why I don’t get a usable signal at the VGA output of the card.

No, the only thing it can handle is DukeNukem 3D (©1996 3DRealms)

With no CUDA devices on system cudaGetDeviceCount() will return only one device which is actually software emulation. With 8400 in CUDA recognizes it and does not include that emulator into result.

Run deviceQuery sample with and without 8400 and you should see the difference.

I had the same problem with an Ati(slot 1, monitor attached to it) card and a 2600 GTX on slot 2. I was getting only one device, but examining device properties returned no name, and unrealistic other data. I was using latest drivers and CUDA (2.1).

Ok folks I tried to run ‘deviceQuery’.

Initialization Error, brothers!!!

Sorry I have no idea what this means. I tried searching the forum for ‘initialization error cudaGetDeviceCount()’ but didn’t find

usable results. I attached a screenshot. Sorry for the German blahblah, the window at the left side is ‘Properties of NVIDIA GeForce 8400 GS’.

In this window you can see that the GeForce driver is from December 26th, 2008. That was the newest one I could get. I’m using CUDA SDK

2.0 WinXP32. What the heck is going on?