Cleaned up ANSTO code to merge with sinqdev.sics
This is our new RELEASE-4_0 branch which was taken from ansto/93d9a7c Conflicts: .gitignore SICSmain.c asynnet.c confvirtualmot.c counter.c devexec.c drive.c event.h exebuf.c exeman.c histmem.c interface.h motor.c motorlist.c motorsec.c multicounter.c napi.c napi.h napi4.c network.c nwatch.c nxscript.c nxxml.c nxxml.h ofac.c reflist.c scan.c sicshipadaba.c sicsobj.c site_ansto/docs/Copyright.txt site_ansto/instrument/lyrebird/config/tasmad/sicscommon/nxsupport.tcl site_ansto/instrument/lyrebird/config/tasmad/taspub_sics/tasscript.tcl statusfile.c tasdrive.c tasub.c tasub.h tasublib.c tasublib.h
This commit is contained in:
15
rwpuffer.h
15
rwpuffer.h
@@ -16,6 +16,13 @@ typedef struct __RWBuffer *prwBuffer;
|
||||
* \return NULL on success, else a pointer to t a new rwPuffer
|
||||
*/
|
||||
prwBuffer MakeRWPuffer(int size);
|
||||
/**
|
||||
* \brief create a RW buffer which can grow.
|
||||
* \param size The size of the buffer.
|
||||
* \param maxSize The maximum size of the buffer.
|
||||
* \return NULL on success, else a pointer to t a new rwPuffer
|
||||
*/
|
||||
prwBuffer MakeBigRWPuffer(int size, int maxSize);
|
||||
/**
|
||||
* \brief delete a rw buffer.
|
||||
* \param self The rwPuffer to delete.
|
||||
@@ -29,6 +36,14 @@ void KillRWBuffer(prwBuffer self);
|
||||
* \return 1 on success, 0 on failure
|
||||
*/
|
||||
int StoreRWBuffer(prwBuffer self, void *data, int count);
|
||||
/**
|
||||
* \brief Test if the data can be stored in the rwBuffer
|
||||
* \param self The rw buffer to store the data in
|
||||
* \param data pointer to the data to store
|
||||
* \param count The number of bytes to store
|
||||
* \return 1 when OK, 0 when buffer full
|
||||
*/
|
||||
int CanStoreRWBuffer(prwBuffer self, void *data, int count);
|
||||
/**
|
||||
* \brief Get a pointer to the current buffer data
|
||||
* \param self the buffer to get the data from
|
||||
|
||||
Reference in New Issue
Block a user