- Labornetzteil AliExpress         
Seite 4 von 4 ErsteErste ... 234
Ergebnis 31 bis 32 von 32

Thema: Lieder mit dem Soundbefehl

  1. #31
    Erfahrener Benutzer Robotik Einstein
    Registriert seit
    09.06.2004
    Ort
    Aachen
    Beiträge
    2.674
    Anzeige

    Praxistest und DIY Projekte
    Hi Jon,

    ich weiß leider auch nicht mehr so genau, was ich damals gemacht habe.
    Hier sind auf jeden Fall mal zwei Bas-Dateien, die ich davon noch gefunden habe. Ich kann dir aber leider nicht erklären, was da was genau macht, und warum ich das so gemacht habe.

    Code:
    $Crystal = 10000000
    
    Do
    Sound Portd.6 , 130 , 1916
    Sound Portd.6 , 146 , 1706
    Sound Portd.6 , 164 , 1520
    Sound Portd.6 , 174 , 1433
    Sound Portd.6 , 293 , 1276
    Sound Portd.6 , 6250 , 10
    Sound Portd.6 , 293 , 1276
    Sound Portd.6 , 6250 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 783 , 1276
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 200 , 1136
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 783 , 1276
    Sound Portd.6 , 170 , 1433
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 170 , 1433
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 170 , 1433
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 170 , 1433
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 325 , 1520
    Sound Portd.6 , 500 , 10
    Sound Portd.6 , 325 , 1520
    Sound Portd.6 , 500 , 10
    Sound Portd.6 , 145 , 1706
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 145 , 1706
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 145 , 1706
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 145 , 1706
    Sound Portd.6 , 450 , 10
    Sound Portd.6 , 261 , 1916
    Wait 2
    Loop
    Und:

    Code:
    $baud = 19200
    Const Konstante = 332400
    Const Zeitkonstante = 332400                                'Konstante f¸r ganze Note (Hier = Konstante)
    Const C = 261
    Const D = 293
    Const Pause = 10
    Dim Duration As Long
    Dim Puls As Long
    Print "Hallo"
    Declare Sub Play(byval Noten As Word , Byval Wert As Byte)
    
    Do
    Call Play(c , 8)
    Wait 1
    Loop
    End
    
    Sub Play(byval Noten As Word , Byval Wert As Byte)
    
    Puls = Konstante / Noten
    Duration = Zeitkonstante / Puls
    Print Puls
    Print Duration
    Duration = Duration / Wert
    Print Duration
    Sound Portd.6 , Duration , Puls
    Sound Portd.6 , 1000 , 10
    
    
    End Sub
    Ich hoffe, es hilft dir irgenwie weiter

  2. #32
    Erfahrener Benutzer Robotik Einstein
    Registriert seit
    29.12.2005
    Ort
    Nähe Mainz
    Alter
    32
    Beiträge
    3.467
    Ich werde es mir nochmal genauer anschauen. Im Moment habe ich nicht die Zeit dazu.
    Aber trotzdem schade, dass du nicht mehr weißt, wie du das gemacht hast.
    Vielleicht finde ich es ja heraus

    jon
    Nice to be back after two years
    www.roboterfreak.de

Seite 4 von 4 ErsteErste ... 234

Berechtigungen

  • Neue Themen erstellen: Nein
  • Themen beantworten: Nein
  • Anhänge hochladen: Nein
  • Beiträge bearbeiten: Nein
  •  

MultiPlus Wechselrichter Insel und Nulleinspeisung Conrad