Can I read and write registers on the target machine?
Submitted by francois on Fri, 04/23/2010 - 19:06
For a project we are working on we need to have access to the DSP registers. What is the way to do this in VisSim?
Answers
-
Submitted by Anders89 on Fri, 04/23/2010 - 19:38.
Yes. Use the extern read and extern write blocks under VisSim/DSP > target menu. Under the Data Type drop down in the extern block properties dialog you will find <16-bit hardware register> and <32-bit hardware register>. Select the proper one for your register, then put the name of the register as given in the TI document. For example, here is some VisSim code to update the TIMERA compare register on the MSP430 F2013:
You must include the unit suffix on the hardware register. For instance, if you want to access SCI unit B RX status register, you use the name SCIRXSTB.0