Jump to content

adding C codes in asm application


anakin
 Share

Recommended Posts

Hi

I'm doing some tests using the application sm_example2_v1b that is coded in ASM.

The apps for me is quite difficult also because i'M not able to code in asm but quite well in C.

question: is it possible to add some lines in C inside the code in asm? in which way?

Do I have to create a new file called , for example main.c and code inside or I have to do in other way?

thank you for your precious help!

Anakin

Link to comment
Share on other sites

Hi,

check out sm_c_example2 :)

http://svnmios.midibox.org/listing.php?repname=svn.mios&path=%2Ftrunk%2Fapps%2Fexamples%2Fsm_c_example2%2F

question: is it possible to add some lines in C inside the code in asm? in which way?

No, it's only possible to add assembly code to C routines (but it's very tricky and not straightforward)

Mostly it's easier to place assembly functions in a separate module, and to call the assembly code from C - this is demonstrated in sm_c_example2

Best Regards, Thorsten.

Link to comment
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.

Loading...
 Share

×
×
  • Create New...