Hi Keenan,
On 11/18/19 6:21 PM, Lang, Keenan C. wrote:
The scalcout record from the calc module
(https://github.com/epics-modules/calc) could theoretically do this by
using string replacements.
record("scalcout", "$(P)$(R)to_upper_1")
{
field("CALC", "AA{'a','A'}{'b','B'}...")
}
Though, with a maximum length of 80 characters, you'd only be able to
get 8 replacements per record. You'd have to chain together a set of 4
of these records to make an entire string capitalized (and then another
4 records for lowercase).
That is a pain which I love.
Another possible option is the luascript record from the lua module
(https://github.com/epics-modules/lua).
record("luascript", "$(P)$(R)to_upper")
{
field("CODE", "return string.upper(AA)")
}
From this, there is the more reason I have to study Lua record now.
It is the brilliant idea. Thank you again for guiding me to the new
adventure.
Best,
Han
P.S. I re-think the problem from scratch, and resolved it with the
different approach.
------------------------------------------------------------------------
*From:* Tech-talk <[email protected]> on behalf of Jeong Han
Lee via Tech-talk <[email protected]>
*Sent:* Sunday, November 17, 2019 5:33 PM
*To:* [email protected] <[email protected]>
*Subject:* string conversion to uppercase or lowercase
Hi,
Is there a way to convert a string from uppercase to lowercase or
vice-verse by using only available records within database files?
Best,
Han
- References:
- string conversion to uppercase or lowercase Jeong Han Lee via Tech-talk
- Re: string conversion to uppercase or lowercase Lang, Keenan C. via Tech-talk
- Navigate by Date:
- Prev:
Re: string conversion to uppercase or lowercase Jeong Han Lee via Tech-talk
- Next:
Re: [EXTERNAL] ai records with data covering many decades Maren Purves via Tech-talk
- 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: string conversion to uppercase or lowercase Lang, Keenan C. via Tech-talk
- Next:
Re: string conversion to uppercase or lowercase Johnson, Andrew N. via Tech-talk
- 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
|