Tagged: 

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #3204
    Anonymous
    Inactive

    How can I program a handshake when the two arduinos are connected? So that one arduino sends a specific code to the main arduino and the main arduino does some specific then. And when the slave arduino gots disconnected the main arduino recognizes it and waits for a new arduino? Over serial?

    Or is it easier to do this over I²C?
    (but I made some pcbs with Atmegas, so if I²C is easier and better I have to make new pcbs 🙁 )

    Sorry for bad english.

    Greetings from Germany

    jhns

    #3271
    Anonymous
    Inactive

    German (English is further down):

    Serielle Kommunikation mit EasyTransfer Library sollte gut funktionieren

    Du kannst versuchen in einem periodischen Zyklus eine Aufgabe vom Master an den Slave zu schicken.

    z.B.: Der Master sendet eine random Zahl an den slave. Der slave muss diese um eins erhöhen und zurück schicken. Wenn der Master innerhalb einer gewissen Zeit keine oder nur die falsche Antwort bekommt ist der Slave oder die Kommunikation tod. Ansonsten habt ihr euch erfolgreich die Hände geschüttelt 😉

     

    English:

    Serial Communication with EasyTransfer should work very well.

    You can try to send a periodic Challenge from the master to the slave.

    e.g. master sends random number, slave receives it, iterates it and send it back to master. When master gets the right answer within some time the handshake works well

     

    Greetings

    Pac-Man

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.