Guest User

Untitled

a guest
May 24th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.24 KB | None | 0 0
  1. #include "uart_new.h"
  2.  
  3. void setup() {
  4. uart_init_new(103);
  5. DDRB = 0xff;
  6. }
  7.  
  8. void loop() {
  9. uint16_t c;
  10. c = get_char();
  11. if (c & NO_DATA)
  12. {
  13. PORTB |= (1<<PB5);
  14. _delay_ms(500);
  15. PORTB &= ~(1<<PB5);
  16. _delay_ms(500);
  17. }
  18. else
  19. {
  20. put_char(c);
  21. }
  22. }
Add Comment
Please, Sign In to add comment