Jump to content
43oh

simple asm code example in energia?


Recommended Posts

Is it possible to use asm in energia? I would like to see some short and simple example of how to use it and compile it.

I found THIS very nice and useful guide to make it work in code composer studio, but unfortunalley I could not put this code it to work in Energia, and I dont have CCS.. (I downloaded the version 7, but for some reason it did not install, just give errors, tried in 2 pcs)

In the other hand, I found something about asm in Energia here in the forum, but is was intended for a more complex stuff, and I could not put it to work, too..

Could someone give me a light? I just want to do something very simple like blink a red led, then a green led, like in the example in the link, just to know how to handle asm in msp430. But in Energia, not CCS.. 

I am using the msp430g2553 launchpad. I have also a g2452 chip..

ps. my final objective is to make something like THIS in msp430 (the guy provides the emulator asm code for the atmel chip, I guess it would be possible to port it to msp, if you know asm and study the chips very well.... once tha arm emulator runs, I guess the rest will work...)

Link to post
Share on other sites

Can I ask a related question?  Recently I posted here about an alternate G2553 BSL entry mechanism that I had developed and posted on Github.  This involves a very short code segment buried in INFOA in between the calibration data blocks.  There are two requirements for it to work.  The first is that the Reset vector at 0xFFFE must point to 0x10C0, which is where the boot entry code resides at the beginning of INFOA.  The second is that the firmware which will be running on the chip after flashing must begin at 0xC000, which is the beginning of MAIN memory.  The code in INFOA tests whether USB is connected, and if not it BRanches to 0xC000.  So the application must begin there, and it must be an instruction, not .dw stuff.

This is easy in assembler, but it has occurred to me that the two requirements might not be easy, or even possible, to satisfy in plain C or in Energia, about which I know very little.  What do you think?

 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...