Experimental Physics and Industrial Control System
One problem is that you used upper-case for VAL. In the aiRecord.h file that is lower-case. It is upper case only when using the PV name.
So change this:
precord->VAL=3;
e=precord->VAL;
to this:
precord->val=3;
e=precord->val;
The compiler is clear about other errors too, like that precord->DOUBLE does not exist, etc.
Mark
________________________________
From: [email protected] [[email protected]] on behalf of priya tiwari [[email protected]]
Sent: Monday, February 02, 2015 12:05 AM
To: Mark Engbretson
Cc: [email protected]
Subject: Re: related to coding
sorry sir this is compile time error, What would be the solution of this problem? Actually i want to write a simple code for putting a value in VAL field of ai record.
On Mon, Feb 2, 2015 at 10:47 AM, Mark Engbretson <[email protected]<mailto:[email protected]>> wrote:
Note: these are NOT run time errors, your code doesn't even compile.
Sent from my iPad 4
On Feb 1, 2015, at 23:05, priya tiwari <[email protected]<mailto:[email protected]>> wrote:
Thanks Sir,
I changed in a code but still i got the errors at run time.please provide me solution.
On Mon, Feb 2, 2015 at 9:50 AM, Mooney, Tim M. <[email protected]<mailto:[email protected]>> wrote:
Hi Priya,
Return 2, instead of 0, from read_ai. That tells the record that you put the value in VAL. If you return 0, you are telling the record you put the value in RVAL, and that the record should convert RVAL to get VAL.
See "Device Support Routines" in
https://wiki-ext.aps.anl.gov/epics/index.php/RRM_3-14_Analog_Input
Tim Mooney ([email protected]<mailto:[email protected]>) (630)252-5417
Software Services Group (www.aps.anl.gov<http://www.aps.anl.gov>)
Advanced Photon Source, Argonne National Lab
________________________________
From: [email protected]<mailto:[email protected]> [[email protected]<mailto:[email protected]>] on behalf of priya tiwari [[email protected]<mailto:[email protected]>]
Sent: Sunday, February 01, 2015 9:54 PM
To: [email protected]<mailto:[email protected]>
Subject: related to coding
Hello,
I am trying to write the value into val field of ai record from device support.I am beginner in EPICS so I have no idea about this. But i have tried then i got the errors at run time please help me.I am attaching code file.
Thanks in advance...
<Screenshot from 2015-02-02 10:30:06.png>
<dbtest.c>
- References:
- related to coding priya tiwari
- RE: related to coding Mooney, Tim M.
- Re: related to coding priya tiwari
- Re: related to coding Mark Engbretson
- Re: related to coding priya tiwari
- Navigate by Date:
- Prev:
Re: related to coding priya tiwari
- Next:
Remote Controlled Power Distribution Units? Ralph Lange
- 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:
Re: related to coding priya tiwari
- Next:
Remote Controlled Power Distribution Units? Ralph Lange
- 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