6

Does QEMU support Cortex M4 emulation? Also the controller(hardware) I am trying to emulate is bare metal implementation ( FreeRTOS ), is it possible to implement such scenario in QEMU? or a OS image is must?

Edit: The better question would be does QEMU support Cortex-M4 emulation with STM32.

2
  • 1
    Hi Chandrika, you seem to be asking a lot of questions inside your question. Try and be more specific, have a look at the Asking page to get more tips on how to ask the best possible question to get the best possible answer.
    – angelofdev
    Feb 7, 2019 at 13:04
  • 1
    Thank you for your comment. I understand now I should have asked more precise question. I would have edited the question but the answer given by harrymc is really good and it would not make sense if i change the question. I have added the edit and keep in mind for future thanks :) Mar 13, 2019 at 10:30

2 Answers 2

6

QEMU Documentation/Platforms/ARM says that it does:

As well as the more common "A-profile" CPUs (which have MMUs and will run Linux) we also support the Cortex-M3 and Cortex-M4 "M-profile" CPUs (which are microcontrollers used in very embedded boards. We only have two boards which use the M-profile CPU at the moment: "lm3s811evb" and "lm3s6965evb" (which are both TI Stellaris evaluation boards).

If you are looking to run a program without ISO, this requires some work. See for a similar case the article Hello world for bare metal ARM using QEMU .

1
  • Thank you this is great. I'm quite new to this technology. I read that QEMU supports cortex M4 but have only TI boards as mentioned above. I'm working on ST boards with cortex M4 processor. I'm not sure if that is problem and if its supported? Feb 8, 2019 at 13:09
2

The above answer was quite helpful to me. Moving on to precisely answer my own question, I did some digging throughout my literature survey and found cortex m4 is supported by QEMU but with TI Stellaris board. If you are implementing with this board and bare metal then all you have to do is write some startup ,linker code and convert to .bin (pass as argument for kernel in QEMU command) If not, like in my case, I had to build a "custom machine" for STM32 , implementing the peripherals and memory.Explore one such example here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .