Author Topic: Software reset  (Read 3477 times)

leyouf

  • Newbie
  • *
  • Posts: 1
Software reset
« on: August 25, 2014, 03:13:49 am »
Hi, there is a way to reset the digispark via software?

Or at least by using a pin?

gogol

  • Sr. Member
  • ****
  • Posts: 398
Re: Software reset
« Reply #1 on: August 25, 2014, 04:54:05 am »
declare the following function:
Code: [Select]
void(* resetDigispark) (void) = 0;and call it, where you want
Code: [Select]
resetDigispark();

redridinghood74

  • Newbie
  • *
  • Posts: 7
Re: Software reset
« Reply #2 on: October 13, 2017, 04:23:00 pm »
Code: [Select]
byte i;
void(* resetDigispark) (void) = 0;
void setup() {
  pinMode(1, OUTPUT);
}
void loop() {
  digitalWrite(1, HIGH);
  delay(i);               // wait for a second
  digitalWrite(1, LOW);
  delay(i);               // wait for a second
  i++;
  if (i >= 100) {
    i = 0;
    resetDigispark();
  }
}

Seems to restart once, but nothing is blinking, tried so many ways :(

redridinghood74

  • Newbie
  • *
  • Posts: 7
Re: Software reset
« Reply #3 on: October 14, 2017, 02:01:06 am »
Somehow, there are some clones amongst the originals (or most accurate clones) hmmm  :o

This absolutely works on original & not on fakes  >:(

redridinghood74

  • Newbie
  • *
  • Posts: 7
Re: Software reset
« Reply #4 on: October 16, 2017, 04:17:43 am »
After further study, this does not work on clones with firmware 1.0.6 aka 1.6. Happily works with 1.11 upgrade.