Hello,
I am trying to add a variable into the pbuf. I see the main function should be something like:
pbuf_add_field_{TYPE}(name, persistence, dtype, dimsizes, index, col_type)
my doubts are on these 2 arguments:
-persistence, it can be 'global' or 'physpkg' but I don't know the meaning
-index, seems like it is set to 0 or -1 for different variables and I don't know which one to use. I understand this is an initialization that will be changed after with the real index through pbuf_get_index
After that, i understand I should be calling two more functions (pbuf_get_field and pbuf_get_index), but:
-which is the role of the pbuf_get_field function, where to call it and which arguments it accepts. I see sometimes they use 'pbuf' as first argument sometimes it's 'pbuf2d'
-when to call the pbuf_get_index function
Overall, I am having trouble with adding a new variable in the physical buffer. If anyone can help with that, it'd great. Thank you!
I am trying to add a variable into the pbuf. I see the main function should be something like:
pbuf_add_field_{TYPE}(name, persistence, dtype, dimsizes, index, col_type)
my doubts are on these 2 arguments:
-persistence, it can be 'global' or 'physpkg' but I don't know the meaning
-index, seems like it is set to 0 or -1 for different variables and I don't know which one to use. I understand this is an initialization that will be changed after with the real index through pbuf_get_index
After that, i understand I should be calling two more functions (pbuf_get_field and pbuf_get_index), but:
-which is the role of the pbuf_get_field function, where to call it and which arguments it accepts. I see sometimes they use 'pbuf' as first argument sometimes it's 'pbuf2d'
-when to call the pbuf_get_index function
Overall, I am having trouble with adding a new variable in the physical buffer. If anyone can help with that, it'd great. Thank you!