Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp
00001 /* 00002 Test interrupt response time 00003 00004 Hardware: NUCLEO-F767ZI 00005 Libraries: 00006 mbed-os-5.12.3 00007 Measured delay between gpio_in and gpio_out 00008 * rising: 1.1 usec - 1.3 usec 00009 * falling: 1.1 usec - 1.3 usec 00010 */ 00011 00012 #include "mbed.h" 00013 00014 InterruptIn gpio_in(PC_8); 00015 DigitalOut gpio_out(PC_9); 00016 00017 void on_fall() 00018 { 00019 gpio_out = 0; 00020 } 00021 00022 void on_rise() 00023 { 00024 gpio_out = 1; 00025 } 00026 00027 int main() 00028 { 00029 gpio_in.fall(&on_fall); 00030 gpio_in.rise(&on_rise); 00031 00032 while (1) { 00033 wait(0.01); // 10 msec 00034 } 00035 }
Generated on Sat Jul 16 2022 23:30:34 by
1.7.2