mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-27 15:32:52 +02:00
radiotext: cleanup from tons of unused code; rass is dead
Origin commit data
------------------
Branch: ni/coolstream
Commit: e8bb447fcf
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-11-27 (Mon, 27 Nov 2017)
Origin message was:
------------------
- radiotext: cleanup from tons of unused code; rass is dead
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -26,19 +26,8 @@
|
||||
#include <stdio.h>
|
||||
#include <sys/time.h>
|
||||
|
||||
/* for timetest */
|
||||
//#include <time.h>
|
||||
//#include <sys/time.h>
|
||||
unsigned short crc16_ccitt(unsigned char *daten, int len, bool skipfirst)
|
||||
{
|
||||
/* timetest */
|
||||
//struct timeval t;
|
||||
//unsigned long long tstart = 0;
|
||||
//if (gettimeofday(&t, NULL) == 0)
|
||||
// tstart = t.tv_sec*1000000 + t.tv_usec;
|
||||
|
||||
// CRC16-CCITT: x^16 + x^12 + x^5 + 1
|
||||
// with start 0xffff and result invers
|
||||
register unsigned short crc = 0xffff;
|
||||
|
||||
if (skipfirst) daten++;
|
||||
@@ -50,10 +39,6 @@ unsigned short crc16_ccitt(unsigned char *daten, int len, bool skipfirst)
|
||||
crc ^= ((crc & 0xff) << 4) << 1;
|
||||
}
|
||||
|
||||
/* timetest */
|
||||
//if (tstart > 0 && gettimeofday(&t, NULL) == 0)
|
||||
// printf("vdr-radio: crc-calctime = %d usec\n", (int)((t.tv_sec*1000000 + t.tv_usec) - tstart));
|
||||
|
||||
return ~(crc);
|
||||
}
|
||||
|
||||
@@ -72,30 +57,3 @@ cTimeMs::cTimeMs(void)
|
||||
{
|
||||
Set();
|
||||
}
|
||||
|
||||
#if 0
|
||||
uint64_t cTimeMs::Now(void)
|
||||
{
|
||||
struct timeval t;
|
||||
if (gettimeofday(&t, NULL) == 0)
|
||||
return (uint64_t(t.tv_sec)) * 1000 + t.tv_usec / 1000;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void cTimeMs::Set(int Ms)
|
||||
{
|
||||
begin = Now() + Ms;
|
||||
}
|
||||
|
||||
bool cTimeMs::TimedOut(void)
|
||||
{
|
||||
return Now() >= begin;
|
||||
}
|
||||
|
||||
uint64_t cTimeMs::Elapsed(void)
|
||||
{
|
||||
return Now() - begin;
|
||||
}
|
||||
|
||||
#endif
|
||||
//--------------- End -----------------------------------------------------------------
|
||||
|
Reference in New Issue
Block a user