adding some notes, tested both send and recieve, both work fine but shift to letters and figures still needs to be implemented

This commit is contained in:
erratic 2015-01-24 22:17:18 +00:00
parent d962b12ac2
commit d38535715b
1 changed files with 24 additions and 12 deletions

View File

@ -808,7 +808,6 @@ main( int argc, char*argv[] )
* echo in wireless scenarios because of the longer delays. * echo in wireless scenarios because of the longer delays.
* Refer to the TTY specification for a solution to mitigating * Refer to the TTY specification for a solution to mitigating
* echo in wireless networks. * echo in wireless networks.
*
*/ */
bfsk_nstopbits = 1.5; bfsk_nstopbits = 1.5;
} }
@ -849,17 +848,30 @@ main( int argc, char*argv[] )
if ( band_width == 0 ) if ( band_width == 0 )
band_width = 50; // close enough band_width = 50; // close enough
} else { } else {
/* /*
* RTTY: baud=45.45 mark/space=variable shift=-170 * RTTY: baud=45.45 mark/space=variable shift=-170
*/ */
autodetect_shift = 170; if(strncasecmp(modem_mode, "tdd", 3) != 0)
if ( bfsk_mark_f == 0 ) {
bfsk_mark_f = 1585; autodetect_shift = 170;
if ( bfsk_space_f == 0 ) if ( bfsk_mark_f == 0 )
bfsk_space_f = bfsk_mark_f - autodetect_shift; bfsk_mark_f = 1585;
if ( band_width == 0 ) { if ( bfsk_space_f == 0 )
band_width = 10; // FIXME chosen arbitrarily bfsk_space_f = bfsk_mark_f - autodetect_shift;
}
if ( band_width == 0 ) {
band_width = 10; // FIXME chosen arbitrarily
}
}
else
{
// TODO shift isn't indicated by an actual frequency shift for
// TTY/TDD, rather these bits are sent:
// 11011 11011 Shift to figure
//11111 11111 Shift to letters
autodetect_shift = 0;
band_width = (band_width == 0) ? 45.45 : band_width;
}
} }
// defaults: 1 start bit, 1 stop bit // defaults: 1 start bit, 1 stop bit