Hi,
I want make a emulator for my "Tuner List" radio like describt on:
http://tlcdcemu.sourceforge.net/
Unfortunately the communication have to be 9600 Baud, 8 bits, even parity and one stopbit. 
The main problem I have (at the moment) is:
How can I switch the normal mode from serial connections with no parity to a even parity bit?
Is there any Serial.mode()-command?
How I can get all informations about attributs and operations of a class or method?
Many thanks in advance for help
You will want the Atmel manual for your processor, either the ATmega8 or ATmega168. There in the chapter on the USART you will find the registers and bits defined. On an ATmega8 it looks like...
UCSRC = ( UCSRC & ~_BV(UPM0) | _BV(UPM1) );
... will switch you to even parity. The 168 may have a different register name.
Do this after your Serial.begin(9600) call.
Thank you for the fast response.
It's running after 30 minutes studying the manual ;D. Please don't grumbling me. I'm an absolut beginner with ATmega and have only a few experiences with C/C++ because I had used formerly the Parallax Basic-Stamps about 5 years. Now I was limited with this BASIC solution and looking for a better one. Arduino seems to be the answer (I hope for the next few years).
The working code is:
Serial.begin(9600);
UCSR0C = ( UCSR0C & ~_BV(UPM00) | _BV(UPM01) );
UPM01=1 --> Parity on
UPM00=0-->Even
UPM00=1--> Odd
Can anybody describe the code part by part?
What means the "_BV"? Hold this the bit-position of that register-entry (UPM00 is the fourth bit, UPM01 the fifth)?
What means the "n" in UCSRnC, UPMn0, UPMn1 which I can read in the manual for ATmega48/88/168?
_BV(x) is a macro that returns a byte of all zeroes except for bit number 'x' which is a one.
It is probably the same as (1<<x)
UCSR0C is just a symbolic name for a register.
The Atmel folks like to pretend they have any number of certain things and use 'n' for the digit, even if there is only one UART or if the timer they are talking about is completely different from all the other timers. Sometime between the mega8 and mega168 they brought this hallucination to the uart register names.
The rest of it is just bitwise arithmetic.
& is bitwise AND
~ is bitwise NOT
| is bitwise OR
The end result is that you turn off UPM00, turn on UPM01, and leave the rest alone.