thijse / Arduino-CmdMessenger

CmdMessenger Communication library for Arduino & .NET
Other
208 stars 87 forks source link

Winforms application not receiving messages from arduino #30

Open vramanx opened 7 years ago

vramanx commented 7 years ago

I have a sample winforms application using CmdMessenger connecting at 115200 with DtrEnable set to true. This is running on windows 10 with Arduino getting connected on COM4. The code is based on the Datalogging example

I have the below code in Setup function in the ino file. The winforms application receives the first acknowledge message. But not the second one. Any clues?

void setup() { // Listen on serial connection for messages from the pc Serial.begin(115200);

// Adds newline to every command cmdMessenger.printLfCr();

// Attach my application's user-defined callback methods attachCommandCallbacks();

// Send the status to the PC that says the Arduino has booted cmdMessenger.sendCmd(kAcknowledge,"Arduino has started!");

// set some pin modes pinMode(kBlinkLed, OUTPUT); pinMode(....)

cmdMessenger.sendCmd(kAcknowledge,"Setup Completed"); }