久久人妻av一区二区软件 ,欧美日韩中文亚洲另类春色,国产欧美亚洲精品a,亚洲a∨无码男人的天堂,精品亚洲人伦一区二区三区,国产美女精品一区二区,欧美精品aaa久久久影院,成人精品天堂一区二区三区
首頁 新聞 > 科技 > 正文

用VHDL設(shè)計的任意頻率分頻器

Sometimes I need to generate a clock at a lower frequency than the main clock driving the FPGA. If the ratio of the frequencies is a power of 2, the logic is easy. If the ratio is an integer N, then a divide-by-N counter is only a little harder. But if the ratio isn"t an integer, a little (and I mean a little) math is required. Note that the new clock will have lots of jitter: there"s no escaping that. But it will have no drift, and for some applications that"s what counts. If you have a clock A at frequency a, and want to make a clock B at some lower frequency b (that is, b a), then something like: d = 0; forever { Wait for clock A. if (d 1) { d += (b/a); } else { d += (b/a) - 1; /* getting here means tick for clock B */ } } but comparison against zero is easier, so subtract 1 from d: d = 0; forever { Wait for clock A. if (d 0) { d += (b/a); } else { d += (b/a) - 1; /* getting here means tick for clock B */ } } want an integer representation, so multiply everything by a: d = 0; forever { Wait for clock A. if (d 0) { d += b; } else { d += b - a; /* getting here means tick for clock B */ } } For example. I just bought a bargain batch of 14.1523MHz oscillators from BG but I need to generate a 24Hz clock. So a=14152300 and b=24: d = 0; forever { Wait for clock A. if (d 0) { d += 24; } else { d += 24 - 14152300; /* getting here means tick for clock B */ } } For a hardware implementation I need to know how many bits are needed for d: here it"s 24 bits to hold the largest value (-14152300) plus one more bit for the sign. In VHDL this looks like: signal d, dInc, dN : std_logic_vector(24 downto 0); process (d) begin if (d(24) = "1") then dInc = 0000000000000000000011000; -- (24) else dInc = 1001010000000110110101100; -- (24 - 14152300) end if; end process; dN = d + dInc; process begin wait until A"event and A = "1"; d = dN; -- clock B tick whenever d(24) is zero end process;

關(guān)鍵詞: VHDL任意頻率分頻器

最近更新

關(guān)于本站 管理團隊 版權(quán)申明 網(wǎng)站地圖 聯(lián)系合作 招聘信息

Copyright © 2005-2018 創(chuàng)投網(wǎng) - www.bbcnxku.cn All rights reserved
聯(lián)系我們:33 92 950@qq.com
豫ICP備2020035879號-12

 

主站蜘蛛池模板: 成人亚洲欧美激情在线电影| 日本夜爽爽一区二区三区| 日本熟人妻中文字幕在线| 狠狠色丁香婷婷亚洲综合| 手机午夜电影神马久久| 精品国产v无码大片在线观看| 欧美丰满大爆乳波霸奶水多| 国产成人免费无庶挡视频| 国产偷国产偷高清精品| 亚洲一本大道无码av天堂| 国产av丝袜旗袍无码网站| 产精品视频在线观看免费| 亚洲成av人片一区二区蜜柚| 免费国产精品视频在线| 日韩国产综合精选| 亚洲一区二区三区丝袜| 国产美女自卫慰黄网站| 四虎永久在线精品视频免费观看| 国产av亚洲精品久久久久久| 欧亚乱熟女一区二区三区在线| 99热热久久这里只有精品68| 亚洲区欧美区综合区自拍区| 国产精品推荐手机在线| 欧美人妻体内射射| 伊伊人成亚洲综合人网香| 四虎国产精品永久地址入口| 国产超高清麻豆精品传媒麻豆精品| 在线观看无码av网址| 西西人体大胆www44he七| 精品国精品无码自拍自在线| 国产成人无码va在线播放| 99热精国产这里只有精品| av无码国产精品麻豆| 人妻有码精品视频在线| 精品国产一区二区三区四区色| 久久久久国产精品麻豆ar影院| 亚洲乱码日产精品b| 婷婷亚洲天堂影院| 国产亚洲精品久久久一区| 久久av无码aⅴ高潮av喷吹 | 国产成人av综合久久|