Cerbuino throws error at first change

Hi All,

just got my first gadgeteer (Cerbuino) flashed it to the latest firmware (2x) comfirmed the via mfdeploy wanted to start my first test by setting on/off the on board led in a timer event. but experience a nice error, what am I doing wrong …

Gadgeteer 4.2

You are not trying to run it in the Emulator by any chance?

Nope, to device directly

Do you know if you have QFE2 on your system?

Yep I’m pretty sure …

Remove all references and only add the ones that are needed.

Well, I have started a brand new project and made no change just hit F5 and no probs … didn’t do much but didn’t fail either … could be I’m directly trying to access the on board led

… somewhere in main program …

public static OutputPort led = new OutputPort(Pins.LED, false);

where Pins.LED is in some class found as:

public const Cpu.Pin LED = (Cpu.Pin)0x12; // PB2/BOOT1

Please show exactly where in main you do that?

If you do that before the Mainboard is created then that may be the reason.

Anyways you should access onboard led using Mainboard’s SetDebugLED method.

In non-Gadgeteer project you can use OutputPort.

See screenshot for details…

Yes remove that OuputPort declaration and it will work.

Don’t use OutputPort for onboard led in Gadgeteer project. Use MainBoard method I have mentioned in my previous post.

Ooohhhh man, what was I thinking of … hoped my coding experiences on Panda-II and Cobra 1 is 1:1 usable … well I’ve got some reading to do …

Thx 4 ur help in this … it works now … the blinking led … up to the rest …

It’s midnight over here so I’m hitting my pillow … wish you the best …



You are welcome!

There is nothing wrong about using OutputPort for a led and your experience is good.

It just the onboard led is already “taken” by another OutputPort inside Mainboard class in Gadgeteer.