SPKR.LST 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. Listing:
  2. 1 IMPLEMENTATION MODULE Spkr;
  3. 2 (*
  4. 3 * REPERTOIRE
  5. 4 * Release 1.6
  6. 5 * By Charles Bradford and Cole Brecheen
  7. 6 * (c) Copyright 1985-1992 PMI
  8. 7 * Green Bay, Wisconsin
  9. 8 * All rights reserved
  10. 9 * (414) 468-6040
  11. 10 *
  12. 11 * $Header: D:/logfiles/mods/spkr.mov 1.5 10 Mar 1991 15:32:56 coleb $
  13. 12 *
  14. 13 *)
  15. 14
  16. 15
  17. 16 IMPORT FAPI;
  18. 17
  19. 18 IMPORT ErrorManager;
  20. 19
  21. 20 VAR
  22. 21 Initialized : BOOLEAN;
  23. 22
  24. 23 PROCEDURE Init();
  25. 24 BEGIN
  26. 25 IF Initialized THEN
  27. 26 RETURN;
  28. 27 ELSE
  29. 28 Initialized := TRUE;
  30. 29 END;
  31. 30 ErrorManager.Init();
  32. ***** ^ not supported yet
  33. ***** ^ not supported yet
  34. ***** ^ not supported yet
  35. 31 END Init;
  36. ***** ^ not supported yet
  37. 32
  38. 33
  39. 34 PROCEDURE Calibrate();
  40. 35 BEGIN
  41. 36 END Calibrate;
  42. ***** ^ not supported yet
  43. 37
  44. 38
  45. 39 PROCEDURE Delay(pause : CARDINAL);
  46. 40 BEGIN
  47. 41 IF 0 # FAPI.DOSSLEEP( VAL(LONGINT, pause) ) THEN
  48. ***** ^ not supported yet
  49. ***** ^ not supported yet
  50. ***** ^ undeclared identifier
  51. ***** ^ not supported yet
  52. 42 END;
  53. 43 END Delay;
  54. ***** ^ not supported yet
  55. 44
  56. 45
  57. 46 PROCEDURE StartNoise(infreq : CARDINAL);
  58. 47 BEGIN
  59. 48 ErrorManager.WARN("Spkr.StartNoise not implimented");
  60. ***** ^ not supported yet
  61. ***** ^ not supported yet
  62. ***** ^ not supported yet
  63. 49 END StartNoise;
  64. ***** ^ not supported yet
  65. 50
  66. 51 PROCEDURE StopNoise();
  67. 52 BEGIN
  68. 53 ErrorManager.WARN("Spkr.StopNoise not implimented");
  69. ***** ^ not supported yet
  70. ***** ^ not supported yet
  71. ***** ^ not supported yet
  72. 54 END StopNoise;
  73. ***** ^ not supported yet
  74. 55
  75. 56 PROCEDURE TimedNoise(thefreq, thetime : CARDINAL);
  76. 57 BEGIN
  77. 58 IF 0 # FAPI.DOSBEEP( thefreq, thetime ) THEN
  78. ***** ^ not supported yet
  79. ***** ^ not supported yet
  80. ***** ^ not supported yet
  81. 59 END;
  82. 60 END TimedNoise;
  83. ***** ^ not supported yet
  84. 61
  85. 62 PROCEDURE Noise(kind : SoundTypes; pitch : SoundLevels; duration :
  86. ***** ^ undeclared identifier
  87. ***** ^ undeclared identifier
  88. 63 SoundTimes);
  89. ***** ^ undeclared identifier
  90. 64 VAR
  91. 65 i, dur, p1, d1 : CARDINAL;
  92. 66 BEGIN
  93. 67 (*noise*)
  94. 68 CASE pitch OF
  95. ***** ^ not supported yet
  96. 69 Low :
  97. ***** ^ undeclared identifier
  98. 70 p1 := 100;
  99. 71 | Normal :
  100. ***** ^ undeclared identifier
  101. 72 p1 := 440;
  102. 73 | High :
  103. ***** ^ undeclared identifier
  104. 74 p1 := 1100;
  105. 75 | RealHigh :
  106. ***** ^ undeclared identifier
  107. 76 p1 := 1800;
  108. 77 END;
  109. 78 CASE duration OF
  110. ***** ^ not supported yet
  111. 79 Short :
  112. ***** ^ undeclared identifier
  113. 80 d1 := 10;
  114. 81 | Medium :
  115. ***** ^ undeclared identifier
  116. 82 d1 := 30;
  117. 83 | Long :
  118. ***** ^ undeclared identifier
  119. 84 d1 := 60;
  120. 85 END;
  121. 86 IF kind=Beep THEN
  122. ***** ^ not supported yet
  123. ***** ^ undeclared identifier
  124. 87 TimedNoise(p1, d1);
  125. ***** ^ not supported yet
  126. ***** ^ not supported yet
  127. 88 ELSE
  128. 89 dur := d1 DIV 2;
  129. 90 FOR i := 1 TO 2 DO
  130. 91 TimedNoise(p1+500, dur);
  131. ***** ^ not supported yet
  132. ***** ^ not supported yet
  133. 92 TimedNoise(p1, dur);
  134. ***** ^ not supported yet
  135. ***** ^ not supported yet
  136. 93 END;
  137. 94 END;
  138. 95 END Noise;
  139. ***** ^ not supported yet
  140. 96
  141. 97
  142. 98 BEGIN
  143. 99 Initialized := FALSE;
  144. 100 Init();
  145. ***** ^ not supported yet
  146. ***** ^ not supported yet
  147. 101 END Spkr.
  148. ***** ^ not supported yet
  149. 46 errors