⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 debugchain.h

📁 ARM核的边界扫描(JTAG)的实现,此代码在s3c2400上测试通过
💻 H
字号:
//////////////////////////////////////////////////////////////////////////////
// DebugChain                                                               //
//////////////////////////////////////////////////////////////////////////////
class DebugChain : public Chain
{
	public:
		unsigned data : 32;
		unsigned dden : 1;			// INTEST: capture dden status, EXTEST: 1=write, 0=read
		unsigned wptandbkpt : 1;	// in case of watchpoint, this bit returns 1 if also a breakpoint occurred
		unsigned sysspeed : 1;		// synchronize clock. returns cause of debug mode: 0=breakpoint, 1=watchpoint
		unsigned instruction : 32;	// reversed

		void Select() { JTAG::Command(INTEST); JTAG::Chain(DEBUG_CHAIN); }

		unsigned int Exec(unsigned int instruction, int systemspeed, int data = 0)
		{
			this->data = data;
			this->dden = 0;
			this->wptandbkpt = 0;
			this->sysspeed = systemspeed;
			this->instruction = Reverse(instruction);
			Select();
			JTAG::Transfer(this);
			return this->data;
		}
};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -