speakup_dtlk.h 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /* speakup_dtlk.h - header file for speakups DoubleTalk driver. */
  2. #define SYNTH_IO_EXTENT 0x02
  3. #define SYNTH_CLEAR 0x18 /* stops speech */
  4. /* TTS Port Status Flags */
  5. #define TTS_READABLE 0x80 /* mask for bit which is nonzero if a
  6. * byte can be read from the TTS port
  7. */
  8. #define TTS_SPEAKING 0x40 /* mask for SYNC bit, which is nonzero
  9. * while DoubleTalk is producing
  10. * output with TTS, PCM or CVSD
  11. * synthesizers or tone generators
  12. * (that is, all but LPC)
  13. */
  14. #define TTS_SPEAKING2 0x20 /* mask for SYNC2 bit,
  15. * which falls to zero up to 0.4 sec
  16. * before speech stops
  17. */
  18. #define TTS_WRITABLE 0x10 /* mask for RDY bit, which when set to
  19. * 1, indicates the TTS port is ready
  20. * to accept a byte of data. The RDY
  21. * bit goes zero 2-3 usec after
  22. * writing, and goes 1 again 180-190
  23. * usec later.
  24. */
  25. #define TTS_ALMOST_FULL 0x08 /* mask for AF bit: When set to 1,
  26. * indicates that less than 300 bytes
  27. * are available in the TTS input
  28. * buffer. AF is always 0 in the PCM,
  29. * TGN and CVSD modes.
  30. */
  31. #define TTS_ALMOST_EMPTY 0x04 /* mask for AE bit: When set to 1,
  32. * indicates that less than 300 bytes
  33. * are remaining in DoubleTalk's input
  34. * (TTS or PCM) buffer. AE is always 1
  35. * in the TGN and CVSD modes.
  36. */
  37. /* data returned by Interrogate command */
  38. struct synth_settings {
  39. u_short serial_number; /* 0-7Fh:0-7Fh */
  40. u_char rom_version[24]; /* null terminated string */
  41. u_char mode; /* 0=Character; 1=Phoneme; 2=Text */
  42. u_char punc_level; /* nB; 0-7 */
  43. u_char formant_freq; /* nF; 0-9 */
  44. u_char pitch; /* nP; 0-99 */
  45. u_char speed; /* nS; 0-9 */
  46. u_char volume; /* nV; 0-9 */
  47. u_char tone; /* nX; 0-2 */
  48. u_char expression; /* nE; 0-9 */
  49. u_char ext_dict_loaded; /* 1=exception dictionary loaded */
  50. u_char ext_dict_status; /* 1=exception dictionary enabled */
  51. u_char free_ram; /* # pages (truncated) remaining for
  52. * text buffer
  53. */
  54. u_char articulation; /* nA; 0-9 */
  55. u_char reverb; /* nR; 0-9 */
  56. u_char eob; /* 7Fh value indicating end of
  57. * parameter block
  58. */
  59. u_char has_indexing; /* nonzero if indexing is implemented */
  60. };