Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] [Moved] CANalyzer - CAPL automation

Status
Not open for further replies.

dharanikumarsrvn

Junior Member level 1
Joined
Oct 22, 2012
Messages
15
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,401
HI,
I am trying to automate a CANalyzer configuration via python. I am using win32com.client module to automate. Following code explains the process.


Code Python - [expand]
1
2
3
4
5
6
7
8
9
10
11
12
13
import sys
import os
import time
import win32com.client
 
def can():
    CANalyzer = win32com.client.Dispatch('CANalyzer.Application') 
    measurement = CANalyzer.Measurement
    CANalyzer.Open("Configuration3.cfg") 
    measurement.Start()
    time.sleep(float(10)) # delays for XX seconds
    measurement.Stop()
    return 1



The above code successfully runs the configuration. But i need to access System Variables via python associated with this configuration. I tried to do like this.


Code Python - [expand]
1
2
3
NameSpace = CANalyzer.System.Namespaces("NameSpace")
SystemVariable = NS.Variable("SystemVariable")
Print SystemVariable.Value



But the above code fails. I cant get the correct syntax in python to access the System Variable. Could someone help me with this?
 
Last edited by a moderator:

Hello,
we have a script at **broken link removed** for access to system variables. You might try that in conjunction with the CANoe configuration **broken link removed**.

Kind regards
Andreas Neubauer (Vector Group)
 
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top