Robofun 機器人論壇

熱搜: 活動 交友 discuz
查看: 5817|回復: 3

BS2 如何使用計時器達到時間同步

發表於 2012-2-10 19:37:24 | 顯示全部樓層 |閱讀模式
發表於 2012-2-10 22:30:26 | 顯示全部樓層

 樓主| 發表於 2012-2-11 10:23:09 | 顯示全部樓層
回復 2# g921002

發表於 2012-2-11 15:00:38 | 顯示全部樓層
Does the BASIC Stamp module support interrupts?

No, the interpreter chip used in the BASIC Stamp microcontroller does not support interrupts. In many cases, a fast polling routine may be used to accomplish the same effect, however, depending on the number and size of the tasks involved in some applications, this will not be fast enough and the BASIC Stamp microcontroller may not be a plausible solution. While not true interrupts, the BS2p24, BS2p40 and BS2px24 modules support 「polled interrupts.」 The 「polling」 commands allow the BASIC Stamp modules to respond to certain I/O pin events at a faster rate than what is normally possible through manual PBASIC programming. In this case the interpreter periodically checks the state of the designated polled-input pins. It 「polls」 these pins after the end of each PBASIC command and before it reads the next PBASIC command from the user program; giving the appearance that it is polling 「in the background.」
Stamp 2 is the lack of interrupts and lack of a real time clock / counter.

BS2p24, BS2p40 and BS2px24 支援所謂 「polled interrupts."也非硬體的中斷(即便使用的uC有)
您需要登錄後才可以回帖 登錄 | 申請會員


小黑屋|手機版|Archiver|機器人論壇 from 2005.07

GMT+8, 2021-12-1 12:09 , Processed in 0.154985 second(s), 7 queries , Apc On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回復 返回頂部 返回列表