------------------------------------------------------------------------------------------------- Sample Project for Microchip XC8 (pic18F46K80) and MPLAB X simulator. Rev.: 1.1 // 2018/05/02 ------------------------------------------------------------------------------------------------- TESSY 4.0.19 Microchip XC8 v1.45 (mode=free) MPLAB X v4.15 ------------------------------------------------------------------------------------------------- Package: microchip_xc8_pic18F46K80_mplabx_simulator.zip ------------------------------------------------------------------------------------------------- Brief description: The sample project uses only a simple function (is_value_in_range) and assumes that you have already experience with TESSY. It's important to set the so called configuration bits in TESSY. In case of PIC18F46K80 (and with the given example), you have to deactivate the Extended Instruction Set Enable bit (XINST) and the Watchdog Timer (WDT). MPLABX offers the possibility to generate source code with the settings of the configuration bits. This source code can be copied and stored in a file (e.g. configuration_bits.c) that we can compile and link to the test driver. You have to use the attributes InitScrDir and InitObjDir with Use Board Files enabled. The example uses a file located in the scr folder (of the example). The'mode' settings in the Makefile template for the XC8 compiler are set to mode=free. If you have a licensed compiler, you can set the mode to mode=pro. Regarding the warning message (when compiling the test driver): (1459) peripheral library support is missing for the 18F46K80 (warning) According to Microchip, the latest version of XC8 no longer includes the old PIC18 peripheral libraries. If you don't use them, ignore the messages. If you do, you have to download them separately from the XC8 download page. Extracting the project files 1) Please extract the archive in a folder of your choice, e.g. c:\projects. Do not use $(TESSY_TESTAREA) -> c:\tessy. This directory is reserved for TESSY! 2) Start TESSY 4.0. In the Select Project dialog, please choose Import and select then the ..\tessy\tessy.pdbx (or just double-click the file). 3) Open the imported project. TESSY will then open the Restore Database dialog. Please choose the module 'IsValueInRange'. 4) If the environment editor is not starting, please open them from File|Edit Environment... You have to enable the compiler (General - Compiler) and the debugger (General - Targets) if necessary. You have to correct the path accordingly for attributes that are marked in red.