This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Errors when including header file at89x051

Hi, i'm kinda new to this so you'll have to excuse my ignorance. I'm using the MC AT89C4051 and I need to program it, so I got the at89x051.h and when I compile my program (with the #include<at89x51.h> ofcourse) with Microsoft Visual C++, I get the following errors:

error C2146: syntax error : missing ';' before identifier 'SP'
error C2501: 'sfr' : missing storage-class or type specifiers
fatal error C1004: unexpected end of file found

And here is where I got the header file from:
www.mcuok.com/.../AT89x051.H

Any help would be greatly appreciated.
Thanks in adavance, Alex.

Parents
  • You haven't, please excuse the ignorant response you received from the other poster. Unfortunately there are a couple of contributors around here who derive their amusement from trying to ridicule newcomers.

    And then there are those like Jack that "derive their amusement" from criticising every response that is not exactly to their liking.

    Erik

Reply
  • You haven't, please excuse the ignorant response you received from the other poster. Unfortunately there are a couple of contributors around here who derive their amusement from trying to ridicule newcomers.

    And then there are those like Jack that "derive their amusement" from criticising every response that is not exactly to their liking.

    Erik

Children
  • And then there are those like Jack that "derive their amusement" from criticising every response that is not exactly to their liking.

    No. I get my fun from correcting your false statements.

  • and when there is nothing false, you "get your fun" from labelling a correct but brief post 'ridicule'. Well I am getting used to the fact that whatever I post you will find a way to make a non-technical personal attack. Be advised my skin is thick. Ooes that maen that I will let a non-techinical personal attack stand, of course not.

    Erik

  • you "get your fun" from labelling a correct but brief post 'ridicule'

    Ok, let's take a look at that post:

    HUH?

    Microsoft Visual C++, for the '51??? in a Keil forum???

    It is certainly brief, but there's nothing in it that could be described as 'correct'. It's just a deliberately unhelpful and rude response. Take a look at your use of capitalisation and multiple question marks.

    Here, let me try replying to your post using your style:

    Couldn't you understand the OP's question??? HUH???

  • The correct response would be, then:

    Before posting in any new forum (especially one you "just found" with Google), please take care to read the forum's "terms of reference" (or whatever) and ensure that your post is on-topic:

    http://www.keil.com/forum/

    It says, "The Keil Discussion Forum is an open forum where you may post questions and comments about Keil products" (my emphasis).

    Neither MSVC nor Raisonance is a Keil product!

  • and the cited header file istelf does say "Keil"