• AVR Freaks

Hot!I2C driver is not working with basic bootloader firmware

Author
ravic
think_do_repeat
  • Total Posts : 139
  • Reward points : 0
  • Joined: 2016/02/04 03:02:20
  • Location: Pune, MH, India
  • Status: offline
2016/10/18 02:36:45 (permalink)
0

I2C driver is not working with basic bootloader firmware

Hi,
I am using basic firmware present in directory C:\microchip\harmony\v1_07_01\apps\bootloader\basic\firmware, and I kept my application firmware in C:\microchip\harmony\v1_07_01\apps\usb\device\i2c_test\i2c_test\firmware, if I disable the 'Use bootloader' then the above application firmware is working fine( its writting data on EEPROM), but when I enable use bootloader,  build application linker script and bootloader type as USB_DEVICE, then its not working with basic bootloader.
For customizing the bootloader, I made Few changes in basic bootloader as below:
In the apps/bootloader/basic fw I only changed the function:
app.c file :
int APP_ForceBootloaderCheck(void)
{
    // For most of the basic bootloaders, the check of the switch (S3) and
    // the memory location will decide the question.
    //if (BSP_SWITCH_STATE_PRESSED == BSP_SwitchStateGet(BSP_SWITCH_3))
   if (*(uint32_t *)BOOTLOADER_FLASH_TRIGGER_ADDRESS != 0xFFFFFFFF)
        return (1);
    
    return (0);
}

and in system_config.h:

#define BOOTLOADER_LEGACY
#define BOOTLOADER_FLASH_TRIGGER_ADDRESS 0x9D061000

these lines added.
(attached my i2c_test firmware to build it succesfully keep it in "C:\microchip\harmony\v1_07_01\apps\usb\device\i2c_test\i2c_test\" directory)
#1

2 Replies Related Threads

    NKurzman
    A Guy on the Net
    • Total Posts : 18680
    • Reward points : 0
    • Joined: 2008/01/16 19:33:48
    • Location: 0
    • Status: offline
    Re: I2C driver is not working with basic bootloader firmware 2016/10/18 06:13:44 (permalink)
    0
    Try the v1.09 bootloader and see if it is any better.
    #2
    clange
    Junior Member
    • Total Posts : 53
    • Reward points : 0
    • Joined: 2012/05/16 14:25:43
    • Location: 0
    • Status: offline
    Re: I2C driver is not working with basic bootloader firmware 2019/12/23 14:42:44 (permalink)
    0
    I know this is a really old topic, but I have the exact same issue running Harmony 2.06.
    If I run my main program, everything works fine.  As soon as I program with the bootloader, I2C hangs in the main program.
    #3
    Jump to:
    © 2020 APG vNext Commercial Version 4.5