guivi01 / arduino-tvout

Automatically exported from code.google.com/p/arduino-tvout
0 stars 0 forks source link

hbi_hook and video offset #31

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
- What steps will reproduce the problem?
1. Setting a hbi_hook() with set_hbi_hook(&func)
2. Putting some simple code in the hbi_hook()

- What is the expected output? What do you see instead?

I expect the code to run without influencing the video display. What is 
happening is that the video is shifted towards the right.

- What version of the product are you using? On what operating system?

I am using Beta1.0 (Dec 2nd 2010)

- Please provide any additional information below.

The solution was to change the order of calls in ISR(TIMER1_OVF_vect) to the 
following:

ISR(TIMER1_OVF_vect) {

    line_handler();
    hbi_hook();
}

By changing the code, I do not notice an offset of the video.

Original issue reported on code.google.com by thomas.f...@gmail.com on 10 Feb 2011 at 7:56

GoogleCodeExporter commented 9 years ago
your code is not fast enough and I will not change the order of the calls as 
when I finally switch the render routine around the line handler will occur on 
the current interrupt and then a second interrupt will trigger output.

The horizontal blanking period hook was only intended for checking a register 
for data and putting it in a buffer, Or another very fast task

Original comment by mdmetzle@gmail.com on 10 Feb 2011 at 9:31

GoogleCodeExporter commented 9 years ago

Original comment by mdmetzle@gmail.com on 11 Feb 2011 at 9:24