This article partly references the following articles; thanks to their authors:
- Introduction to Acoustic Wave Transmission Technology
- What Is the Principle Behind Alipay’s Acoustic Wave Payment (Face-to-Face Payment)?
- How Are the Acoustic Waves Emitted by Alipay’s Face-to-Face Payment Modulated and Demodulated?
Alipay’s acoustic wave payment has been widely deployed on vending machines across the country. It has no requirements on screen brightness, light, or other external conditions; its biggest requirement is that the phone has a speaker and can install Alipay. Compared with the earlier QR-code scanning payment or NFC, the cost is much lower.
Compared with Apple Pay, Alipay is honestly the stronger one here. In terms of promotion, Alipay is much more convenient and more suitable for the public’s small-amount consumption. So how does this principle work? Actually the principle is simple:
The phone client emits an acoustic wave; the terminal device captures the acoustic wave and converts it into a transaction number. The vending machine sends the product info plus the transaction number to Alipay’s backend over the network to generate a bill, then pushes it to the client. The transaction number is actually used to identify whose order this is.
After the principle is explained, questions arise:
1. How does the acoustic wave transmit data?
The principle is simple. Take the following audio protocol as an example: build a table of 32 characters ([0-9, a-v]) and map each character to a frequency table. The frequency table is generated by calculation based on music theory.
0 = 1760hz
1 = 1864hz
…
v = 10.5khz
A complete acoustic wave packet contains 20 tones, i.e. 20 characters, and each tone has 32 choices (as shown above), emitted one tone every 87.2 milliseconds. The first two are the information header, used to notify the receiver to start receiving. The middle 10 are the effective information bits — the valid transmitted information, i.e. the frequency information after the Key value is mapped. The last 8 are the RS (Reed-Solomon) check bits; through the RS check algorithm, the middle 10 bits are computed to generate 8 bits of check information.
The biggest limitation of the audio protocol is its low transmission efficiency, but if it’s only used to transmit the user number to the vending machine via acoustic wave for user identification, it’s still sufficient.
2. Is the same client’s acoustic wave the same every time?
This involves what information is contained in the acoustic wave. Based on the operating mechanism of the client’s QR-code payment, the acoustic wave contains not only the user’s code, but also a time-related token, a payment encryption number, etc.
Wang Yuming, Director of Alipay’s Wireless Business Development, said that the ultrasonic wave transmitted by acoustic wave payment is a randomly generated transaction number, valid for only 5 minutes.
So whether it’s the same client at different times or different clients, the emitted acoustic waves are different. This also ensures that even if the emitted acoustic wave is completely recorded, it still can’t be used to pay again.
3. Is the payment acoustic wave the “xiu xiu xiu” we hear?
This is the easiest place to misunderstand. Just as the loud counting sound from an ATM when withdrawing money is just sound from a speaker, Alipay’s payment acoustic wave is not the same as the “xiu xiu xiu” heard by the human ear. The “xiu xiu xiu” is only there so users can feel the feature is working, requiring them to bring the speaker close to the vending machine.
The frequency band of acoustic wave payment, although hard for ordinary people to hear, is also not ultrasound. The low-frequency band has too much environmental noise interference — like wind noise, knocking sounds, these broadband interferences. Restoring and correcting this polluted low-frequency information on the terminal costs too much, so currently most information is carried in the 18KHz high-frequency band (the human hearing range is 20 Hz — 20 KHz; ordinary people can generally hear around 15 KHz, so although 18KHz is within the hearing range, most people can’t hear the real payment acoustic wave frequency).
4. Does acoustic wave payment need internet?
The information transmitted by the acoustic wave is generated locally and doesn’t need to be fetched from the server over the network, so you can still use acoustic wave payment without network on your phone. This is why acoustic wave payment is massively used in vending machines in underground subway stations (wireless signals are usually affected when passing through the subway). However, the vending machine side definitely needs to be online.



