aboutsummaryrefslogtreecommitdiffstats
path: root/src/amps
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2016-12-06 17:45:48 +0100
committerAndreas Eversberg <jolly@eversberg.eu>2016-12-06 17:46:12 +0100
commiteed826387a791d3e75d05e72131e0141110d264d (patch)
tree1d46874d697cd75689c5b45bbaea6383a49706b4 /src/amps
parent27c6e3d860aed41f6ed44997b1410b229f2bd53f (diff)
work on docs
Diffstat (limited to 'src/amps')
-rw-r--r--src/amps/amps.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/amps/amps.c b/src/amps/amps.c
index d9f6287..f330f2f 100644
--- a/src/amps/amps.c
+++ b/src/amps/amps.c
@@ -17,6 +17,24 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+/*
+ * Notes on frames and scheduling:
+ *
+ * If the amps->dsp_mode is set to transmit frames, fsk_frame() at dsp.c code
+ * requests frames, modulates them and forwards them to sound device. Whenever
+ * the dsp.c code requests frame (if no frame exists or frame had been sent),
+ * it calls amps_encode_frame_focc() or amps_encode_frame_fvc() of frame.c.
+ * There it generates a sequence of frames (message train). If no sequence is
+ * transmitted or a new sequence starts, amps_tx_frame_focc() or
+ * amps_tx_frame_fvc() of amps.c is called. There it sets message data and
+ * other states according to the current trans->state.
+ *
+ * If a frame is received by dsp.c code, amps_decode_frame() at frame.c is
+ * called. There the bits are decoded and messages are assembled from multiple
+ * frames. Then amps_rx_recc() at amps.c is called, so the received messages
+ * are processed.
+ */
+
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>