All the various iterations of the flashing LEDs program had one thing in common; they were one large loop using different methods to control the timing of the flashing. If this was part of a larger program that did other tasks, such as driving a robot, then putting in hooks everywhere to check if the LEDs need processing is annoying and can easily lead to bugs.

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

How to Set and Catch Interrupts

  • Stephen Smith

摘要

All the various iterations of the flashing LEDs program had one thing in common; they were one large loop using different methods to control the timing of the flashing. If this was part of a larger program that did other tasks, such as driving a robot, then putting in hooks everywhere to check if the LEDs need processing is annoying and can easily lead to bugs.