I am trying to Write a digital value at DAC0 pin of teensy 3.2 MK20DX256H usisng Keil to get analog value But i get 240mV whereas i should get 3.3V according to the following formula ***Vout = Vin * (1 + DACDAT0[11:0])/4096***
# include "MK20D7.h"
SIM->SCGC2 = 1UL << 12; //Enable Clock for DAC0
DAC0->C0=0XC0 ; //Enable DAC and DACREF=3.3V
This is a simple program.please guide what is wrong in this?
View all questions in Keil forum