# Drum machine > How about making your own drum beat? Build a 16-step drum pattern with kick, snare, hi-hats, clap and tom, play it at your tempo and tap live pads on top. Make a drum beat in your browser: a 16-step grid with kick, snare, hi-hats, clap and tom, tempo, live pads and presets. The beat is saved in the link. - Page: https://how.box/drum-machine/ - Runs entirely in the browser. - License: HowToolbox's own text and data (titles, explanations, FAQs, tool descriptions and schemas, this file) are CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/); AI training and answers are welcome. Attribute "HowToolbox (how.box)" with a link to the page used. Third-party data keeps its own terms; the name and logo are not licensed. Publisher: HowToolbox, contact@how.box. Terms: https://how.box/about/terms/ ## Inputs Answer link: https://how.box/drum-machine/?t={t}&p={p} - `t` (whole number 40 to 240): Tempo in beats per minute, 40–240. Example: `120`. - `p` (text): The 16-step pattern as 24 hex digits (kick, snare, closed hi-hat, open hi-hat, clap, tom; four digits each). Example: `80a00808aaaa000000000000`. Example answer: https://how.box/drum-machine/?t=120&p=80a00808aaaa000000000000 The page computes the answer in the browser: read results from the agent tools below, not from the page HTML. ## Agent tools - `drum_machine_pattern`: Sets a 16-step drum pattern on the page and returns its facts. - MCP, one POST to https://how.box/mcp: `{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"drum_machine_pattern","arguments":{"tempo_bpm":120}}}` - GET: https://how.box/mcp/run/drum_machine_pattern?tempo_bpm=120 ## How it works A drum machine plays a short pattern over and over. Here the pattern is one bar of four beats, and each beat is split into four steps, so a bar has 16 steps. A step is a sixteenth note. How long a step lasts follows from the tempo: step length = 60 ÷ BPM ÷ 4 seconds. At 120 BPM a beat is 0.5 s, so a step is 125 ms and the bar lasts 2 seconds. Slower tempos stretch the bar, faster ones squeeze it. The drums are made in your browser, not played from recordings: a kick is a quickly falling low tone, a snare and hi-hats are shaped noise, a clap is a few short noise bursts and a tom is a similar falling tone, higher than the kick. A closed hi-hat cuts off an open one that is still ringing, as on real drum machines. Common beats use the same few ideas: rock puts the kick on beat one and the snare on beats two and four, house and techno put the kick on every beat, reggae's one drop leaves beat one empty, and drum and bass keeps just two kicks and two snares. The presets are generic grooves of each style at its usual tempo, not copies of songs. ## FAQ **Why does a step not sound the moment I press it?** The drums are scheduled slightly ahead so the rhythm stays steady even when the page is busy. A step you switch on is played the next time the loop reaches it. **Can I save my beat?** The pattern and tempo are in the page address. Copy the link, bookmark it or send it to someone to open the same beat. **Why does the beat stop when I switch to another tab?** Browsers pause sound and timing in hidden pages to save power, so the drum machine stops when the page is hidden. Press Play again when you return. **Can I make a pattern in 3/4 or add swing?** No. Each loop has sixteen evenly spaced steps in 4/4. Different time signatures and swing are not supported. **Can I load my own drum samples?** No. The six drum sounds are synthesized; the tool does not import samples. More: [HowToolbox index](https://how.box/llms.txt) · [Agent Skill](https://how.box/skill.md) · [agent terms](https://how.box/about/agents/)