2015-08-10 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>, Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v4.5.0
+ Comment debug print.
+ Fix CMakeLists.txt
+ Add InputFile::getpos().
+ Fix metadata loading for rblocks with a fixed number of instances.
+ Store fields section offsets.
+ Fix SDFBlock xml rblock name allocation.
+ Fix -Wextra warnings.
+ Fix src/CMakeLists.txt to work from a different source rootdir.
+ Install the static library with cmake.
+ Add cmake build system.
+ Remove pedantic warnings.
+ Throw exception on chdir error.
+ Fix xml parsing of SDFBlocks.
+ Example with iteration on blocks and fields
+ Added Packet::pheader(), Packet::dfheader(), Packet::sdf(), byte*
+ PartOfPacket::getBytes() as shortcuts
+ Adds xml examples
+ Makefile for Doxygen issues
+ Fix lot of warnings
+ Remove XmlConfig class.
+ Parsing directly XML without conversions.
+ Fix makefile output.
+ Rename SharedPtr include guards.

2014-07-24 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>, Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v4.3.2
+ Fixed Makefile for parallel build.
+ Fix getLine()
+ Use conditional assignment for CXX, CFLAGS and LINK in Makefiles
+ Fix bigendian attribute loading during xml parsing
+ Handle ARCH_BIGENDIAN cases

2014-07-24 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>, Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v4.3.1
+ -Werror -m64 CFLAGS removed.
+ Fix 32bit compilation warnings.
+ Add openDevice() for Input and Output classes.
+ Add Utility::getByteStream().
+ Add ByteStream functions getPaddedCopy() and getUnpaddedCopy().
+ PacketStream::PacketStream(const char* fileNameConfig) automatic createStr.
+ Add PacketLib4.vpp project.
+ First optimization of the getBlock() if rBlockIndex==0.

2014-07-17 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v4.3.0
+ added exception generation if LZ4 decompression has problems
+ removed Packet::decompressData. Now Packet::getData() performs the decompression operation in a transparent way

2014-07-14 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>, Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v4.2.0
+ Generating stream file in the same path of the xml
+ Fix loop on rblock idref/id resolution during xml parsing
+ Fix Tail element parsing, handle it as optional
+ Fix packet name xml loading
+ long PacketLib::ByteStream::getValue() and bool PacketNotRecognized::createPacketType()
+ Fix throw on ByteStream::GetValue()
+ Fix compiler warnings
+ Add -Werror
+ Fix ByteStream and Packet initialization
+ Fix some initialization
+ added word SDFBlock::getMaxNumberOfBlocks(word rblockIndex = 0)
+ word PartOfPacket::getFieldIndex(string fieldname) compare on strings issue
+ if prefix==false set dimPrefix=0


2014-04-26 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>, Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v4.1.0
+ Add support for xml config files.
+ Added get/setFieldValueTYPE methods on SDFBlock, PartOfPacket and SourceDataField.
+ Add lz4 compression.
+ Refactor from Packet::set to Packet::decode; PacketStream::getPacketType(string
name); from Packet::getOutputStream() to Packet::encode().
+ dword Packet::size() alternative flows without packet member.
+ Added Packet::getBSSourceDataField(), Packet::copyBSSourceDataField(byte* bytestream, dword size) methods.
+ Endianity fix.

2014-04-14 Andrea Zoli <zoli@iasfbo.inaf.it>, Andrea Bulgarelli
<bulgarelli@iasfbo.inaf.it>
TAG v4.0.2
+ Add build files to .gitignore.
+ dword Packet::size() alternative flows without packet member
+ Check for nullptr in Packet::size().
+ fix PacketHeader* Packet::getPacketHeader()
+ Add eclipse project files.
+ Add PacketBufferQ and PacketBufferV classes.
+ Add OutputPacketStream::writePacket(ByteStreamPtr bs)

2014-03-09 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v4.0.1
+ size() instead of getDimension
+ sizeMax()
+ removed decodeTupe
+ Packet::verify()
+ Packet::set()

