Inline assembly for PSoC5

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
JOLO_264146
Level 4
Level 4
First like received Welcome!

Hi,

   

question is in the subject: is it possible write inline assembly for PSoC5? For PSoC3 is possible; there are several post about and it appears in documentation. But I found nothing about PSoC5

   

Thanks

0 Likes
4 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

The assembly for an ARM Cortex is so complicated, that everybody says : Hands off.

   

The fact is, it is a 3-address assembler with the opportunity to modify the third operand before its usage.

   

Have a look at the ARM website and get your shivers.

   

 

   

Bob

0 Likes
Anonymous
Not applicable

I tried but it is just too time consuming. May do it if really have to. however, I still prefer to use C unless needed to 🙂

0 Likes
markgsaunders
Employee
Employee
50 sign-ins 10 solutions authored 5 solutions authored

I'm not recommending ASM development either but it is perfectly possible. There is nothing more difficult about it on an ARM processor as opposed to a 8-bitter, imho, but C compiles so efficiently on ARM that it seems a pain I can live without. Anyway, since I do plenty of things that are bad for me I'll tell you how and then leave it to your own conscience!

   

The procedure is simple enough.

   
        
  1. Open the Workspace Explorer and right-click on the "Source Files" folder.
  2.     
  3. Select "New Item..." to open the dialog.
  4.     
  5. Choose either "GNU ARM Assembly File" or "RealView ARM Assembly File" and give your file a name.
  6.     
  7. Write ASM code, build, curse, fix ASM code, build, curse, cry, give up, etc
  8.    
   

One thing to note is that the choice in step 3 depends on the compiler (which defines the assembler) you are going to use. GNU ASM is not compatible with RealView or MDK ASM. So check that before you take the plunge.

   

Good luck and enjoy yourself!

   

-- Mark.

0 Likes
JOLO_264146
Level 4
Level 4
First like received Welcome!

I imagined these answers. Sometimes customers do "strange" questions

   

I asked to this customer why this but I've not answer yet. But I've couriosity.

   

Thanks 

0 Likes