Subject: |
"Count Num or Channel" option in MEDM cartesian plot |
From: |
Noboru Yamamoto <[email protected]> |
To: |
epics tech-talk <[email protected]> |
Date: |
Mon, 09 Feb 2009 14:31:11 +0900 |
Hi,
medm cartisian plot has an option "Plot Mode" to choose from "plot last
npts" and "plot n pts & stop". This number is specified by the other
option "Count Num or Channel" in "Resource Palette".
It used be OK to use a number in this option but it does not work in
recent versions. If you specifies Channel name in this options, it works.
I studied medm3_1_3 and apply modification shown in the attached file.
This modification works for me but I just run a few test, so it may not
good enough fro generic purpose but can be a start point to solve this
problem. This modification has at least one side effect. If you use
a channel name beginning with digits, it will be interpreted as number
in the attached code.
Regards,
Noboru
===================================================================
RCS file: RCS/medmCartesianPlot.c,v
retrieving revision 1.1
diff -r1.1 medmCartesianPlot.c
283,285c283,287
< if((dlCartesianPlot->countPvName[0] != '\0')
< && (!isdigit(dlCartesianPlot->countPvName[0]))
< && (validTraces > 0)) {
---
> if ((dlCartesianPlot->countPvName[0] != '\0') && (validTraces > 0)) {
> if (isdigit(dlCartesianPlot->countPvName[0])) {
> dlCartesianPlot->count=atoi(dlCartesianPlot->countPvName);
> pcp->countCh.recordX = NULL;
> } else {
288,290c290,292
< cartesianPlotUpdateScreenFirstTime,
< cartesianPlotUpdateGraphicalInfoCb,
< (XtPointer) &(pcp->countCh));
---
> cartesianPlotUpdateScreenFirstTime,
> cartesianPlotUpdateGraphicalInfoCb,
> (XtPointer) &(pcp->countCh));
291a294
> }
429c432
< if(pcp->countCh.recordX != 0) {
---
> if(pcp->countCh.recordX != NULL) {
1376c1379
< CpDataHandle hcp, hcpold, hcp1=NULL, hcp2=NULL, hcpold1=NULL, hcpold2=NULL;
---
> CpDataHandle hcp=NULL, hcpold=NULL, hcp1=NULL, hcp2=NULL, hcpold1=NULL, hcpold2=NULL;
2050a2054
> dlCartesianPlot->count= atoi(token);
2438c2442
< int k, n, iPrec;
---
> int k, n, iPrec=-1;
2440c2444
< int axis, isMax;
---
> int axis=-1, isMax=-1;
3010,3011c3014,3015
< xIsCurrentlyFromChannel, y1IsCurrentlyFromChannel,
< y2IsCurrentlyFromChannel;
---
> xIsCurrentlyFromChannel=False, y1IsCurrentlyFromChannel=False,
> y2IsCurrentlyFromChannel=False;
- Navigate by Date:
- Prev:
problem using the gpib-asyn support Maurizio Montis
- Next:
Re: Diamond Libera EPICS Driver Michael Abbott
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
<2009>
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
problem using the gpib-asyn support Maurizio Montis
- Next:
Re: NTP issues with rtems 4.9 and EPICS R3.14.10 Till Straumann
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
<2009>
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|