Discovering PIC 16F18446 - TOGGLE "ASM WARNING - Invalid RAM location"


Results 1 to 11 of 11

Threaded View

  1. #7
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    938


    Did you find this post helpful? Yes | No

    Default Discovering PIC 16F18446 - TOGGLE "ASM WARNING - Invalid RAM location"

    Richard,

    Sorry for my late reply.

    First or upper code in your previous message dosen't work. The LED is steady ON and no warning message.

    Lower or second code doesn't work either; no LED blinking AND I do have the warning message showing up again.

    And "yes", I went to read the post you pointed me at.

    Currently, this is the code that will make the LED blink and have no warnings after compiling:
    Code:
    ' PIC 16F18446
    
    #CONFIG
        __config _CONFIG1, _FEXTOSC_OFF & _RSTOSC_HFINT1 & _CLKOUTEN_OFF & _CSWEN_ON & _FCMEN_ON
        __config _CONFIG2, _MCLRE_ON & _PWRTS_PWRT_64 & _LPBOREN_OFF & _BOREN_SBOREN & _BORV_LO & _ZCDDIS_OFF & _PPS1WAY_OFF & _STVREN_ON
        __config _CONFIG3, _WDTCPS_WDTCPS_31 & _WDTE_SWDTEN & _WDTCWS_WDTCWS_7 & _WDTCCS_LFINTOSC
        __config _CONFIG4, _BBSIZE_BB512 & _BBEN_OFF & _SAFEN_OFF & _WRTAPP_OFF & _WRTB_OFF & _WRTC_OFF & _WRTD_OFF & _WRTSAF_OFF & _LVP_OFF
        __config _CONFIG5, _CP_OFF
    #ENDCONFIG
    
    ' ====== REGISTERS SETTINGS =======================================================================
    TRISB.6 = 0
    
    ' Oscillator Control Register1
    OSCCON1 = %01100000 ' $60
    
    ' HFFRQ - Oscillator's Frequency Selection Register
    OSCFRQ  = %00000010 ' 4MHz
    
    ' ====== TEST PROGRAM =============================================================================
    TEST:
        LATB.6 = 1
        PAUSE 500
        LATB.6 = 0
        PAUSE 500
    GOTO TEST
    END
    Last edited by flotulopex; - 24th February 2024 at 18:16.
    Roger

Similar Threads

  1. How to do the "SerIN" and "SerOut " for the usb ?
    By vicce67 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 13th March 2015, 02:01
  2. Replies: 0
    Last Post: - 14th November 2013, 03:32
  3. Replies: 3
    Last Post: - 15th October 2012, 08:06
  4. PBP 2.6/MPLab 8.33 ASM "COD" error message
    By reddog24 in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 3rd December 2009, 20:09
  5. Adding data to an "array" in ASM
    By The Master in forum Off Topic
    Replies: 11
    Last Post: - 22nd November 2009, 03:21

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts