Is a bootloader worth the limitations?



  • Hi,

    I'm working on my first to be commissioned node (i.e. not just a test device). I am thinking of using the WDT to reset the system if the processor gets "lost". I am using a Mini Pro board and found the normal WDT reset instructions do not work. My investigation found at least one post that blamed it on the bootloader (not yet verified myself).

    My question is:

    Except for possible OTA reprogramming and maybe a slightly easier programming connection what does a boot loader gain you?
    I realize to perform ISP programming you need a different programmer (I have a AVR MKii clone).

    Am I missing something?



  • @johnrob Another option would be an external hardware based WDT. I have read that they are more reliable than the software based WDTs. I have been working on a board for this, but haven't had the time to do any final testing, but here is a design that I found on the web that uses a 555 timer. I mapped out this schematic in EasyEDA:
    0_1521769762948_f716a8e4-3ed8-4e7c-91d1-e067ff8ccf1f-image.png

    Here is what I came up with for a board using through hole components:
    0_1521769832772_0f30564b-494b-4677-9936-3a200d610532-image.png
    This board could be made a fraction of the size using SMDs.



  • @dbemowsk

    Thank for the thought. I am familiar with the 555 (or in this case the 555C) but the WDT should work. BTW if I were to try an external device I would use the TPL5010 as this will be battery powered.

    Back to my point, It would be much easier to just use an ISP than to add an additional circuit. Hence my question, is the boot loaded providing some other function I've not not aware of (mentioned above)?


  • Admin

    If you have an ISP device, then I would say no. The bootloader does not add extra value, and could be left out of the equation.



  • @tbowmo

    Thanks for the response. I'll start to the ISP. All my non Arduino AVR projects were all programmed with ISP. I moved to Arduino specifically for MySensors.

    John



  • As I recall the "normal" bootloader have not configured the WDT (I guess it's too difficult for a newbire to understand and handle WDT)
    Optiboot have WDT configured and you can set it
    Remember to call this at for each less than 8sec, else you will get reboot via watchdog
    I recommend not to set the wdt time too short, as you then won't be able to upload a sketch, as the Arduino then will reset during sketch-upload (But this isn't a problem when using ISP)

    wdt_enable(WDTO_8S);

    https://github.com/Optiboot/optiboot/wiki/HowOptibootWorks


Log in to reply
 

Suggested Topics

  • 1
  • 198
  • 1
  • 6
  • 1
  • 2

38
Online

11.4k
Users

11.1k
Topics

112.6k
Posts