element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products & Partners
    Products & Partners
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
    About the element14 Community
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      •  Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Community Hub
Community Hub
Member's Forum spi interfacing between ad7796 and atmega 16
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Leaderboard
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Community Hub to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Suggested Answer
  • Replies 4 replies
  • Answers 1 answer
  • Subscribers 631 subscribers
  • Views 751 views
  • Users 0 members are here
Related

spi interfacing between ad7796 and atmega 16

e14 Contributor
e14 Contributor over 13 years ago

hai,

 

     i have to interface  ad7796 ic which is Low Power, 16-/24-Bit Sigma-Delta ADC for Bridge Sensors to ATmega 16. The interface is with spi protocol.i am not strong in ATmega. request help from others.

  • Sign in to reply
  • Cancel
  • e14 Contributor
    0 e14 Contributor over 13 years ago in reply to michaelkellett

    thankyou sir

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • michaelkellett
    0 michaelkellett over 13 years ago in reply to e14 Contributor

    Step 1:

    Read the AD7796 data sheet and look carefully at the timing diagrams and digital interface description on pages 17,18 and 19

    Read the SPI section of the atMega16 data (page 135 onwards)

    Step 2:

    Work out what you need to do to the AD7796 registers to make it work the way you want (you'll need to read the whoel data sheet carefully).

    Step 3:

    High level description of your code

    Step 4:

    Work out the C functions you will need like write byte to spi, read byte from spi, write x bytes to register y of AD7796, read x bytes from register y of AD7796

    Step 5:

    Write the code for step 4 and a set of little test functions.(You'll need a debugger to see what results your tests give).

     

    HINT: The atMega16 SPI port leaves control of the SS (slave select) of the SPI port to your code - this is good because as you will see in the AD7796 description it uses SS to tell it when commands start and stop.

     

    If you have any specific problems with any of these steps then ask again.

     

    Michael Kellett

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • e14 Contributor
    0 e14 Contributor over 13 years ago in reply to michaelkellett

    Sir,

          I doing my main project. I have to make the hardware setup for sensing motion of human body. The motion is sensed by using two strain gauges. The output of the strain gauge is connected to the  input of ad7796. ad7796 is a Low Power, 16-/24-Bit Sigma-Delta ADC for Bridge Sensors.The output from the ad7796 is connected to the atmega 16. The interfacing of ad7796 and atmega 16 is by using spi protocol. For that i have to write code for spi in embedded C.  Sir i need help.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • michaelkellett
    0 michaelkellett over 13 years ago

    You need to tell us a bit more about what you are trying to do and where you are stuck.

    Are you coding in C or assembler.

    Do you have a hardware set up to test.

    Is it  a commercial project.

    Do you have a specification for the code you need to write ot for the performance of the finished article.

     

    Michael Kellett

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2026 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube