Target Doard Definition

Comments

3 comments

  • Avatar
    Chuck Hackett

    Ok, so I can't type :-)  ... obviously "Doard" in the subject line should be "Board"!  (I'm off to my corner now ...)

    Chuck Hackett

    0
    Comment actions Permalink
  • Avatar
    Paul Curtis

    You can edit the ctl_board.c file to match your own target.  Right click on the file in the Project Explorer and select Import to make a local copy, if it's not local already.

    The "board" files just define the set of services needed by the generic examples--usually something that will control a LED and respond to a button press using an interrupt.

    0
    Comment actions Permalink
  • Avatar
    Chuck Hackett

    (Still trying to find my way around)

    (minor) When using "Add Existing File" I get a standard Windows Open Dialog rather than what is shown in Help but I assume that this is because the Help images are from a MAC or Unix?

    I don't see ctl_board.c in Project Explorer -- I am trying to compile the bare minimum ctl template code (I have not added any code yet) and I am still getting compile errors on ctl_avr.c.

    It appears that "ctl_avr.c" was derived from ctl_board.c (or is at least very similar).  I hesitate to alter "System" files before I know my way around the product.  I also hesitate to alter a "System" file because I would not get the benefit of any changes made to the file in future releases.

    I started with the unaltered CTL template code to be sure I got a clean compile before I added any of my code.  My errors are:

    Line 64: TIMSK1 undefined

    This is in an "else" on an "if defined(__TARGET_PROCESSOR_IS_XMEGA).  Project properties correctly shows the target processor as "ATmega32A" which does not have a "TIMSK1" but does have a "TIMSK".

    Line 104: EICRA undefined

    Line 105: EIMSK undefined

    These are within the "else" of a "#elif (__TARGET_PROCESSOR==ATmega32)".  Again, the target processor is set to "ATmega32A".

    I know how to fix these if I "Import" ctl_avr.c into the project but I hesitated to do so since it was a "System" file. 

    Does this file need to be updated by Rowley or is this a "commonly modified template only" and I should expect to modify it? 

    If so, I think this should be noted in the ctl doc (perhaps a section called "Creating a ctl project from scratch").

     

    0
    Comment actions Permalink

Please sign in to leave a comment.