X-Git-Url: http://git.linex4red.de/pub/USBasp.git/blobdiff_plain/b7ef7f49c9f6b4de962ae32776866bd1d5d59c3b..fd96b288824caaa3ee4e5e03887f016de9df80cf:/Projects/Magstripe/Lib/CircularBitBuffer.c?ds=sidebyside diff --git a/Projects/Magstripe/Lib/CircularBitBuffer.c b/Projects/Magstripe/Lib/CircularBitBuffer.c index 5d23762ec..128639413 100644 --- a/Projects/Magstripe/Lib/CircularBitBuffer.c +++ b/Projects/Magstripe/Lib/CircularBitBuffer.c @@ -1,22 +1,22 @@ /* LUFA Library - Copyright (C) Dean Camera, 2009. + Copyright (C) Dean Camera, 2010. dean [at] fourwalledcubicle [dot] com www.fourwalledcubicle.com */ /* - Copyright 2009 Denver Gingerich (denver [at] ossguy [dot] com) - Copyright 2009 Dean Camera (dean [at] fourwalledcubicle [dot] com) + Copyright 2010 Denver Gingerich (denver [at] ossguy [dot] com) + Copyright 2010 Dean Camera (dean [at] fourwalledcubicle [dot] com) - Permission to use, copy, modify, and distribute this software - and its documentation for any purpose and without fee is hereby - granted, provided that the above copyright notice appear in all - copies and that both that the copyright notice and this - permission notice and warranty disclaimer appear in supporting - documentation, and that the name of the author not be used in - advertising or publicity pertaining to distribution of the + Permission to use, copy, modify, distribute, and sell this + software and its documentation for any purpose is hereby granted + without fee, provided that the above copyright notice appear in + all copies and that both that the copyright notice and this + permission notice and warranty disclaimer appear in supporting + documentation, and that the name of the author not be used in + advertising or publicity pertaining to distribution of the software without specific, written prior permission. The author disclaim all warranties with regard to this @@ -37,7 +37,7 @@ #include "CircularBitBuffer.h" /** Function to initialize or reset a bit buffer, ready for data to be stored into it. */ -void BitBuffer_Init(BitBuffer_t* Buffer) +void BitBuffer_Init(BitBuffer_t* const Buffer) { /* Reset the number of stored bits in the buffer */ Buffer->Elements = 0; @@ -50,7 +50,7 @@ void BitBuffer_Init(BitBuffer_t* Buffer) } /** Function to store the given bit into the given bit buffer. */ -void BitBuffer_StoreNextBit(BitBuffer_t* Buffer, bool Bit) +void BitBuffer_StoreNextBit(BitBuffer_t* const Buffer, const bool Bit) { /* If the bit to store is true, set the next bit in the buffer */ if (Bit) @@ -79,7 +79,7 @@ void BitBuffer_StoreNextBit(BitBuffer_t* Buffer, bool Bit) } /** Function to retrieve the next bit stored in the given bit buffer. */ -bool BitBuffer_GetNextBit(BitBuffer_t* Buffer) +bool BitBuffer_GetNextBit(BitBuffer_t* const Buffer) { /* Retrieve the value of the next bit stored in the buffer */ bool Bit = ((*Buffer->Out.CurrentByte & Buffer->Out.ByteMask) != 0);