is there any special C standard for
MCU?
No, there is the ISO C standard. Because many small devices have special architecture features that need to be supported, many compilers support language extensions. For example because an 8051 has bit addressable RAM, a _bit
data type may be provided. It also has a Harvard architecture, so keywords are provided for specifying different memory address spaces which an address alone does not resolve since different instructions are required to address these spaces. Such extensions will be clearly indicated in the compiler documentation. Moreover extensions in a conforming compiler should be prefixed with an underscore, however many provide unadorned aliases for backward compatibility, their use should be deprecated.
when I programmed something under
Windows OS, it doesn´t matter which
compiler I used.
Because the Windows API is standardized (by Microsoft), and it only runs on x86, so there is no architectural variation to consider. That said, you may still see FAR, and NEAR macros in APIs, and that is a throwback to 16bit x86 with its segmented addressing, which also required compiler extensions to handle.
that even its still C in its basics,
like loops, variables creation and so,
I am not sure what that means. A typical microcontroller application has no OS or a simple kernel, you should expect top see a lot more 'bare metal' or 'system-level' code, because there are no extensive OS APIs and device driver interfaces to do lost of work under the hood for you. All those library calls are just that; they are not part of the language; it is the same C language; jut put to different work.
there is some syntax type I never seen
in C for desktop computers.
For example...?
And furthermore, the syntax is
changing from version to version.
I doubt it. Again; for example...?
I use AVR-GCC compiler, and in
previous versions, you used function
for Port I/O, now you can handle Port
like variable in new version.
That is not down to changes in the language or compiler, but more likely simple 'preprocessor magic'. On AVR all I/O is memory mapped, so if for example you include the device support header, it may have a declaration such as:
#define PORTA (*((volatile char*)0x0100))
you can the write:
PORTA = 0xff ;
to write 0xff to memory mapped the register at address 0x100. You could just take a look at the header file and see exactly how it does it.
The GCC documentation describes target specific variations; AVR is specifically dealt with here in section 6.36.8, and in 3.17.3. If you compare that with other targets supported by GCC, it has very few extensions, perhaps because the AVR architecture and instruction set were specifically designed for clean and efficient implementation of a C compiler without extensions.
So, I just wondered, what defines what
functions and how have to be
implemented into compiler to be still
called C?
It is important to realise that The C language is a distinct entity from its libraries, and that functions provided by libraries are no different from the ones you might write yourself - they are not part of the language - so it can be C with no library whatsoever. Ultimately library functions are written using the same basic language elements. You cannot expect the level of abstraction present in say the Win32 API to exist in a library intended for a microcontroller. You can in most cases expect at least a subset of the C Standard Library to be implemented since it was designed as a systems level library with few target hardware dependencies.
I have been writing C and C++ for embedded and desktop systems for years and do not recognise the huge differences you seem to perceive, so can only assume that they are the result of a misunderstanding of what constitutes the C language. The following may help: