From 1771faf03eb3fa569567446026a27b44573850eb Mon Sep 17 00:00:00 2001 From: Dan Date: Sun, 29 Jan 2023 11:23:52 -0500 Subject: [PATCH] Few changes to the carrier frequency --- src/main.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index d60b4f3..d10f5d4 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -9,13 +9,13 @@ long code = 0b11111111100000000111111011100001; #define BIT_LENGTH 1 //Generates the carrier requency for the supplied timeframe -void carrier(int BlastTime) { - for(int i=0; i<(BlastTime); i++) +void carrier(unsigned int BlastTime) { + for(int i=0; i<(BlastTime/2); i++) { PORTB |= (1 << 0x04); - _delay_ms(BIT_LENGTH); + _delay_ms(9); PORTB &= ~(1 << 0x04); - _delay_ms(BIT_LENGTH); + _delay_ms(9); } return; }