If you want to control flow in an event model- then chained promises might be what you are after.
Manipulating bits might be more intensive - if you have the space, use a byte- takes a look at the dataview classes. With these you can operate on a chunk of an existing array.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
If you want to control flow in an event model- then chained promises might be what you are after.
Manipulating bits might be more intensive - if you have the space, use a byte- takes a look at the dataview classes. With these you can operate on a chunk of an existing array.