Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostm8s103f3.h>
- main( void )
- {
- PD_DDR = 0x0f; //sets port to output mode
- while(1){
- PD_ODR_ODR3 = 1; //turns pin3 on
- //delay
- int k = 0;
- for(int i = 0; i < 1000000; i++){
- k++;
- }
- PD_ODR_ODR3 = 0; //turns pin3 off
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment