Closed GoogleCodeExporter closed 9 years ago
Exactly what im looking for!
But i dont understand what you mean with "OFF,OFF,ON,OFF"
Original comment by bo...@owee.de
on 20 Sep 2011 at 6:37
to be honest, i cant remember what the ON,OFF boolean flags do..
it is possible to do all this, just change the bit array (hidden in the manual
for each port and then power cycle the board. something like
bitarray = B'00000000'
does the trick
Original comment by frozenf...@gmail.com
on 20 Sep 2011 at 7:28
page 226 from http://www.atmel.com/dyn/resources/prod_documents/doc2549.pdf has
all the info for this topic. if the IDE could automate these bits, then that
would be fantastic!
Original comment by frozenf...@gmail.com
on 20 Sep 2011 at 7:54
I know that it isn't "that" easy to do all modes of a uart with only one Byte.
On a AtMega644P for example you need to change the registers UCSRxB and UCSRxC
to configure a 9N1 for example (UCSZx0,UCSZx1,UCSZx2)
But this should defenitly be supported by the serial lib!
Original comment by bo...@owee.de
on 21 Sep 2011 at 7:12
from a project (comments might be wrong), but this is an alternate structured
way to follow the manual and apply the settings
//Servo drive port setup
//
//UCSR2C IS =
//UMSELx1, UMSELx0, UPMx1, UPMx0, USBSx, UCSZx1, UCSZx0, UCPOLx
UCSR2C = B00000000;
//set serial port to none
UCSR2C = UCSR2C | B00000000;
//set serial word length to 8
UCSR2C = UCSR2C | B00000110;
//set serial stop bit to 1
UCSR2C = UCSR2C | B00000000;
8/none/1 seems to be the default I think. windows hyperterminal allways seems
to auto detect settings if you input them incorrectly.
9 data bits is something I have not come across. If it is settable I allways
try to change it to 8/Odd/1,
only 8/7, Even/none/Odd, 1/2 should exist, bloody 9 data bit devices.
alternatively alternatively, someone could just make a profibus/DP shield and
my problems would be over......
Original comment by frozenf...@gmail.com
on 21 Sep 2011 at 7:41
Original comment by dmel...@gmail.com
on 11 Mar 2012 at 5:05
Original issue reported on code.google.com by
frozenf...@gmail.com
on 28 Jul 2011 at 8:25