5
Last change
on this file since f831eff was
f831eff,
checked in by Sebastian Huber <sebastian.huber@…>, on 03/02/16 at 07:07:58
|
tmtests/tmtimer01: New test
Test run performed on T4240 running at 1667MHz in uni-processor
configuration.
Update #2554.
|
-
Property mode set to
100644
|
File size:
730 bytes
|
Line | |
---|
1 | # |
---|
2 | # Copyright (c) 2016 embedded brains GmbH. All rights reserved. |
---|
3 | # |
---|
4 | # The license and distribution terms for this file may be |
---|
5 | # found in the file LICENSE in this distribution or at |
---|
6 | # http://www.rtems.org/license/LICENSE. |
---|
7 | # |
---|
8 | |
---|
9 | import libxml2 |
---|
10 | from libxml2 import xmlNode |
---|
11 | import matplotlib.pyplot as plt |
---|
12 | doc = libxml2.parseFile('tmtimer01.scn') |
---|
13 | ctx = doc.xpathNewContext() |
---|
14 | |
---|
15 | plt.title('timer test') |
---|
16 | plt.xscale('log') |
---|
17 | plt.xlabel('active timers') |
---|
18 | plt.ylabel('timer fire and cancel [ns]') |
---|
19 | |
---|
20 | x = map(xmlNode.getContent, ctx.xpathEval('/TMTimer01/Sample/ActiveTimers')) |
---|
21 | for i in ['First', 'Middle', 'Last']: |
---|
22 | y = map(xmlNode.getContent, ctx.xpathEval('/TMTimer01/Sample/' + i)) |
---|
23 | plt.plot(x, y, label = i) |
---|
24 | plt.legend(loc = 'best') |
---|
25 | plt.show() |
---|
Note: See
TracBrowser
for help on using the repository browser.