The opening of the stomata is related to the influx of the $\mathrm{K}^{+}$ions into the guard cells. The $\mathrm{K}^{+}$ions are obtained from the nearby subsidiary and epidermal cells. Due to this influx, the concentration of the $\mathrm{K}^{+}$ions in the guard cells. The presence of high energy ATP molecules triggers the entry of $\mathrm{K}^{+}$ions into the guard cells. Further, the presence of ATP also triggers the $\mathrm{H}^{+}$uptake by guard cell chloroplasts or mitochondria.