fixed horizontal offset error

Basically, the LPM instruction (3 cycles) does not always take 3 cycles,
(I think because of the timing needed to read the Flash memory),
and this disrupts the timing of the signal, leading to some offsets
depending on what is shown on the line.

Thus, the LPM instruction has been replaced with an RJMP one, which,
instead, always takes 3 perfect cycles to be performed, timing is
not disrupted anymore, and image appears ok.
This commit is contained in:
giomba 2021-08-11 11:24:41 +02:00
parent eaef011cbd
commit 02a19ef783
2 changed files with 13026 additions and 11030 deletions

24053
frame.S

File diff suppressed because it is too large Load Diff

View File

@ -100,7 +100,8 @@ int main(int argc, char** argv) {
outfile << '\t' << "brne 1b" << std::endl;
}
outfile << '\t' << "lpm" << std::endl;
outfile << '\t' << "rjmp 2f" << std::endl;
outfile << "2:" << std::endl;
last = current;
count = 1;