osmo_e1f: Allow to transmit AIS
AIS is an all-1 bit-pattern which is used by intermediate equipment
to indicate that the link somewhere upstream is lost.
Change-Id: Icc5a16ee44ecebe802c4cca0b6cc763a88b6cc05
diff --git a/software/obsolete/osmo_e1f.c b/software/obsolete/osmo_e1f.c
index 2c3fcfb..fa64e17 100644
--- a/software/obsolete/osmo_e1f.c
+++ b/software/obsolete/osmo_e1f.c
@@ -292,6 +292,11 @@
{
int i;
+ if (e1i->tx.ais) {
+ memset(out_frame, 0xff, 32);
+ return 0;
+ }
+
/* generate TS0 */
out_frame[0] = e1_pull_ts0(e1i);
diff --git a/software/obsolete/osmo_e1f.h b/software/obsolete/osmo_e1f.h
index c9d4778..0b423d9 100644
--- a/software/obsolete/osmo_e1f.h
+++ b/software/obsolete/osmo_e1f.h
@@ -10,6 +10,7 @@
struct osmo_e1f_tx_state {
bool remote_alarm;
bool crc4_error;
+ bool ais;
/* lower 5 bits: Sa4..Sa8 */
uint8_t sa4_sa8;
/* frame number 0..15 */