home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1994 #1 / monster.zip / monster / MATH / VISSIM.ZIP / D2A.VSM < prev    next >
Text File  |  1993-02-17  |  3KB  |  117 lines

  1. ; VisSim Block Diagram Format (VBDF)
  2. ; Copyright (C) 1989-1992 Visual Solutions
  3. PV=1.200
  4. PS=0
  5. PE=2
  6. PP=0.001
  7. PI=175
  8. PX=0.001
  9. PN=1e-006
  10. PF=10
  11. PD=800x600
  12. Pf=0x0
  13. Ps=860,0,0,526,0,0
  14. PM=1,1,1,1
  15. N.1="comment"@18x7@760x191<M>
  16. C="Digital to Analog Converter Model        
  17.  
  18. Can be used to model 8, 12, 16 or any bitlength converter.  The output is a voltage between 0 and Vref where Vref is typically 5 or 10 Vdc. NOTE: The sign is carried in a seperate bit not in the converter. The input is a digital sequence (series of pulses) and the output is an analog signal (sampled and held).  There are 4 parameters; N (# of bits in the converter, usually 8, 12, or 16), the Maximum input value (from 0 to the Max positive value), Vreference (the D/A output voltage range, usually 5 or 10 Vdc), and the Digital Update Time in seconds.
  19.  
  20. Limitations:
  21. 1.  Verify that the simulation update time is less than the Digital Update Time parameter
  22.  
  23. "
  24. N.2="Compound"@0x0#1,1<C>
  25. n="d2a.bmp"
  26. Ms=860,0,0,526,0,0
  27. Mb
  28. N.3="variable"@186x224<M>
  29. n=":input"
  30. N.4="sign"@630x322<M>
  31. N.5="variable"@558x322<M>
  32. n=":input"
  33. N.6="*"@702x252#3,1<M>
  34. N.7="abs"@216x259<M>
  35. N.8="variable"@216x287<M>
  36. n=":Quantization"
  37. N.9="/"@576x273<M>
  38. N.10="variable"@408x301<M>
  39. n=":Max Input Value"
  40. N.11="variable"@576x210<M>
  41. n=":Vref, volts"
  42. N.12="variable"@66x378<M>
  43. n=":N, converter bitlength"
  44. N.13="const"(8)@12x378<M>
  45. N.14="const"(1)@12x399<M>
  46. N.15="variable"@66x399<M>
  47. n=":Max Input Value"
  48. N.16="const"(1)@12x420<M>
  49. N.17="variable"@66x420<M>
  50. n=":Vref, volts"
  51. N.18="variable"@186x490<M>
  52. n=":N, converter bitlength"
  53. N.19="summingJunction"(0)@444x441<M>
  54. N.20="const"(1)@390x469<M>
  55. N.21="variable"@372x406<M>
  56. n=":Max Input Value"
  57. N.22="/"@552x434<M>
  58. N.23="variable"@612x441<M>
  59. n=":Quantization"
  60. N.24="wireLabel"@624x266<M>
  61. n="%"
  62. N.25="/"@348x259<M>
  63. N.26="int"@408x266<M>
  64. N.27="*"@474x266<M>
  65. N.28="wireLabel"@12x350<M>
  66. n="==== Parameters ===="
  67. N.29="variable"@66x441<M>
  68. n=":Digital Update Time, sec"
  69. N.30="const"(0.1)@12x441<M>
  70. N.31="wireLabel"@450x497<M>
  71. n="Compute Quantization Value"
  72. N.32="wireLabel"@498x469<M>
  73. n="2^(N-1)"
  74. N.33="sampleHold"(0)@126x252<M>
  75. N.34="pow"(2)@372x434#2,1<M>
  76. N.35="const"(2)@312x434<M>
  77. N.36="wireLabel"@18x280<M>
  78. n="Input"
  79. N.37="variable"@324x371<M>
  80. n=":Digital Update Time, sec"
  81. N.38="variable"@606x364<M>
  82. n=":Trigger"
  83. N.39="pulseTrain"(0,0.01)@522x357#2,1<M>
  84. N.40="variable"@18x224<M>
  85. n=":Trigger"
  86. G.2=1,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,
  87. I.2.o1=6.o1
  88. I.3.i1=33.o1
  89. I.4.i1=5.o1
  90. I.6.i1=11.o1
  91. I.6.i2=9.o1
  92. I.6.i3=4.o1
  93. I.7.i1=33.o1
  94. I.9.i1=27.o1
  95. I.9.i2=10.o1
  96. I.12.i1=13.o1
  97. I.15.i1=14.o1
  98. I.17.i1=16.o1
  99. I.19.i1=34.o1
  100. f19.2.i=-
  101. I.19.i2=20.o1
  102. I.22.i1=21.o1
  103. I.22.i2=19.o1
  104. I.23.i1=22.o1
  105. I.25.i1=7.o1
  106. I.25.i2=8.o1
  107. I.26.i1=25.o1
  108. I.27.i1=26.o1
  109. I.27.i2=8.o1
  110. I.29.i1=30.o1
  111. I.33.i1=40.o1
  112. I.33.i2=2.i1
  113. I.34.i1=35.o1
  114. I.34.i2=18.o1
  115. I.38.i1=39.o1
  116. I.39.i2=37.o1
  117.