cancel
Showing results for 
Search instead for 
Did you mean: 

What is it magic of COSMIC?

Vyacheslav Azarov
Associate III
Posted on December 06, 2016 at 08:15

Hello,

Very interested, why needs code what marked bold? In the documentation, this bit is designated as insignificant.

 

163                     ; 28 __interrupt void _on_tick_(void)

 163                     ; 29 {

 164                            switch    .text

 165  0034             __on_tick_:

 167  0034 8a                push    cc

 168  0035 84                pop     a

 169  0036 a4bf              and     a,&sharp191

 170  0038 88                push    a

 171  0039 86                pop     cc

 172  003a 3b0002            push    c_x+2

 173  003d be00              ldw     x,c_x

                             ...

Answer who knows, please.

#compiler #cosmic #magic
2 REPLIES 2
luca239955_stm1_st
Senior II
Posted on December 06, 2016 at 12:15

Hello,

this is a fix for a silicon problem in the DIV / DIVW instruction, more details at page 59 of the compiler manual.

Regards,

Luca

Posted on December 06, 2016 at 16:03

Thank you. Who would have thought? I needed study the errata sheets more deeply, to prevent possible surprises.