230400 Serial Speed

Hi, Is it possible to obtain 230400 serial data rate from the pin 1 of Duemilanove?

I heard it's necessary to change the oscillator 16->14.7456MHz...


Hi, to continue my own thread I can verify that 230400 didn't work out of the box because the timing was off. I changed the 16MHz oscillator to a 14.7456MHz one and it started working!!

Now I can't upload sketches any more or use the serial monitor with the new oscillator. I tried changing in boards.txt


But it didn't seem to affect anything... what more should I change?


You'd have to change, rebuild, and reload the bootloader to account for the new crystal speed and still run the upload at 19200bps.

You COULD try changing boards.txt: atmega168.upload.speed=19200 to atmega168.upload.speed=17695

I don't know whether avdude and the FTDI chip will support that, but it IS about what the AVR uart will be running at during upload (if I did my math right.)

Thanks for your reply. Do you mean that recompiling the bootloader is the way to go but that I could be fine just by changing the upload speed in boards.txt?

It's an Atmega 328 board and the speed is 57600 there. I tried changing that to 53084 but it didn't seem to work (The IDE froze).

Thanks again.

Recompiling the bootloader is the "correct" solution, but changing the upload speed in boards.txt would have been a lot easier IF all the pieces in the upload chain actually support arbitrary speeds rather than just "the usual values." It sounds like they dont; too bad, but not too much time lost.

(when I was playing with the millis() internals and wanted to make sure it seemed to operate at different clock frequencies, I lied to the build system about the clock speed, and then lied to the serial monitor about the bitrate, and it worked fine. But the clock rates involved were just 8MHz, and 16MHz, so the bit-rate lies still worked out to standard values...)