Composite video with ATmega1284p

I am trying to make a computer running tiny basic on an ATmega1284p using the Arduino TVout library. But for some reason the composite video won't sync to the display resulting the text not stop scrolling. I have tried changing display.scanline to -1 but that has not helped either. The display I am using is PAL and the microcontroller is set to output PAL at 720x480. Any help you can offer is greatly appreciated.

Code?
Hardware setup?
We're not mind readers, need something to work from.

ATmega1284p with a 1k resitor from pin 19 (sync) to rca connector
470 ohm resistor (video) from pin 33 to rca
16mhz crystal across pins 12 and 13 with 22pf capacitors.

Single_Chip_Computer.ino (45.6 KB)

No decoupling caps?
No reset pullup resistor?
Add those as a minimum.

I have not used any of these is a pull up on the reset necessary?

Yes. I don't make any boards without them.
What about the fuses - did you burn them to support 16 MHz external crystal?

I have added a 0.1 uf capacitor and a 10k pull up resistor but still get the same issue.
Thank you for your help so far.

I am not 100% sure but i believe the fuzes were set when i burnt the "original mighty 1284p 16mhz bootloader" to the chip

Ok.

I can't tell from that code which 2 pins are being used as the 2 outputs you are after.

The pins_arduino.h for Bobuino board type is different from other 1284 board types.

What you can do is use a an LED with resistor and see which 2 pins are really active, then they those 2 as the 2 output signals you are looking for,.

The best I got out of a atmega1284 was 352*280 @ 24MHz, and that took over 12k of the 16k

if you are doing 720x480 you wont have enough ram, that will take 43.2kbytes !!

what speed are you running at ?

I am running at 16mhz