capl

Call CAPL function from Python

余生长醉 提交于 2019-12-19 04:45:09
问题 I'm working on CANalyzer and I can't find how to call a CAPL function wich contains a parameter. If I put num in functions_call.Call(num) it doesn't work. def call(num): print 'calling from CAN' x=int(num) functions_call.Call() return 1 回答1: I ran into a similar problem a while back and some Googling led me to the following application note by Vector: http://vector.com/portal/medien/cmc/application_notes/AN-AND-1-117_CANoe_CANalyzer_as_a_COM_Server.pdf ...checkout section "2.7 Calling CAPL

Sending Periodic CAN signals on button press using CAPL and CANalyzer

我只是一个虾纸丫 提交于 2019-12-13 20:21:30
问题 I am trying to send a set of CAN frames on to CAN bus. I am using CAPL to program and CANalyzer8.5 to simulate and Panel designer to create a button. My requirement is to first create a button using PANEL designer. Only on button press it should start sending periodic CAN frames on to the bus. I am a bit confused as to how to achieve it. So far I have managed to write two separate programs using CAPL. First program sends data at start periodically. Second code sends data only once when the

How to read a float in a csv with CAPL?

99封情书 提交于 2019-12-12 22:14:19
问题 I have a .csv file and I want to read the data in its format, not at string. This is the function that save the file in a readbuffer if is ok. fileGetString(readbuffer,elcount(readbuffer),readHandle)!=0) And I have the data is in this format: Temperature;12.25;15.65;-25.12;80; Time;1;2;4;7; I want save the temperature in a buffer " Temperature[i] " and do the same with the time " Time[i] " How can I do this in CAPL? I know that I can read each data like String and cast to integer or float

Are timers running, while loops are active?

喜你入骨 提交于 2019-12-11 12:18:01
问题 Here's my code: setTimer(delay, (SEEDKEY_MAXTRY * SEEDKEY_FREQ) + (LOGIN_MAXTRY * LOGIN_FREQ)); do { // waits, until all operations have been executed; } while(isTimerActive(delay)); I know exactly how long it takes to execute my commands, so I set the timer delay to the explicit value. I have to wait, until I return some values. The simulation stucks at this point, my panels go into Windows-"No response" and the only way I can end the simulation is via Taskmanager. I think the only

Log Write Output to File in CAPL [closed]

谁说胖子不能爱 提交于 2019-12-11 03:36:40
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 5 years ago . Is there an easy way to take what I write to the write window and log it to a file? Or do I need to separately create an array of chars manually and open a file to write the char[] to? I would love to be able to write to file using regular expressions at the very least but I'm not

CAPL Programming usage of Timer as a delay

霸气de小男生 提交于 2019-12-10 17:49:31
问题 I have been writing a CAPL script that would send message on each channel (2 no's) after a certain delay. The following delay i want to generate using SetTimer() and mstimer::isRunning function. I can use setTimer function but I dont know how to use mstimer::isRunning . The code is shown below: Variables{ message * temp = {DLC=8}; mstimer timer1; } on timer timer1{ //Do nothing } onstart{ for(noofChannel=1;noofChannel<=2;noofChannel++){ settimer(timer1,100); temp.CAN = noofChannel; temp.ID =

How to include a .h or .dll file in CANoe/CAPL

倾然丶 夕夏残阳落幕 提交于 2019-12-07 07:07:05
问题 I want integrate a header .h or .dll file in CAPL (concretly Visa32.dll, visa.h or sicl.h) to control a multimeter 34461A. How can I include the .h files or .dll file in CANoe? I created an ECU module called multimeter. Thanks, 回答1: Including external DLLs in CAPL is possible, but you will need to create a wrapper for all the functions you're going to use. Take a look at \CANoe\Demo_AddOn\Capldll directorty which features such a wrapper. It's a MSVC project exporting a few simple functions to

Start and run CANoe from Command Prompt

断了今生、忘了曾经 提交于 2019-12-01 19:23:48
Is it possible to start and run Vector CANoe from the Command Prompt and/or by using any other external script? This document tells you how to control CANoe from C++, C# etc. This by making use of the CANoe as a COM Server utilities. http://www.vector.com/portal/medien/cmc/application_notes/AN-AND-1-117_CANoe_CANalyzer_as_a_COM_Server.pdf CANOE simply loads a .cfg configuration file. For jenkins, I am using the Visual Basics script and using this loading perticular configration file. In this was it bypasses the "I accept" and other windows and loads the desired configuration also also using

Call CAPL function from Python

烈酒焚心 提交于 2019-12-01 01:17:09
I'm working on CANalyzer and I can't find how to call a CAPL function wich contains a parameter. If I put num in functions_call.Call(num) it doesn't work. def call(num): print 'calling from CAN' x=int(num) functions_call.Call() return 1 I ran into a similar problem a while back and some Googling led me to the following application note by Vector: http://vector.com/portal/medien/cmc/application_notes/AN-AND-1-117_CANoe_CANalyzer_as_a_COM_Server.pdf ...checkout section "2.7 Calling CAPL Functions". To sum it up, make sure to declare your CAPL function's parameters as "long", .e.g: the following

Transmitting data over ISO-TP (transport protocol) in CANoe using CAPL

僤鯓⒐⒋嵵緔 提交于 2019-11-29 12:38:35
Using CAPL with CANoe to transmit big amount of data via ISO-TP on CAN. Is there a routine, that provides the handling of data segmentation embedded in CAPL or do I need to write my own interpretation? Take a look at the OSEK_TP CANoe demo. It shows how to transmit and receive data over ISO-TP ( Transport Protocol, ISO 15765-2 ). See the nodeA.can file and the OSEL_TP API reference for implementation details. Here is minimal example: Create and configure a connection: long handle; handle = CanTpCreateConnection(0); // 0 = Normal mode CanTpSetTxIdentifier(handle, 0x700); // Tx CAN-ID