2014-03-09 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v4.0.0
+ moved InputPacketStream::getPacket() to PacketStream
+ changed "onlySections" into decodeType:
	0) do not decode anything
	1) decode only sections (prefix, header, data field header, source data field fixed part, source data field variable part)
	3) decode blocks (all sections + all blocks of the source data field variable part
+ move InputPacketStream::detPacketType to PacketStream
+ move InputPacketStream::getPacketDimension to PacketStream
+ moved Packet::setByteStreamPointers into protected section
+ in Packet added dimPacketHeader, dimPacketDataFieldHeader, dimPacketSourceDataFieldFixed, dimPacketTail, dimPacketStartingFixedPart and related methods
+ Added Packet:: getBSPrefix(), getBSHeader(), getBSDataFieldHeader(), getBSSourceDataFieldsFixedPart(), getBSSourceDataFieldsVariablePart(), getBSTail()
+ added Packet::getPacketHeader(), getPacketDataFieldHeader(), getPacketSourceDataField(), getPacketTail()
+ all attributes of Packet and PacketDataField are protected
+ renamed SDFRBBlock in SDFBlock
+ renamed SDFRBlock in SourceDataField
+ removed all the code of packet types 1, 2, and 3
+ Packet::getBSPacket()


2014-03-06  Andrea Bulgarelli, Andrea Zoli <bulgarelli@iasfbo.inaf.it, zoli@iasfbo.inaf.it>
TAG v3.4.0
+ Packet* InputPacketStream::readPacket(int decodeType) and Packet* getPacket(ByteStreamPtr packet, int decodeType = 2)
+  Fix double throw definition.

2014-03-05  Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v 3.3.0
+ ByteStream use memcpy instead of a loop to copy buffers.
+ Using fread inside File::getNByte.
+ bDecode option for readPacket.

2014-03-02  Andrea Bulgarelli, Andrea Zoli <bulgarelli@iasfbo.inaf.it, zoli@iasfbo.inaf.it>
TAG v3.2.0
* added (1) decoding only section (bool onlySections), (2) PartOfPacket::decode() only on demand (3) ByteStream(ByteStreamPtr b0, dword start, dword end, bool memory_sharing)
* SDFRBBlock management of headers at different levels
* Changes in makefile (Etienne suggestion)
* File seek and ftell as long

2014-01-14  Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v3.1.1
* Added long File::fsize()
* Added dword InputFile::setpos(dword offset) throw(PacketExceptionIO*)
* installation of packetlib in $(includedir)/packet

2014-01-10	Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v3.1.0
* InputPacketStream: expose ByteStream instead of byte*.
* Fixed low level buffer (byte*) deallocation.

2013-12-23  Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
* PartOfPacket: get set PTC=5 PFC=2 (real double precision) TODO: this does
not work in a 32 bit system

2013-12-20  Andrea Zoli <zoli@iasfbo.inaf.it>
TAG v3.0.0
* Using a SharedPtr for the ByteStream instances.
* Fixed some memleak, jump that depends on uninitialised value(s) and buffer overflow.

2013-10-08  Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v2.0.8
* src/PartOfPacket.cpp (PartOfPacket::loadFields): inserted do-while
* src/PacketHeader.cpp (PacketHeader::~PacketHeader): removed delete name
* src/Packet.cpp (Packet::setPacketValue): bug correction
* include/PacketHeader.h (PacketHeader.getDimensionOfPacketLength): renamed the method for typo
* src/Packet.cpp (Packet::createPacketType): bool Packet::createPacketType(char* fileName, bool isprefix, word dimprefix) bug fix when the configuration files are read more than one time
* include/InputPacketStream.h (InputPacketStream): 
        ** dword getPacketDimension(byte* stream);
        ** int detPacketType(byte* packet);
* include/Packet.h (Packet): bool verifyPacketValue(byte* stream);


2013-09-13  Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v2.0.7
* src/PartOfPacket.cpp (PartOfPacket::setByteStream): 
	 For some reasons the following line introduced with v2.0.6:
	 222: this->stream->setStream(s, 0, s->getDimension() - 1);
	 does not work on linux (but only on make). Restored the old version
	 221: this->stream = s;

2013-09-12  Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v2.0.6

Bug resolved (http://redmine.iasfbo.inaf.it/issues/983): the ByteStream::stream do not contain the correct point to the stream
* src/SDFRBBlock.cpp (SDFRBBlock::setByteStream): 
	this->stream->setStream(s, 0, s->getDimension() - 1);
* src/PartOfPacket.cpp (PartOfPacket::setByteStream):
	//this->stream = s; <- OLD
    this->stream->setStream(s, 0, s->getDimension() - 1); <- NEW
* include/PartOfPacket.h (PartOfPacket): 
	** new method: virtual void deleteByteStream();
	** new method: virtual void memByteStream(ByteStream* stream);
	** stream moved into protected section
* include/SDFRBBlock.h: added deleteByteStream() and memByteStrem()
* changes on Packet.cpp,  PacketNotRecognized.cpp for new methods on PartOfPacket

2013-08-29 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v2.0.5

* include/ByteStream.h (ByteStream): void swapWordIfStreamIsBigEndian();
* include/ByteStream.h (ByteStream): renamed swap() in swapWord()
* include/ByteStream.h (ByteStream): void swapWordIfStreamIsLittleEndian();
* include/ByteStream.h (ByteStream): void swapWordIfStreamIsBigEndian();

2013-07-25 Andrea Bulgarelli <bulgarelli@iasfbo.inaf.it>
TAG v2.0.3

* 32 bit packet length

Example of .header format

-- name of header
Header CTA
-- number of field with dimension of packet (or first field if dim of packet is stored in a 32 bit field)
6
-- 16 or 32 bit size dimension of the packet lenght
32
[Field]
-- field 0
Version number
3
0b100
-- field 1
Type
1
0b0
-- field 2
DHFH
1
0b1
-- field 3
APID
11
none
-- field 4
SF
2
0b11
-- field 5
Source Sequence Counter
14
none
-- field 6
Packet Length MSB (4_14) - 1
16
none
-- field 7
Packet Length LSB (4_14) - 1
16
none

If the field '-- 16 or 32 bit size dimension of the packet lenght' is set to 16 or it is absent, the packet lenght is 16 bit.

* Field::value management (set predefined value=0 and during output stream generation
* Migration to git repository

15 July 2013
TAG CVS: PACKETLIB_1_4_0
+ 32 and 64 bit compatibility

2 July 2012
TAG CVS: PACKETLIB_1_3_10
+ resolved other problems with gcc4

09 Mag 2012
TAG CVS: PACKETLIB_1_3_9
+ resolved gcc4 problems
+ send to NASA/JPL the current version

7 December 2005
TAG CVS: PACKETLIB_1_3_8
+ added the management of number of blocks *2 per rblocks in the SDFRBBlock (symbol '*' in the line of sub from nblocks)

21 October 2005
TAG CVS: PACKETLIB_1_3_7
+ added the management of number of blocks /2 per rblocks in the SDFRBBlock (symbol '/' in the line of sub from nblocks)
+ added include <unistd.h>

24 August 2005
Started PacketLib 1.3.7

18 August 2005
TAG CVS: PACKETLIB_1_3_6
+ corrections after valngrind verification

23 July 2005
+ end first verification with valgrind

12 July 2005
TAG CVS: PACKETLIB_1_3_6_BETA1
+ used valgrind to verify the memory allocation problems

08 May 2005
TAG CVS: PACKETLIB_1_3_5
+ added set/getFieldValue_PTC_PFC to the SourceDataField class
+ added some cout error message during the decoding of the telemtry
+ added the mask pattern the the setFieldValue() methods

5 April 2005
TAG CVS: PACKETLIB_1_3_4
+ added the possibility to have an even number of byte in the definition of a block
+ addedd the Packet::printPacketOutputStream()
+ correction of the [SourceDataFieldBlock] not found keyword into the SDFBlockFixed
+ correction of the calculation of the dimension with tail

22 March 2005
TAG CVS: PACKETLIB_1_3_4_BETA2
PacketLib 1.3.4 beta 2
+ correct the bug for the setFieldValue4_13 and 3_13 
+ added the exception generation when for the 24 bit field value there are an out of range:
#define U24BITINTGEGERUNSIGNED_MAX 16777215
#define U24BITINTGEGERSIGNED_MIN -8388607
#define U24BITINTGEGERSIGNED_MAX 8388607


9 March 2005
TAG CVS: PACKETLIB_1_3_4_BETA1
PacketLib 1.3.4 beta
+ modified the management of the fields (class PartOfPacket). Now a field should be divided between two words
+ addedd getBlock() and getElement() methods for the Layout 2 and Layout 3
+ correction of the bug for the fixed number of blocks in the Layout 2 and 3. Now it is not necessary to set the number of the blocks.

2 March 2005
+ bug of the InputFile::isEOF()
+ added PTC/PFC 4/13 3/14 3/13


24 Fev 2005
CVS TAG: PACKETLIB_1_3_2
+ getFieldValue() and setFieldValue() with PTC, PFC (5, 1) and (4,14)
+ demo mode

=============================================

15 Feb 2005
CVS TAG: PACKETLIB_1_3_1
+ aggiunta la gestione del PTC=5 PFC=1 con il metodo double PartOfPacket::getFieldValue_5_1(word index)
ed il metodo double SourceDataField::getFieldValue_5_1(word block, word index)

=============================================

4 Nov 2004
CVS TAG: PACKETLIB_1_3_0
+ aggiunto il tipo generico di packet con blocchi definiti in modo ricorsivo (rblock).

=============================================
15 Aprile 2004
Inizio test della PacketLib 1.3.0 beta.
+ Tolta la SDFNoBlockVariable
+ Aggiunto il tipo generico SDFRBlock + SDFRBBlock
+ Corretto il bug sul prefix = 0
+ Aggiunto il tail

=============================================
14 Aprile 2004
CVS TAG: PACKETLIB_1_2_4
Versione con i 4 tipi di packet: block fixed, block variable, noblock fixed, noblock variable

Note: utilizzare la 1.2.3 per le acquisizioni per MCAL SEM DFE TE prima delle modifiche per adattare la PacketLib al PDHU TE.

=============================================
22 Agosto 2003
Nuova versione con il nuovo sistema di gestione dei progetti basato su makefile.
Aggiunta anche la classe Serial per la gestione della comunicazione su seriale
con codice per QNX.

=============================================
2 Maggio 2003
CVS TAG: PACKETLIB_1_2_3
Versione in cui �stata tolta la classe DISCoSSHM per inserirla direttamente nella ProcessorLib

=============================================
21 Febbraio 2003
CVS TAG: PACKETLIB_1_2_2
Versione rilasciata a:
1) Laben per Science Console MCAL DFE SEM BOARD_X (Febbraio 2003)
2) Versione utilizzata per MMC utilizzata in Laben (Febbraio 2003)

- Tolta la definizione NULL da PacketLibDefinition
- Modifiche minime a MSGQ.h e MSGQ.cpp

=============================================
8 Gennaio 2003
CVS TAG: PACKETLIB_1_2_1
Versione rilasciata a:
1) INFN (Federico)
2) ENEA
3) Laben per Science Console MCAL DFE SEM BOARD_X (Novembre 2002)

