mikroC fault with binary data type 0b00000000

Post your requests and ideas on the future development of mikroC.
Post Reply
Author
Message
The_RB
Posts: 172
Joined: 18 Jan 2008 05:32
Location: Australia
Contact:

mikroC fault with binary data type 0b00000000

#1 Post by The_RB » 03 Apr 2009 13:03

Hi, just to let you know that the binary integer data type, ie;

0b00000001 (etc) works in the C compiler.

But 0b00000001 does NOT work when it is within inline assembler (ASM { } )code within the C compiler. And the MPASM data type '0b00000001' does not work either.

So can you please make the inline assember accept binary integers please.
:)
Using; EasyPic4, EasyPIC6, BigPic4, MikroC. MPLab, MPASM.
C since 1991, PIC asm since 1998. Author of many freeware and open-source goodies; www.RomanBlack.com Designer of the www.TalkBotBrain.com talking PIC project.

User avatar
milan
mikroElektronika team
Posts: 1013
Joined: 04 May 2006 16:36
Contact:

#2 Post by milan » 03 Apr 2009 13:48

Hi,

mikroC PRO for PIC supports binary format "0b..."

It also supports hex numbers : "0x"
current program counter : "PC" or "$"

and operators "bitPos", "bitMask", "lo_addr", "hi_addr" "higher_addr"

If I remember well - everything that you see in generated *.asm and *.lst files is supported in asm blocks.
SmartADAPT2 rules !

The_RB
Posts: 172
Joined: 18 Jan 2008 05:32
Location: Australia
Contact:

#3 Post by The_RB » 04 Apr 2009 00:25

Thanks for the quick reply! :)

Does the new PRO compiler allow me to use "0b..." inside ASM?? The old compiler does not, it only lets me use "0b..." in the C code not in the ASM code, and I write a lot of my C code in ASM to speed it up.

Thank you.
Using; EasyPic4, EasyPIC6, BigPic4, MikroC. MPLab, MPASM.
C since 1991, PIC asm since 1998. Author of many freeware and open-source goodies; www.RomanBlack.com Designer of the www.TalkBotBrain.com talking PIC project.

User avatar
milan
mikroElektronika team
Posts: 1013
Joined: 04 May 2006 16:36
Contact:

#4 Post by milan » 06 Apr 2009 08:08

Yes, all the formats/operators explained are supported inside asm blocks.

Download the compiler http://www.mikroe.com/forum/viewtopic.php?t=18973 and try it :)
SmartADAPT2 rules !

Post Reply

Return to “mikroC Wish List”