microkar
Joined: 26 Jan 2008 Posts: 1
|
26 Jan 2008 14:27 interfacing dac to 8051 |
|
|
|
|
Hi everyone I am Karthik, looking out for a project which involves Interfacing 8051 with RTC and DAC to get a user defined random waveform.
I had a lab expt in 7th sem where 8051 was interfaced to get a sine wave.
But now I want to display a random user defined wave where signal may be a mixture of sine, square, ramp or any other shape and also it should have a definite user defined time interval in the program.
Can anyone tell me how to go about it?
|
|
laktronics
Joined: 06 Jan 2007 Posts: 945 Helped: 156
|
27 Jan 2008 7:19 dac interfacing with 8051 |
|
|
|
|
Hi,
You can probably use a parallel EEPROM into which the user defined function may be stored. Use a chain of counters to generate the EEPROM address. Connect the data out of the EEPROM to a DAC to generate an analog output.
The micro should have control to reset the counter, serial incrementing of the counter and to write data to EEPROM data bus, which is also connected to the DAC data input.
Inorder to load the user defined function table into the EEPROM, the micro will first reset the counter, place the data on to EEPROM data bus and issue a wr pulse to EEPROM and wait in a wr delay loop. Next, increment the counter and write the next data sample.
While running the function, after loading the table values into EEPROM, reset the counter, put the EEPROM in RD mode, incremet the counter at regular intervals from reset. If you want to make the function a repetitive time function, make a facility to switch the counter clock input to an adjutable clock generator.
Regards,
Laktronics
|
|