A flute that always plays in the right key. - Description of Tree Flute in Golden Sun: Dark Dawn.

Playing the Tree Flute in Ayuthay.
The Tree Flute is an important item given to you by Baghi at Passaj.
The encyclopedia describe it as:
- This flute is said to be made from ancient trees that once grew near Ayuthay Castle. Its craftsmanship is undeniably old.
Story[]
It is the only way of getting into Ayuthay. The Tree flute allows certain passages to be revealed once played by encouraging the growth of trees and vines to lift stone walls. Playing the flute to the Ancient Tree in Ayuthay will allow you entrance into the castle.
Later on, the Tree Flute is used to awaken the Sand Prince, initiating a boss battle. In addition, when combined with the Insight energy, it will reveal the true entrance to the Ouroboros labyrinth. After these events occur, the Tree Flute has little use, but since it is an important item, it cannot be dropped or sold.
If the player exits Passaj without obtaining the item than they will be unable to progress through Ayuthay and through the story.