MAX7456 Breakout Board On Screen Display Libary Fehlermeldung

Hallo Uwe,

lies mal weiter vorne, da hatte ich schon geschrieben, dass der TO das auf PAL umstellen muss und das hat er scheinbar auch gemacht, daran liegt es wahrscheinlich nicht mehr.

Gruß,
Ralf

Ok, das hatte ich überlesen.
Aber die Frage ist, hat er den Ratschlag beherzigt und umgestellt oder nicht?
Grüße Uwe

Epijano:
Das mit dem OSD.setDefaultSystem(MAX7456_PAL); war denke ich eine gute Idee. Jetzt bekomme ich manchmal regelmäßig angeordnete weiße Punkte über das Vidobild gelegt (komisch, hier: โป๊กเกอร์ บาคาร่า เสือมังกร คาสิโน มารับความร่ำรวยกัน เกมไพ่ poker steht die Libary wäre mit einem Pal System verwendet worden).

@uwefed: Ja, ich denke, er hat es gemacht.

Gruß,
Ralf

Ja, hab ich. So sieht der Scetch im Moment aus:

/*
  HelloWorld.ino
    
    Demonstrates most simple use of the MAX7456 Library.


    This example code is in the public domain.
    Requires Arduino 1.0 or later.


    History :
      1.0 ~ Creation of HelloWorld from MAX7456Demo 0.4
            2013.01.301 - F. Robert Honeyman <www.coldcoredesign.com>
      
*/



// Included Libraries //////////////////////////////////////////////////////////

  #include <SPI.h>
  #include <MAX7456.h>





// Pin Mapping /////////////////////////////////////////////////////////////////
  
  // pinValue = 0 means "not connected"

  //  FDTI Basic 5V                   ---  Arduino  VCC      (AVCC,VCC)
  //  FDTI Basic GND                  ---  Arduino  GND      (AGND,GND)
  //  FDTI Basic CTS                  ---  Arduino  GND      (AGND,GND)
  //  FDTI Basic DTR                  ---  Arduino  GRN
  //  FDTI Basic TXO                  ---> Arduino  TXO [PD0](RXD)
  //  FDTI Basic RXI                 <---  Arduino  RXI [PD1](TXD)
  
  
  //  Max7456 +5V   [DVDD,AVDD,PVDD]  ---  Arduino  VCC      (AVCC,VCC)
  //  Max7456 GND   [DGND,AGND,PGND]  ---  Arduino  GND      (AGND,GND)
  //  Max7456 CS    [~CS]            <---  Arduino  10  [PB2](SS/OC1B)
  //  Max7456 CS    [~CS]            <---  Mega2560 43  [PL6]
  const byte osdChipSelect             =            43;
  //  Max7456 DIN   [SDIN]           <---  Arduino  11  [PB3](MOSI/OC2)
  //  Max7456 DIN   [SDIN]           <---  Mega2560 51  [PB2](MOSI)
  const byte masterOutSlaveIn          =                      MOSI;
  //  Max7456 DOUT  [SDOUT]           ---> Arduino  12  [PB4](MISO)
  //  Max7456 DOUT  [SDOUT]           ---> Mega2560 50  [PB3](MISO)
  const byte masterInSlaveOut          =                      MISO;
  //  Max7456 SCK   [SCLK]           <---  Arduino  13  [PB5](SCK)
  //  Max7456 SCK   [SCLK]           <---  Mega2560 52  [PB1](SCK)
  const byte slaveClock                =                      SCK;
  //  Max7456 RST   [~RESET]          ---  Arduino  RST      (RESET)
  const byte osdReset                  =            0;
  //  Max7456 VSYNC [~VSYNC]          -X-
  //  Max7456 HSYNC [~HSYNC]          -X-
  //  Max7456 LOS   [LOS]             -X-





// Global Macros ///////////////////////////////////////////////////////////////





// Global Constants ////////////////////////////////////////////////////////////

  const unsigned long debugBaud = 9600;         // Initial serial baud rate for 
                                                //   Debug PC interface
  




// Global Variables ////////////////////////////////////////////////////////////
  
  HardwareSerial Debug = Serial;                // Set debug connection
  
  MAX7456 OSD( osdChipSelect );





// Hardware Setup //////////////////////////////////////////////////////////////

  void setup() 
  {
    
    // Initialize the Serial connection to the debug computer:
    Debug.begin( debugBaud );
    
    
    // Initialize the SPI connection:
    SPI.begin();
    SPI.setClockDivider( SPI_CLOCK_DIV2 );      // Must be less than 10MHz.
    
    // Initialize the MAX7456 OSD:
    OSD.begin();                                // Use NTSC with default area.
    OSD.setDefaultSystem(MAX7456_PAL);
    OSD.setCharEncoding(MAX7456_ASCII);
    //OSD.setCharEncoding( MAX7456_ASCII );       // Only needed if ascii font.
    OSD.display();                              // Activate the text display. 
  }
  // setup()





// Main Code ///////////////////////////////////////////////////////////////////

  void loop() 
  {
    
    while (OSD.notInVSync());                   // Wait for VSync to start to 
                                                //   prevent write artifacts.
    OSD.print( "Hello World!" );                // The '!' will not display
                                                //   because it does not come 
                                                //   in the factory font.
    while (true);
    
  } 
  // loop()





// Interrupt Methods ///////////////////////////////////////////////////////////





// Local Methods ///////////////////////////////////////////////////////////////

besonders interessant finde ich, dass wenn ich OSD.print( "Hello World!" ); und/oder while (OSD.notInVSync()); aus dem Code raus nehme immer das Videobild mit den darüber gelegten Punkten bekomme und nie überhaupt kein Signal (das passiert sonst nämlich relativ häufig).

Übrigens sind hier noch Dokumente die bei der Libary dabei waren. Ich hab sie mir ein Stück weit durchgelesen aber nur zur Hälfte verstanden(Meine Microkontroller Kenntnisse reichen (noch) nicht über das was ich mir aus Interesse angeeignet habe hinaus).

Sorry, ich hatte vergessen die Dateien anzuhängen.

keywords.txt (2.87 KB)

MAX7456.cpp (69.3 KB)

MAX7456.h (11.8 KB)

Hallo,

nicht das Du denkst, ich melde mich einfach nicht mehr, aber im Moment habe ich leider keine Idee.

Gruß,
Ralf

So,

ich habe anlässlich meines "Keine Idee"-Posts nochmal über Deinen Code geschaut. Mir ist noch folgendes aufgefallen:

  //  Max7456 CS    [~CS]            <---  Arduino  10  [PB2](SS/OC1B)
  //  Max7456 CS    [~CS]            <---  Mega2560 43  [PL6]
  const byte osdChipSelect             =            43;

Du schreibst aber, Du hast einen UNO. Ändere das doch mal in:

const byte osdChipSelect             =            10;

und achte darauf, dass das Kabel auch am richtigen Pin angeschlossen ist.

Was passiert dann?

Gruß,
Ralf

Ah, jetzt funtioniert`s.
Was ich mich noch frag ist wie ich die weißen Punkte (die sind nämlich immer noch da) aus dem Bild raus bekomme aber die Einstellung dazu werde ich sicher noch finden.
Vielen Dank, Ralf.

Gruß,
Jan

Epijano:
Ah, jetzt funtioniert`s.

Cool, das freut mich XD

Gruß,
Ralf