Apologies Ralph for my code not compiling. I was sort of expecting it, since I just recalled from memory. I was not using my home PC, so I could not remember the exact code.
Some more experimenting proved this:
Code below:
#include "DigiKeyboard.h"
void setup() {
pinMode(0,OUTPUT);
}
void loop() {
DigiKeyboard.delay(500);
digitalWrite(0,1);
DigiKeyboard.delay(500);
digitalWrite (0,0);
}When I keep the datalines connected with the links, the code will run with only power connected. So it seems that for some reason, the zener diode portion of the hardware should stay connected to the pins. Probably the 1k pull-up resistor on the pin is required. (The links disconnected the zeners and resistors used for to drop the voltage.
Then I loaded my final sketch, kept the links in, but still not running the code. Because of extensive usage of other functions, I will just show some test code - no need to discuss my method of pushing bit level data to EEPROM.

Below the code I am trying out.
#include "DigiKeyboard.h"
#define LED_PIN 0
void setup() {
pinMode(LED_PIN, OUTPUT);
//DigiKeyboard.update();
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.delay(5000);
DigiKeyboard.print("abcd");
}
void loop() {
// DigiKeyboard.update();
digitalWrite(LED_PIN,HIGH);
DigiKeyboard.delay(250);
digitalWrite(LED_PIN,LOW);
DigiKeyboard.delay(250);
}With the same setup links in or out, it won't run. I've added the "Digikeyboard.update();" line as well, but it still won't run.
Editing out these lines
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.delay(5000);
DigiKeyboard.print("abcd");
}
and leaving in
DigiKeyboard.update();
works.
I will add and remove lines one by one and post the results. But now my PC need a reboot, it does not see the Sparky plugged in anymore. It happens from time to time!
