view pcm-br/showbuf.c @ 40:e1eabf554a75

libhr: small subset of WIP libgsmhr1
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 30 Aug 2024 16:41:56 +0000
parents 499d065ee591
children
line wrap: on
line source

/*
 * Here we implement stdin commands that display current instantaneous
 * state of each read channel.
 */

#include <stdint.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>

#include <osmocom/core/select.h>

#include "globals.h"

void cmd_show_a(int argc, char **argv)
{
	int i, j, off;

	off = 0;
	for (i = 0; i < 10; i++) {
		for (j = 0; j < 16; j++)
			printf(" %02X", readbuf_a[off++]);
		putchar('\n');
	}
}

void cmd_show_b(int argc, char **argv)
{
	int i, j, off;

	off = 0;
	for (i = 0; i < 10; i++) {
		for (j = 0; j < 16; j++)
			printf(" %02X", readbuf_b[off++]);
		putchar('\n');
	}
}