This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430 peripheral I/O simulation

Other Parts Discussed in Thread: MSP430F5437

I'm an EE student and I'm building a project using msp430f5437 in IAR Embedded Workbench IDE tool.

I finished writing the project code and I still don't have the JTAG and the board for debugging it, So I started debugging using the IAR simulator.

I encountered two problems:

1. I wrote a code setting a MCLK system clock using an external crystal oscillator. 

    When I select the MCLK pin to be MCLK output I don't get any changes in the pin output, it remains 0x00. 

    Can I simulate a crystal based clock without having hardware with an actual crystal connected?

2. I read in different forums that there is no way to run a msp430 peripherals simulation using IAR.

    I read in the IAR user guide that such a simulation can be done using macro files. 

    Are there any ready macro files I can find on line? Is there an alternative way of running a msp430 peripherals simulation?

 

Thanks in advance!

Yossi.   

  • The IAR simulator mostly simulates the MCU, but only a small part of the hardware.
    Timers are supported (at least count and compare seem to work, from what I read in other threads).
    A crystal, however, is a different thing. best case, the simulator simulates what happens if you don't have a crystal attached: an oscillator fault (and MCLK stays on DCO)

    About the macro files, it might be possible to simulate some external events, such as I/O input, if the simulator knows when what shall happen.
    However, I don't have any 1st person experience with IAR and never read about this here in the forum.

    In any case, simulation of a CPU (which is shared across all MSPs in just three variations) is easy, but simulation of specific hardware, which is different or at least combined differently for every single MSP, is difficult. And needs individual programming for each device. And is therefore most likely too much effort.

**Attention** This is a public forum