162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 262306a36Sopenharmony_ci/* speakup_dtlk.h - header file for speakups DoubleTalk driver. */ 362306a36Sopenharmony_ci 462306a36Sopenharmony_ci#define SYNTH_IO_EXTENT 0x02 562306a36Sopenharmony_ci#define SYNTH_CLEAR 0x18 /* stops speech */ 662306a36Sopenharmony_ci /* TTS Port Status Flags */ 762306a36Sopenharmony_ci#define TTS_READABLE 0x80 /* mask for bit which is nonzero if a 862306a36Sopenharmony_ci * byte can be read from the TTS port 962306a36Sopenharmony_ci */ 1062306a36Sopenharmony_ci#define TTS_SPEAKING 0x40 /* mask for SYNC bit, which is nonzero 1162306a36Sopenharmony_ci * while DoubleTalk is producing 1262306a36Sopenharmony_ci * output with TTS, PCM or CVSD 1362306a36Sopenharmony_ci * synthesizers or tone generators 1462306a36Sopenharmony_ci * (that is, all but LPC) 1562306a36Sopenharmony_ci */ 1662306a36Sopenharmony_ci#define TTS_SPEAKING2 0x20 /* mask for SYNC2 bit, 1762306a36Sopenharmony_ci * which falls to zero up to 0.4 sec 1862306a36Sopenharmony_ci * before speech stops 1962306a36Sopenharmony_ci */ 2062306a36Sopenharmony_ci#define TTS_WRITABLE 0x10 /* mask for RDY bit, which when set to 2162306a36Sopenharmony_ci * 1, indicates the TTS port is ready 2262306a36Sopenharmony_ci * to accept a byte of data. The RDY 2362306a36Sopenharmony_ci * bit goes zero 2-3 usec after 2462306a36Sopenharmony_ci * writing, and goes 1 again 180-190 2562306a36Sopenharmony_ci * usec later. 2662306a36Sopenharmony_ci */ 2762306a36Sopenharmony_ci#define TTS_ALMOST_FULL 0x08 /* mask for AF bit: When set to 1, 2862306a36Sopenharmony_ci * indicates that less than 300 bytes 2962306a36Sopenharmony_ci * are available in the TTS input 3062306a36Sopenharmony_ci * buffer. AF is always 0 in the PCM, 3162306a36Sopenharmony_ci * TGN and CVSD modes. 3262306a36Sopenharmony_ci */ 3362306a36Sopenharmony_ci#define TTS_ALMOST_EMPTY 0x04 /* mask for AE bit: When set to 1, 3462306a36Sopenharmony_ci * indicates that less than 300 bytes 3562306a36Sopenharmony_ci * are remaining in DoubleTalk's input 3662306a36Sopenharmony_ci * (TTS or PCM) buffer. AE is always 1 3762306a36Sopenharmony_ci * in the TGN and CVSD modes. 3862306a36Sopenharmony_ci */ 3962306a36Sopenharmony_ci 4062306a36Sopenharmony_ci /* data returned by Interrogate command */ 4162306a36Sopenharmony_cistruct synth_settings { 4262306a36Sopenharmony_ci u_short serial_number; /* 0-7Fh:0-7Fh */ 4362306a36Sopenharmony_ci u_char rom_version[24]; /* null terminated string */ 4462306a36Sopenharmony_ci u_char mode; /* 0=Character; 1=Phoneme; 2=Text */ 4562306a36Sopenharmony_ci u_char punc_level; /* nB; 0-7 */ 4662306a36Sopenharmony_ci u_char formant_freq; /* nF; 0-9 */ 4762306a36Sopenharmony_ci u_char pitch; /* nP; 0-99 */ 4862306a36Sopenharmony_ci u_char speed; /* nS; 0-9 */ 4962306a36Sopenharmony_ci u_char volume; /* nV; 0-9 */ 5062306a36Sopenharmony_ci u_char tone; /* nX; 0-2 */ 5162306a36Sopenharmony_ci u_char expression; /* nE; 0-9 */ 5262306a36Sopenharmony_ci u_char ext_dict_loaded; /* 1=exception dictionary loaded */ 5362306a36Sopenharmony_ci u_char ext_dict_status; /* 1=exception dictionary enabled */ 5462306a36Sopenharmony_ci u_char free_ram; /* # pages (truncated) remaining for 5562306a36Sopenharmony_ci * text buffer 5662306a36Sopenharmony_ci */ 5762306a36Sopenharmony_ci u_char articulation; /* nA; 0-9 */ 5862306a36Sopenharmony_ci u_char reverb; /* nR; 0-9 */ 5962306a36Sopenharmony_ci u_char eob; /* 7Fh value indicating end of 6062306a36Sopenharmony_ci * parameter block 6162306a36Sopenharmony_ci */ 6262306a36Sopenharmony_ci u_char has_indexing; /* nonzero if indexing is implemented */ 6362306a36Sopenharmony_ci}; 64