blob: 12bc993df6f7ed17688b897ec2dad8eedaf9bc1f [file] [log] [blame]
Harald Welte39cfbf42016-07-28 09:04:11 +02001#pragma once
2#include <stdbool.h>
3
4#include <osmocom/core/msgb.h>
Harald Welteb7e40232016-07-29 14:26:50 +02005#include <osmocom/core/logging.h>
Harald Welte39cfbf42016-07-28 09:04:11 +02006#include <osmocom/vty/command.h>
7#include <osmocom/abis/e1_input.h>
8
9/* logging */
10enum {
11 DMAIN,
12};
13
14/* vty */
15enum rec_vty_node {
16 RECORDER_NODE = _LAST_OSMOVTY_NODE + 1,
17};
18
19struct e1_recorder_line {
20 struct {
21 bool enabled;
22 uint8_t line_nr;
23 } mirror;
24};
25
26struct e1_recorder {
27 char *storage_path;
28 unsigned int max_file_size_mb;
29 struct e1_recorder_line line[256];
30};
31
32extern struct e1_recorder g_recorder;
33
34/* e1_recorder.c */
35void e1ts_raw_recv(struct e1inp_ts *ts, struct msgb *msg);
36
37/* vty.c */
38void recorder_vty_init(void);