Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Pic18f97j60 interfaced with ad5781

Status
Not open for further replies.

tommy92

Newbie level 4
Joined
Feb 8, 2013
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,319
I am using PIC 18 series(8 BIT) micro controller in my project. We are interfacing this microcontroller with DAC-AD5781(18 BIT). I don't know how to write the coding for this (in C language). Can you please help me
with coding.

Protocol: SPI
DAC output: 0V to 10V
 

Simply look at the datasheet. The PIC has an SPI interface, as has the AD5781. The AD5781 wants 24 bits of data so simply send it as three bytes from the PIC. Don't use framed mode on the PIC - you need to keep the SYNC signal low until you have sent all three bytes so control it with an I/O pin driven by software.

Keith.
 

I tried in the same manner what you said.I had separated 18 BIT's of data in to 2Byte + 2 BIT data ,I am having doubt that how to convert that 2 BIT data to 8 BIT data .Is there is any appending formulae or procedures for particular PIC 18 series.Can you please help me with coding or tutorial web links like that??
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top