Author |
Topic |
|
mfh
10 Posts |
Posted - 21 Apr 2004 : 09:21:29
|
I'm trying to run the CAN test code as suplied from ADS. I compile the code and start it using the IDE but when running the openCAN function it doesn't work correctly. I always get 0xffffffff back from the CreateFile call. This should be caught in the following if statement, but it isn't.
So my problem is that CreateFile always return an error. Secondary problem is that it isn't caught by the application.
Any clues what I'm doing wrong?
/Martin |
|
akidder
1519 Posts |
Posted - 21 Apr 2004 : 17:42:12
|
Hi Martin. Do you have the most recent release of the CAN test? The test has evolved over time as the drivers have changed.
Also, have you tried using the precompiled version included with the source code? That's often a good sanity check. Email us if you need the latest version of the test app! |
 |
|
akidder
1519 Posts |
Posted - 21 Apr 2004 : 17:51:44
|
One other thing to check. Are you using the latest CE build releases for the AGX? The CAN driver has changed a bit over time.
I think our most recent tests were run with 4.10.16. If you're still having trouble, it'll be good to know what build you're using. |
 |
|
mfh
10 Posts |
Posted - 22 Apr 2004 : 07:16:00
|
I think we got the code the other day, so it should be the latest and greatest. The CE build is 4.2 (unknown subversion).
Since the CreateFile dosn't seem to show an error even though it returns -1 I'm a bit unsure about the test with the precompiled code. It does however throw an error at me for every thing I do. Change Baud rate and Reset CAN chip both does at least.
Since I don't have my CANAlyzer hooked up right now I can't try messages.
/Martin |
 |
|
akidder
1519 Posts |
Posted - 22 Apr 2004 : 09:49:31
|
Thanks Martin. The ADS CE build will be important for us to know. Take a look at the debug port output and let us know which one you're using (e.g. 4.20.05). |
 |
|
mfh
10 Posts |
Posted - 22 Apr 2004 : 11:09:47
|
Debug reports it as AGX Build 4.20.02
/Martin |
 |
|
akidder
1519 Posts |
Posted - 22 Apr 2004 : 14:18:19
|
Thanks, Martin. 4.20.02 is a very old build and doesn't include the latest revisions of the CAN driver. Can you try installing one of the current AGX builds and testing again? Thanks! |
 |
|
mfh
10 Posts |
Posted - 23 Apr 2004 : 08:52:35
|
Did a quick test with 4.20.05
Looks promising, but I got sidetracked so only had time to try a "reset CAN chip" on the pre built vertsion. Will post again if I stil have problems, otherwise I will consider the problem solved.
Thanks, Martin |
 |
|
|
Topic |
|