LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Kvaser Leaf light does not show up in max even after refreshing

Solved!
Go to solution

I am using a Kvaser Leaf light HS hardware for CAN to USB. I have installed all its drivers from the KVASER website. When using with there sotware CANKING it works perfectly. BUT I am not able to detect it in MAX and LABVIEW. Any suggestions?????

0 Kudos
Message 1 of 14
(3,079 Views)

I'm not sure I've ever seen my Kvaser devices in Max, but I can see them in Windows' device manager.

 

Here's how I identify the Kvaser leafs in one of my systems:

 

Get CAN D.png

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 2 of 14
(3,069 Views)

I am new working in labview.... so if you could guide me a little. ...

 

I am able to see the kvaser hardware in device manager

 

so, do i need to make this VI posted by you in labview to check the kvaser hardware or is it available in some library?

Also i tried kvCanGetNumberOfChannels.vi and it shows 0.

 

 

0 Kudos
Message 3 of 14
(3,065 Views)

You'll need to initialize before trying to do anything (like getting the channel count).

 

Example_VI_BD.png

 

The snippet in my first post can be dragged into your block diagram (if you're using one of the newer versions of LabVIEW) - http://www.ni.com/white-paper/9330/en

 

I've attached a copy of that VI saved back to LabVIEW 8.2.  If you don't have the OpenG VIs installed (the green icons on the block diagram) you can just delete them.

 

<edited to add> Take a look at the example included with the Kvaser pallet (kvCanExample1.vi).

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 4 of 14
(3,050 Views)

I am able to get the number of channels using the vi by Kvaser. But when I run other VI's I get an error stating ''handle is invalid''. I checked the channel handle number from CAN devices application. It is 0 which I entered in the input handle number in the VI's. But still I get the message ''handle is invalid''.... Any suggestions ??

0 Kudos
Message 5 of 14
(3,034 Views)

Untitled.png

0 Kudos
Message 6 of 14
(3,031 Views)

Are you just running the VIs from the Kvaser pallet or have you written a VI that uses them?  The second method is preferred because you can run the CAN Handle from one VI to the next.

 

Can you post your code?  That will help us better answer your questions.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 7 of 14
(3,029 Views)

I just noticed your last post.  Try opening the CAN port and turning the bus on before reading.  The Kvaser sample shows how to configure the port before turning the bus on, too.  You're likely to need to do that in order to communicate with your target.

 

Example_VI_BD.png

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 8 of 14
(3,019 Views)

Hey Jim

 

The last snippet you gave me gives an error '' No more handles '' . It is error code -9. Shall I continue to run with this error or I am making some mistake ???

 

Thank You

 

Aditya Dalakoti

0 Kudos
Message 9 of 14
(2,997 Views)

Does it give you that error right away, or only after you've run it a bunch of times?  Try restarting LabVIEW and running it again.  I've seen that error during development where I repeatedly start my software and restarting LabVIEW fixes it.  I've never tried to resolve it and it has never been a problem in production.  Man, that makes me sound lazy...

 

 

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 10 of 14
(2,990 Views)