00001 // 00002 // JTAG.H 00003 // 00004 // Low level JTAG access code. Handles all clocking of data in and 00005 // out of target hardware. 00006 // 00007 // Copyright (c) 2002, Jason Riffel - TotalEmbedded LLC. 00008 // All rights reserved. 00009 // 00010 // Redistribution and use in source and binary forms, with or without 00011 // modification, are permitted provided that the following conditions 00012 // are met: 00013 // 00014 // Redistributions of source code must retain the above copyright 00015 // notice, this list of conditions and the following disclaimer. 00016 // 00017 // Redistributions in binary form must reproduce the above copyright 00018 // notice, this list of conditions and the following disclaimer in 00019 // the documentation and/or other materials provided with the 00020 // distribution. 00021 // 00022 // Neither the name of TotalEmbedded nor the names of its 00023 // contributors may be used to endorse or promote products derived 00024 // from this software without specific prior written permission. 00025 // 00026 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 00027 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 00028 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 00029 // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 00030 // COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 00031 // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 00032 // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00033 // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 00034 // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 00035 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 00036 // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 00037 // POSSIBILITY OF SUCH DAMAGE. 00038 // 00039 00040 #ifndef dJTAG_H 00041 #define dJTAG_H 00042 00043 // 00044 // PROTOTYPES 00045 // 00046 void fJTAG_Init (void); 00047 unsigned int fJTAG_Data (unsigned int ui_data_out); 00048 unsigned char fJTAG_Instruction(unsigned char uc_data_out); 00049 00050 // 00051 // DEFINES 00052 // 00053 #define dJTAG_REGISTER_EXTEST 0x00 00054 #define dJTAG_REGISTER_IDCODE 0x01 00055 #define dJTAG_REGISTER_SAMPLE 0x02 00056 #define dJTAG_REGISTER_IMPCODE 0x03 00057 #define dJTAG_REGISTER_ADDRESS 0x08 00058 #define dJTAG_REGISTER_DATA 0x09 00059 #define dJTAG_REGISTER_CONTROL 0x0A 00060 #define dJTAG_REGISTER_ALL 0x0B 00061 #define dJTAG_REGISTER_EJTAG_BOOT 0x0C 00062 #define dJTAG_REGISTER_NORMAL_BOOT 0x0D 00063 #define dJTAG_REGISTER_FASTDATA 0x0E 00064 #define dJTAG_REGISTER_DBTX 0x1C 00065 #define dJTAG_REGISTER_EJWATCH 0x1C 00066 #define dJTAG_REGISTER_DBDX 0x1D 00067 #define dJTAG_REGISTER_BYPASS 0x1F 00068 00069 #endif // #ifndef dJTAG_H
1.5.6