Example program for EVAL-AD1234.

Dependencies:   ADE120x

Committer:
mlambe
Date:
Thu Oct 03 15:06:13 2019 +0000
Revision:
2:2ebdd709cec0
Parent:
0:4b7ec1ec0c7a
Child:
5:975c3cbc8b55
Added interrupts for DOUT pins

Who changed what in which revision?

UserRevisionLine numberNew contents of line
malavikasaji 0:4b7ec1ec0c7a 1 Evaluation Boards/Products Supported
malavikasaji 0:4b7ec1ec0c7a 2 ------------------------------------
mlambe 2:2ebdd709cec0 3 EVAL-AD1202EBZ (ADE1202)
mlambe 2:2ebdd709cec0 4
malavikasaji 0:4b7ec1ec0c7a 5
malavikasaji 0:4b7ec1ec0c7a 6 Overview
malavikasaji 0:4b7ec1ec0c7a 7 --------
mlambe 2:2ebdd709cec0 8 These code files provide drivers to interface with ADE1202 and communicate with
mlambe 2:2ebdd709cec0 9 EVAL-ADE1202EBZ evaluation boards. This code was developed and tested on SDP-K1 controller board
malavikasaji 0:4b7ec1ec0c7a 10 https://os.mbed.com/platforms/SDP_K1/.
malavikasaji 0:4b7ec1ec0c7a 11
mlambe 2:2ebdd709cec0 12 Product details: https://www.analog.com/en/products/ad1202.html
mlambe 2:2ebdd709cec0 13
mlambe 2:2ebdd709cec0 14 Eval board details: https://wiki.analog.com/resources/eval/user-guides/ade120x
malavikasaji 0:4b7ec1ec0c7a 15
malavikasaji 0:4b7ec1ec0c7a 16
malavikasaji 0:4b7ec1ec0c7a 17 Hardware Setup
malavikasaji 0:4b7ec1ec0c7a 18 --------------
mlambe 2:2ebdd709cec0 19 Required: SDP-K1, EVAL-ADE1202, USB cable
mlambe 2:2ebdd709cec0 20
mlambe 2:2ebdd709cec0 21 Plug in the EVAL-AD1201EBZ board to SDP-K1 board using the SDP connector
malavikasaji 0:4b7ec1ec0c7a 22 Connect SDP-K1 board to the PC using the USB cable.
malavikasaji 0:4b7ec1ec0c7a 23
mlambe 2:2ebdd709cec0 24 Code Explanation
mlambe 2:2ebdd709cec0 25 ------------------
mlambe 2:2ebdd709cec0 26 The example program configures device U0 on EVAL-ADE1202EBZ. DOUT1 and DOUT2
mlambe 2:2ebdd709cec0 27 are connected to interrupt pins on the SDP-K1. The UART interfeace transmit data
mlambe 2:2ebdd709cec0 28 back to the PC.
malavikasaji 0:4b7ec1ec0c7a 29
malavikasaji 0:4b7ec1ec0c7a 30 How to Get Started
malavikasaji 0:4b7ec1ec0c7a 31 ------------------
malavikasaji 0:4b7ec1ec0c7a 32 Open Mbed online compiler. https://ide.mbed.com/compiler
mlambe 2:2ebdd709cec0 33 Import Code into compiler from here: https://os.mbed.com/teams/AnalogDevices/code/EVAL-AD1201/
malavikasaji 0:4b7ec1ec0c7a 34 instructions on how to import code are here: https://os.mbed.com/docs/mbed-os/v5.12/tools/importing-code.html
malavikasaji 0:4b7ec1ec0c7a 35 Compile code. Drag and drop binary into SDP-K1 controller board. instructions
malavikasaji 0:4b7ec1ec0c7a 36 here: https://os.mbed.com/docs/mbed-os/v5.12/tools/getting-your-program-on-your-board.html
mlambe 2:2ebdd709cec0 37 Open Tera Term, select 230400 baud rate, and the applicable COM port to see the
malavikasaji 0:4b7ec1ec0c7a 38 list of options.
malavikasaji 0:4b7ec1ec0c7a 39
malavikasaji 0:4b7ec1ec0c7a 40 A detailed user guide on how to use SDP-K1 board on Mbed platform is available
malavikasaji 0:4b7ec1ec0c7a 41 here: <<Mbed user guide>>
malavikasaji 0:4b7ec1ec0c7a 42
malavikasaji 0:4b7ec1ec0c7a 43
malavikasaji 0:4b7ec1ec0c7a 44 Notes
malavikasaji 0:4b7ec1ec0c7a 45 -----
malavikasaji 0:4b7ec1ec0c7a 46 If using Win 7, install serial drivers for Mbed. https://os.mbed.com/docs/mbed-os/v5.12/tutorials/windows-serial-driver.html
malavikasaji 0:4b7ec1ec0c7a 47 A detailed user guide on SDP-K1 controller board is available here https://www.analog.com/en/design-center/evaluation-hardware-and-software/evaluation-boards-kits/SDP-K1.html.
malavikasaji 0:4b7ec1ec0c7a 48
malavikasaji 0:4b7ec1ec0c7a 49
malavikasaji 0:4b7ec1ec0c7a 50 License
malavikasaji 0:4b7ec1ec0c7a 51 -------
malavikasaji 0:4b7ec1ec0c7a 52 Copyright (c) 2019 Analog Devices, Inc. All rights reserved.
malavikasaji 0:4b7ec1ec0c7a 53
malavikasaji 0:4b7ec1ec0c7a 54 Redistribution and use in source and binary forms, with or without modification,
malavikasaji 0:4b7ec1ec0c7a 55 are permitted provided that the following conditions are met:
malavikasaji 0:4b7ec1ec0c7a 56 - Redistributions of source code must retain the above copyright notice,
malavikasaji 0:4b7ec1ec0c7a 57 this list of conditions and the following disclaimer.
malavikasaji 0:4b7ec1ec0c7a 58 - Redistributions in binary form must reproduce the above copyright notice,
malavikasaji 0:4b7ec1ec0c7a 59 this list of conditions and the following disclaimer in the documentation
malavikasaji 0:4b7ec1ec0c7a 60 and/or other materials provided with the distribution.
malavikasaji 0:4b7ec1ec0c7a 61 - Modified versions of the software must be conspicuously marked as such.
malavikasaji 0:4b7ec1ec0c7a 62 - This software is licensed solely and exclusively for use with processors/products
malavikasaji 0:4b7ec1ec0c7a 63 manufactured by or for Analog Devices, Inc.
malavikasaji 0:4b7ec1ec0c7a 64 - This software may not be combined or merged with other code in any manner
malavikasaji 0:4b7ec1ec0c7a 65 that would cause the software to become subject to terms and conditions which
malavikasaji 0:4b7ec1ec0c7a 66 differ from those listed here.
malavikasaji 0:4b7ec1ec0c7a 67 - Neither the name of Analog Devices, Inc. nor the names of its contributors
malavikasaji 0:4b7ec1ec0c7a 68 may be used to endorse or promote products derived from this software without
malavikasaji 0:4b7ec1ec0c7a 69 specific prior written permission.
malavikasaji 0:4b7ec1ec0c7a 70 - The use of this software may or may not infringe the patent rights of one or
malavikasaji 0:4b7ec1ec0c7a 71 more patent holders. This license does not release you from the requirement
malavikasaji 0:4b7ec1ec0c7a 72 that you obtain separate licenses from these patent holders to use this software.
malavikasaji 0:4b7ec1ec0c7a 73
malavikasaji 0:4b7ec1ec0c7a 74 THIS SOFTWARE IS PROVIDED BY ANALOG DEVICES, INC. AND CONTRIBUTORS "AS IS" AND
malavikasaji 0:4b7ec1ec0c7a 75 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, NON-INFRINGEMENT,
malavikasaji 0:4b7ec1ec0c7a 76 TITLE, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
malavikasaji 0:4b7ec1ec0c7a 77 NO EVENT SHALL ANALOG DEVICES, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
malavikasaji 0:4b7ec1ec0c7a 78 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, PUNITIVE OR CONSEQUENTIAL DAMAGES
malavikasaji 0:4b7ec1ec0c7a 79 (INCLUDING, BUT NOT LIMITED TO, DAMAGES ARISING OUT OF CLAIMS OF INTELLECTUAL
malavikasaji 0:4b7ec1ec0c7a 80 PROPERTY RIGHTS INFRINGEMENT; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
malavikasaji 0:4b7ec1ec0c7a 81 OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
malavikasaji 0:4b7ec1ec0c7a 82 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
malavikasaji 0:4b7ec1ec0c7a 83 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
malavikasaji 0:4b7ec1ec0c7a 84 EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
malavikasaji 0:4b7ec1ec0c7a 85
malavikasaji 0:4b7ec1ec0c7a 86 2019-01-10-7CBSD SLA