On 4/10/19 8:39 AM, Kasemir, Kay via Core-talk wrote:
> From: Bruno Martins <[email protected]>
>> Related: https://epics.anl.gov/core-talk/2018/msg00284.php
> Alright, so missing info about size encoding is a known issue.
>
> Also related:
> The element count encoding of the search request for the channel names,
> struct {
> int searchInstanceID;
> string channelName;
> } channels[];
> },
> always seems to use a 2-byte short count, not the usual size encoding.
yup.
https://github.com/epics-base/pvAccessCPP/blob/78410499f0236f5830a0937567bbb794de7b2347/src/server/responseHandlers.cpp#L281
https://github.com/mdavidsaver/cashark/blob/7ea746615292e33ed44d6f3a54c6181996804a33/pva.lua#L379-L383
> I assume that's because all implementations currently start with
> short count: 0
> and then keep updating the buffer in place:
Also yes.
https://github.com/epics-base/pvAccessCPP/blob/78410499f0236f5830a0937567bbb794de7b2347/src/remote/channelSearchManager.cpp#L256-L275
the "ick!!!" comment is mine.
https://github.com/epics-base/pvAccessCPP/blob/78410499f0236f5830a0937567bbb794de7b2347/src/remote/channelSearchManager.cpp#L57-L58
> short count: 1
> int some_channel_id
> string some_channel_name
>
> short count: 2
> int some_channel_id
> string some_channel_name
> int some_channel_id
> string some_channel_name
>
> With normal size encoding, once you have count >= 254 you'd have to shift all channel ids and names down to make room for a larger count.
>
> -Kay
>
- References:
- PV Access Protocol Specification Kasemir, Kay via Core-talk
- Re: PV Access Protocol Specification Timo Korhonen via Core-talk
- Re: PV Access Protocol Specification Kasemir, Kay via Core-talk
- Re: PV Access Protocol Specification Bruno Martins via Core-talk
- Re: PV Access Protocol Specification Kasemir, Kay via Core-talk
- Navigate by Date:
- Prev:
Re: PV Access Protocol Specification Johnson, Andrew N. via Core-talk
- Next:
Re: PV Access Protocol Specification Michael Davidsaver via Core-talk
- Index:
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: PV Access Protocol Specification Kasemir, Kay via Core-talk
- Next:
Re: PV Access Protocol Specification Timo Korhonen via Core-talk
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
<2019>
2020
2021
2022
2023
2024
|