MicroPython Cookbook
上QQ阅读APP看书,第一时间看更新

There's more...

Push buttons are great for applying an action repeatedly, or when you want to register a single button press. Slide switches, however, are more suitable when you want people to be able to specify between two operating modes.

For instance, you might have a project that has two animation modes that can be selected with a slide switch. You could use the slide switch to enable or disable an alarm sound in your project. Depending on the user action, a slide switch or push button might be more appropriate.

The good thing about the Circuit Playground Express is that both options are available, so you can pick and choose which one works best for you.