FYI - AVR baud calculator http://www.wormfood.net/avrbaudcalc.php?postbitrate=9600&postclock=11.0592
----- PŮVODNÍ ZPRÁVA ----- Od: "Matthias Trute" <mtr...@web.de> Komu: "Everything around amforth" <amforth-devel@lists.sourceforge.net> Předmět: Re: [Amforth] Issues with a word compile - flash or eeprom Datum: 7.5.2012 - 21:14:08 > Hi Jan, > > > Chuck, > > > > When I won't to run at a higher baud rate should > > I compile again? > > > That would probably be the easiest way. > > Technically it is not needed however. The serial > settings come from the VALUE baud (check with e.g. > > \ I use 38400 instead of 9600 > amforth 4.9 ATmega1284P 16000 kHz > > baud u. > 25 ok > > > ). The initial value is calculated at compile time > but nothing prevents you from changing it at > runtime. > > The two bytes from this value are written > literally > into the baudrate registers at startup (e.g. > COLD), > thus the name of the value "BAUD" is somewhat > misleading. The datasheets have a rather big table > for some cpu frequencies and baud rates. The > compile > time calculation is done in the file > core/amforth-eeprom.inc An untested forth snippet > is > in lib/misc.frt > > The steps are > 1) get the new settings (e.g. from datasheet) > 2) store them into BAUD > 3) reset the controller (COLD) > 4) reconfigure your terminal > > If you write to the baud rate registers directly > (its > not rocket science, after all), you can even > change > the settings on the fly. You should use one > command line > for both bytes however with the order high-byte > low-byte (again: datasheet). > > Matthias > PS: Is there someone who wants to implement > auto-baud? > > ------------------------------------------------------------------------------ > > Live Security Virtual Conference > Exclusive live event will cover all the ways > today's security and > threat landscape has changed and how IT managers > can respond. Discussions > will include endpoint security, mobile security > and the latest in malware > threats. > http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Amforth-devel mailing list for > http://amforth.sf.net/ > Amforth-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/amforth-devel > ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Amforth-devel mailing list for http://amforth.sf.net/ Amforth-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/amforth-devel