many PICs do not have hardware DAC. It is only when you move to newer and higher end chips, you get DACs.
however, many PICs have a comparator reference voltage generator for its comparators. Those generators typically have a resolution of 4 - 5 bits. Some of them can have their output (CVref) routed to an output pin. viola! you have a 4-bit dac.
here is an example of generating a ramp on 16F886.
(原文件名:16f886 4-bit dac.PNG)
now, this is nothing to write home about but if you are in need of some quick dac, it may work for you.
enjoy.
many PICs have a comparator reference voltage generator for its comparators. Those generators typically have a resolution of 4 - 5 bits. Some of them can have their output (CVref) routed to an output pin. viola! you have a 4-bit dac.
"许多PIC的比较器都有参考电压发生器,这些发生器通常都有4-5位的分辨.这其中的一些型号可以输出到(CVREF)引脚. 这样你就有一个4位的DAC了."
一周热门 更多>