FreeRTOS ATMEGA16

Status
Not open for further replies.

febrijonathansirait

Newbie level 1
Joined
Nov 22, 2016
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
10
hi guys. do we need to change these line of code to use FreeRTOS in ATMega16? by default the code is used for FreeRTOS ATMega128 and ATMega64. i got the code from codevision FreeRTOS example (), and the code was taken from port.c
Code:
/* Hardware constants for Timer1. */
#if (defined _CHIP_ATMEGA128_) | (defined _CHIP_ATMEGA64_)

/* ATmega64, ATmega128 chips, Timer 1 runs in Mode 4 */
#define portCLEAR_COUNTER_ON_MATCH ( ( unsigned portCHAR ) 0x08 ) // WGM13=0 WGM12=1
#define portPRESCALE_64	( ( unsigned portCHAR ) 0x03 )
#define portCLOCK_PRESCALER ( ( unsigned portLONG ) 64 )
#define portCOMPARE_MATCH_A_INTERRUPT_ENABLE ( ( unsigned portCHAR ) 0x10 )

#else
#error please modify Timer1 hardware constants  to suit your chip
#endif
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…