Page 1 of 1
Posted: Thu 31. Oct 2013, 14:19
I jost got my PCAN PCI card 4 channel (IPEH-003040). I have a problem with CanApi2.
I'm calling CAN_SetDeviceName('pcan_pci') with no error but when I go throught enumerating the hardware I get no hardware. Same routine called with CAN_SetDeviceName('pcan_usb') enumerate succesfully.
I'm using Delphi XE4 with Windows7 64bit.
Code: Select all
Ret := CAN_SetDeviceName('pcan_pci');
if Ret<>CAN_ERR_OK then exit;
for HwIdx := 1 to MAX_HCANHW do
NodeInfo.NodeType := NodeDevice;
Ret := CAN_GetHwParam(HwIdx, CAN_PARAM_NAME, @HwName, MAX_DRIVERNAMELEN);
Attached a screenshot of how CANNetConfign and CAn Hardware Control Pannel Applet appears.
Posted: Thu 31. Oct 2013, 16:22
this is strange.
I've tested this by myself in a short Delphi XE2 application, and it works as expected. Both as 32-bit and 64-bit EXE. Can you verify that my example (see attachment) also works on your computer?
Posted: Mon 4. Nov 2013, 09:03
yes your test program works fine, also with Delphi XE4.
I'm gone throught my source code all the weekend to understand where it differs from your call.
I didn't get any results. In my source the PCI enumertaion still does not work. I get Always results 5120d back from the CAN_GetHardwareParam.
Any other suggestion?
Posted: Mon 4. Nov 2013, 09:44
don't ask me how.
I did Windows->Restart, Delphi->Project->Clean All, Delphi->Project->Build All and now it works.
Thanks for the support,