mirror of
https://github.com/radio95-rnt/rds95.git
synced 2026-02-27 04:43:52 +01:00
fixes
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
#include "lib.h"
|
#include "lib.h"
|
||||||
#include "ascii_cmd.h"
|
#include "ascii_cmd.h"
|
||||||
|
|
||||||
#define CMD_MATCHES(a) (ustrcmp(cmd, (char *)a) == 0)
|
#define CMD_MATCHES(a) (strcmp(cmd, (char *)a) == 0)
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const char *cmd;
|
const char *cmd;
|
||||||
|
|||||||
13
src/lib.c
13
src/lib.c
@@ -17,19 +17,6 @@ int _strnlen(const char *s, int maxlen) {
|
|||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
int ustrcmp(const char *s1, const char *s2) {
|
|
||||||
char c1, c2;
|
|
||||||
|
|
||||||
do {
|
|
||||||
c1 = *s1++;
|
|
||||||
c2 = *s2++;
|
|
||||||
if (c1 == '\0')
|
|
||||||
return c1 - c2;
|
|
||||||
} while (c1 == c2);
|
|
||||||
|
|
||||||
return c1 - c2;
|
|
||||||
}
|
|
||||||
|
|
||||||
static uint16_t offset_words[] = {
|
static uint16_t offset_words[] = {
|
||||||
0x0FC, /* A */
|
0x0FC, /* A */
|
||||||
0x198, /* B */
|
0x198, /* B */
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
extern void msleep(unsigned long ms);
|
extern void msleep(unsigned long ms);
|
||||||
|
|
||||||
extern int _strnlen(const char *s, int maxlen);
|
extern int _strnlen(const char *s, int maxlen);
|
||||||
extern int ustrcmp(const char *s1, const char *s2);
|
|
||||||
|
|
||||||
extern void add_checkwords(uint16_t *blocks, uint8_t *bits);
|
extern void add_checkwords(uint16_t *blocks, uint8_t *bits);
|
||||||
extern uint8_t add_rds_af(RDSAFs *af_list, float freq);
|
extern uint8_t add_rds_af(RDSAFs *af_list, float freq);
|
||||||
|
|||||||
Reference in New Issue
Block a user