void CIntelHexRec::InitData(unsigned char Size, unsigned short Addr, unsigned char* pData)
{
	eAssert(pData);
	m_Type = cHexTypeData;
	m_Size = Size;
	m_Addr = Addr;
	CopyMemory(m_Data, pData, Size);
}
unsigned long CIntelHexRec::GetExtAddr()
{
	eAssert(m_Size == 2);
	unsigned long pc = 0;
	switch(m_Type)
	{
	case cHexTypeExtLinearAddr:
		pc |= m_Data[0] << 24;
		pc |= m_Data[1] << 16;
		return pc;
	case cHexTypeExtSegmentAddr:
		pc |= m_Data[0] << 12;
		pc |= m_Data[1] << 4;
		return pc;
	default:
		eTrace1("m_Type = %d", m_Type);
		throw DEFileInvalidHexFormat();
	}
}
IntelHexImage::~IntelHexImage()
{
	eAssert(_file == NULL);
}