ICIE indentifier not in header

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello,

I have been working with Timer1 on an Atmega88, when I tried to use the ICIE1 identifier I would get an error:"undeclared identifier ICIE1" when i looked in the header file iom88v.h (that has been included in my code) I see that within the TIMSK1 register section they have TICIE1 as the identifier. Why is it done like this? It does not seem to match the data sheet.

note
I have been using Imagecraft and it compiles with the TICIE1 identifier

Thanks,
Josh

Edit: Changed ICIE to ICIE1 and TICIE to TICIE1

Last Edited: Mon. Apr 21, 2008 - 04:25 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jbwiden wrote:
I see that within the TIMSK1 register section they have TICIE as the identifier.
Who is they? Imagecraft?

It is supposed to be ICIE1, not ICIE. I couldn't find TICIE anywhere in the data sheet. Lets see, between the chip manufacturer and a compiler writer. who would be considered to have the correct bit name....

I did see TICIE1 is used in the ATmega8. Maybe this was an Imagecraft accidental holdover from an old meag8 library? Both TICIE1 and ICIE1 are for bit 5, so they probably both work, but you might want to verify it yourself.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have tested it and it seems to work. When I refer to "they" I am talking about the developers of the Image Craft compiler who supplied the header file. I was not sure why "they" would have defined it that way. Since I am new to C and AVR's it took me a little time to figure out what needed to be done. I simply wanted to know if there may have been some logic behind the definitions being different and I was missing something.

Thanks,
Josh