Question
AVR128DB48 Usart This is my code, and I want to get the Hello World in my terminal window (Termite or Putty) : #define F_CPU (4000000UL)
AVR128DB48 Usart
This is my code, and I want to get the "Hello World" in my terminal window (Termite or Putty) :
#define F_CPU (4000000UL) #define USART3_BAUD_RATE(BAUD_RATE) ((float)(F_CPU*64/(16 *(float)BAUD_RATE)) + 0.5) #include
void USART3_init(void); void USART3_sendChar(char c); void USART3_sendString(char *str); void USART3_init(void) { PORTC.DIR &= ~PIN1_bm; PORTC.DIR |= PIN0_bm; USART3.BAUD = (uint16_t)USART3_BAUD_RATE(9600); USART3.CTRLB |= USART_TXEN_bm; } void USART3_sendChar(char c) { while (!(USART3.STATUS & USART_DREIF_bm)) { ; } USART3.TXDATAL = c; } void USART3_sendString(char *str) { for(size_t i = 0; i
But this is what I get...
How do I connect to the Terminal? How do I wire the AVR?
Termite 3.4 (by CompuPhase) COM[00][00] COM39600bps,8N1,DTR/DSRSettingsClearAbout
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started