usb_desc_rom.v 7.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226
  1. //-----------------------------------------------------------------
  2. // USB Serial Port
  3. // V0.1
  4. // Ultra-Embedded.com
  5. // Copyright 2020
  6. //
  7. // Email: admin@ultra-embedded.com
  8. //
  9. // License: LGPL
  10. //-----------------------------------------------------------------
  11. //
  12. // This source file may be used and distributed without
  13. // restriction provided that this copyright statement is not
  14. // removed from the file and that any derivative work contains
  15. // the original copyright notice and the associated disclaimer.
  16. //
  17. // This source file is free software; you can redistribute it
  18. // and/or modify it under the terms of the GNU Lesser General
  19. // Public License as published by the Free Software Foundation;
  20. // either version 2.1 of the License, or (at your option) any
  21. // later version.
  22. //
  23. // This source is distributed in the hope that it will be
  24. // useful, but WITHOUT ANY WARRANTY; without even the implied
  25. // warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  26. // PURPOSE. See the GNU Lesser General Public License for more
  27. // details.
  28. //
  29. // You should have received a copy of the GNU Lesser General
  30. // Public License along with this source; if not, write to the
  31. // Free Software Foundation, Inc., 59 Temple Place, Suite 330,
  32. // Boston, MA 02111-1307 USA
  33. //-----------------------------------------------------------------
  34. //-----------------------------------------------------------------
  35. // Generated File
  36. //-----------------------------------------------------------------
  37. module usb_desc_rom
  38. (
  39. input hs_i,
  40. input [7:0] addr_i,
  41. output [7:0] data_o
  42. );
  43. reg [7:0] desc_rom_r;
  44. always @ *
  45. begin
  46. case (addr_i)
  47. 8'd0: desc_rom_r = 8'h12;
  48. 8'd1: desc_rom_r = 8'h01;
  49. 8'd2: desc_rom_r = 8'h00;
  50. 8'd3: desc_rom_r = 8'h02;
  51. 8'd4: desc_rom_r = 8'h02;
  52. 8'd5: desc_rom_r = 8'h00;
  53. 8'd6: desc_rom_r = 8'h00;
  54. 8'd7: desc_rom_r = hs_i ? 8'h40 : 8'h08;
  55. 8'd8: desc_rom_r = 8'h50; // VID_L
  56. 8'd9: desc_rom_r = 8'h1d; // VID_H
  57. 8'd10: desc_rom_r = 8'h49; // PID_L
  58. 8'd11: desc_rom_r = 8'h61; // PID_H
  59. 8'd12: desc_rom_r = 8'h01;
  60. 8'd13: desc_rom_r = 8'h01;
  61. 8'd14: desc_rom_r = 8'h00;
  62. 8'd15: desc_rom_r = 8'h00;
  63. 8'd16: desc_rom_r = 8'h00;
  64. 8'd17: desc_rom_r = 8'h01;
  65. 8'd18: desc_rom_r = 8'h09;
  66. 8'd19: desc_rom_r = 8'h02;
  67. 8'd20: desc_rom_r = 8'h43;
  68. 8'd21: desc_rom_r = 8'h00;
  69. 8'd22: desc_rom_r = 8'h02;
  70. 8'd23: desc_rom_r = 8'h01;
  71. 8'd24: desc_rom_r = 8'h00;
  72. 8'd25: desc_rom_r = 8'h80;
  73. 8'd26: desc_rom_r = 8'h32;
  74. 8'd27: desc_rom_r = 8'h09;
  75. 8'd28: desc_rom_r = 8'h04;
  76. 8'd29: desc_rom_r = 8'h00;
  77. 8'd30: desc_rom_r = 8'h00;
  78. 8'd31: desc_rom_r = 8'h01;
  79. 8'd32: desc_rom_r = 8'h02;
  80. 8'd33: desc_rom_r = 8'h02;
  81. 8'd34: desc_rom_r = 8'h01;
  82. 8'd35: desc_rom_r = 8'h00;
  83. 8'd36: desc_rom_r = 8'h05;
  84. 8'd37: desc_rom_r = 8'h24;
  85. 8'd38: desc_rom_r = 8'h00;
  86. 8'd39: desc_rom_r = 8'h10;
  87. 8'd40: desc_rom_r = 8'h01;
  88. 8'd41: desc_rom_r = 8'h05;
  89. 8'd42: desc_rom_r = 8'h24;
  90. 8'd43: desc_rom_r = 8'h01;
  91. 8'd44: desc_rom_r = 8'h03;
  92. 8'd45: desc_rom_r = 8'h01;
  93. 8'd46: desc_rom_r = 8'h04;
  94. 8'd47: desc_rom_r = 8'h24;
  95. 8'd48: desc_rom_r = 8'h02;
  96. 8'd49: desc_rom_r = 8'h06;
  97. 8'd50: desc_rom_r = 8'h05;
  98. 8'd51: desc_rom_r = 8'h24;
  99. 8'd52: desc_rom_r = 8'h06;
  100. 8'd53: desc_rom_r = 8'h00;
  101. 8'd54: desc_rom_r = 8'h01;
  102. 8'd55: desc_rom_r = 8'h07;
  103. 8'd56: desc_rom_r = 8'h05;
  104. 8'd57: desc_rom_r = 8'h83;
  105. 8'd58: desc_rom_r = 8'h03;
  106. 8'd59: desc_rom_r = 8'h40;
  107. 8'd60: desc_rom_r = 8'h00;
  108. 8'd61: desc_rom_r = 8'h02;
  109. 8'd62: desc_rom_r = 8'h09;
  110. 8'd63: desc_rom_r = 8'h04;
  111. 8'd64: desc_rom_r = 8'h01;
  112. 8'd65: desc_rom_r = 8'h00;
  113. 8'd66: desc_rom_r = 8'h02;
  114. 8'd67: desc_rom_r = 8'h0a;
  115. 8'd68: desc_rom_r = 8'h00;
  116. 8'd69: desc_rom_r = 8'h00;
  117. 8'd70: desc_rom_r = 8'h00;
  118. 8'd71: desc_rom_r = 8'h07;
  119. 8'd72: desc_rom_r = 8'h05;
  120. 8'd73: desc_rom_r = 8'h01;
  121. 8'd74: desc_rom_r = 8'h02;
  122. 8'd75: desc_rom_r = hs_i ? 8'h00 : 8'h40;
  123. 8'd76: desc_rom_r = hs_i ? 8'h02 : 8'h00;
  124. 8'd77: desc_rom_r = 8'h00;
  125. 8'd78: desc_rom_r = 8'h07;
  126. 8'd79: desc_rom_r = 8'h05;
  127. 8'd80: desc_rom_r = 8'h82;
  128. 8'd81: desc_rom_r = 8'h02;
  129. 8'd82: desc_rom_r = hs_i ? 8'h00 : 8'h40;
  130. 8'd83: desc_rom_r = hs_i ? 8'h02 : 8'h00;
  131. 8'd84: desc_rom_r = 8'h00;
  132. 8'd85: desc_rom_r = 8'h04;
  133. 8'd86: desc_rom_r = 8'h03;
  134. 8'd87: desc_rom_r = 8'h09;
  135. 8'd88: desc_rom_r = 8'h04;
  136. 8'd89: desc_rom_r = 8'h1e;
  137. 8'd90: desc_rom_r = 8'h03;
  138. 8'd91: desc_rom_r = 8'h55;
  139. 8'd92: desc_rom_r = 8'h00;
  140. 8'd93: desc_rom_r = 8'h4c;
  141. 8'd94: desc_rom_r = 8'h00;
  142. 8'd95: desc_rom_r = 8'h54;
  143. 8'd96: desc_rom_r = 8'h00;
  144. 8'd97: desc_rom_r = 8'h52;
  145. 8'd98: desc_rom_r = 8'h00;
  146. 8'd99: desc_rom_r = 8'h41;
  147. 8'd100: desc_rom_r = 8'h00;
  148. 8'd101: desc_rom_r = 8'h2d;
  149. 8'd102: desc_rom_r = 8'h00;
  150. 8'd103: desc_rom_r = 8'h45;
  151. 8'd104: desc_rom_r = 8'h00;
  152. 8'd105: desc_rom_r = 8'h4d;
  153. 8'd106: desc_rom_r = 8'h00;
  154. 8'd107: desc_rom_r = 8'h42;
  155. 8'd108: desc_rom_r = 8'h00;
  156. 8'd109: desc_rom_r = 8'h45;
  157. 8'd110: desc_rom_r = 8'h00;
  158. 8'd111: desc_rom_r = 8'h44;
  159. 8'd112: desc_rom_r = 8'h00;
  160. 8'd113: desc_rom_r = 8'h44;
  161. 8'd114: desc_rom_r = 8'h00;
  162. 8'd115: desc_rom_r = 8'h45;
  163. 8'd116: desc_rom_r = 8'h00;
  164. 8'd117: desc_rom_r = 8'h44;
  165. 8'd118: desc_rom_r = 8'h00;
  166. 8'd119: desc_rom_r = 8'h1e;
  167. 8'd120: desc_rom_r = 8'h03;
  168. 8'd121: desc_rom_r = 8'h55;
  169. 8'd122: desc_rom_r = 8'h00;
  170. 8'd123: desc_rom_r = 8'h53;
  171. 8'd124: desc_rom_r = 8'h00;
  172. 8'd125: desc_rom_r = 8'h42;
  173. 8'd126: desc_rom_r = 8'h00;
  174. 8'd127: desc_rom_r = 8'h20;
  175. 8'd128: desc_rom_r = 8'h00;
  176. 8'd129: desc_rom_r = 8'h44;
  177. 8'd130: desc_rom_r = 8'h00;
  178. 8'd131: desc_rom_r = 8'h45;
  179. 8'd132: desc_rom_r = 8'h00;
  180. 8'd133: desc_rom_r = 8'h4d;
  181. 8'd134: desc_rom_r = 8'h00;
  182. 8'd135: desc_rom_r = 8'h4f;
  183. 8'd136: desc_rom_r = 8'h00;
  184. 8'd137: desc_rom_r = 8'h20;
  185. 8'd138: desc_rom_r = 8'h00;
  186. 8'd139: desc_rom_r = 8'h20;
  187. 8'd140: desc_rom_r = 8'h00;
  188. 8'd141: desc_rom_r = 8'h20;
  189. 8'd142: desc_rom_r = 8'h00;
  190. 8'd143: desc_rom_r = 8'h20;
  191. 8'd144: desc_rom_r = 8'h00;
  192. 8'd145: desc_rom_r = 8'h20;
  193. 8'd146: desc_rom_r = 8'h00;
  194. 8'd147: desc_rom_r = 8'h20;
  195. 8'd148: desc_rom_r = 8'h00;
  196. 8'd149: desc_rom_r = 8'h0e;
  197. 8'd150: desc_rom_r = 8'h03;
  198. 8'd151: desc_rom_r = 8'h30;
  199. 8'd152: desc_rom_r = 8'h00;
  200. 8'd153: desc_rom_r = 8'h30;
  201. 8'd154: desc_rom_r = 8'h00;
  202. 8'd155: desc_rom_r = 8'h30;
  203. 8'd156: desc_rom_r = 8'h00;
  204. 8'd157: desc_rom_r = 8'h30;
  205. 8'd158: desc_rom_r = 8'h00;
  206. 8'd159: desc_rom_r = 8'h30;
  207. 8'd160: desc_rom_r = 8'h00;
  208. 8'd161: desc_rom_r = 8'h30;
  209. 8'd162: desc_rom_r = 8'h00;
  210. 8'd163: desc_rom_r = 8'h00;
  211. 8'd164: desc_rom_r = 8'hc2;
  212. 8'd165: desc_rom_r = 8'h01;
  213. 8'd166: desc_rom_r = 8'h00;
  214. 8'd167: desc_rom_r = 8'h00;
  215. 8'd168: desc_rom_r = 8'h00;
  216. 8'd169: desc_rom_r = 8'h08;
  217. default: desc_rom_r = 8'h00;
  218. endcase
  219. end
  220. assign data_o = desc_rom_r;
  221. endmodule