=============================================
20 Dicembre 2002
Aggiunta la classe MSGQ
Aggiunti alcuni metodi della classe Utility per la gestione dei processi

=============================================
4 Novembre 2002
Dal punto di vista concettuale, il parametro endianity nei file .stream cambia significato.
Prima infatti stava ad indicare l'architettura. In realt��pi giusto se indica il formato
dello stream di byte scambiato, indipendente dall'architettura. Questo perch��ad esempio
possibile memorizzare un file in formato big endian (scritto byte per byte) su una architettura
little endian.

+ Alcune classi hanno cambiato nome:
	- OutputSocket -> OutputSocketClient
	- Input -> Input2
	- InputPacketStream -> InputPacketStreamFile

+ Sono state aggiunte nuove classi:
	- Input
	- InputSocketServer
	- InputFile
	- InputPacketStream

+ Modifica ByteStream:
	- interfaccia: aggiunti nuovi metodi
	- gestione memoria: cambiate le responsabilit� Vedere Programmer's manual
	- spostata la gestione dell'endianity interamente all'interno del ByteStream. Le altre
		classi mantengono l'informazione sull'endianity solamente per creare i ByteStream

+ Eliminate le seguenti classi
	- InputByteFileSeq
	- InputByteSHMSeq
	- InputByteSeq
	- InputSeq
	- Input2
	- InputRandom

+ La classe InputText �diventata la root di una gerarchia di classi che rappresentano i file
	di configurazione

+ file.h e file.cpp sono stati rinominati in File.h e File.cpp

+ Definition.h �stato rinominato in PacketLibDefinition.h

+ Creato il namespace PacketLib

----------------------------------------------

+ aggiunto il metodo PacketStream::packetLibVersion()

=============================================
31 Maggio 2002
Rilasciata la versione 1.1
Tag CVS: PACKETLIB_1_1

----------------------------------------------

=============================================
31 Maggio 2002
Rilasciata la versione 1.0.5.

Tag CVS: PACKETLIB_1_0_5

Aggiunte:
+ aggiunte le classi Socket (gerarchia Device), SocketClient e SocketServer per la gestione di connessioni
socket
+ aggiunta la classe OutputSocket (gerachia Output)
+ aggiunto un costruttore alla classe ByteStream che permette di unire piu' ByteStream
+ aggiunta la possibilita' di generare TM/TC packet con prefix

=============================================
9 Maggio 2002
Prima versione 1.0.4.
Tag CVS: START
	 
