Hi,
After spending too much time trying to work out why the 57600 data-stream from my ENVI energy meter was garbage on the Logomatic, I thought it worth sharing what I think might have been the problem.
Basically the baud rates in the supplied firmware, by my calculations, appear to be set pretty coarsely, while this may not be a problem at lower speeds my experience at 57600 was that I was getting significant over-sampling which was adding spurious bits to my data making it unusable after the first byte
As far as I could tell the DIVADDVAL and MULVAL are not set so according to the user manual the baud rate calculation would be;
60Mhz / (16 * (256 * U0DLM) + U0DLL)
So for 57600 baud I get 58593 (using the supplied firmware settings of U0DLM = 0x00, U0DLL = 0x40), a 1.7% error.
But by changing U0DLL to 0x41, I get 57692, only a 0.2% error.
I maybe completely wrong about this but all I know is that when I changed the main.c code for the 57600 baud rate U0DLL from 0x40 to 0x41, the stored streaming XML data changed from this;
else if(baud == 57600)
{
U0DLM = 0x00;
U0DLL = 0x40;
}
logged data...
<µÍùþ<ÍÉ