Quantcast
Channel: SparkFun Electronics Forum
Viewing all articles
Browse latest Browse all 82

Processor Boards • Re: Trouble getting started with SparkFun Blues Wireless MicroMod Starter Kit -STM32F405 no serial port?

$
0
0
You can add some minor checks to your code. Open the Serial Monitor in the Arduino IDE to check for any debug messages printed by your sketch. This will help you see if the Notecard is being initialized and if requests are being sent.
Code: 
#include <Notecard.h>#define productUID "com.gmail.Meo.DDR:feed_connect"#define usbSerial SerialNotecard notecard;void setup() {  delay(2500);  // Initialize serial communication  usbSerial.begin(115200);  while (!usbSerial) {    ; // wait for serial port to connect  }  usbSerial.println("Starting Notecard...");  // Initialize Notecard  notecard.begin();  notecard.setDebugOutputStream(usbSerial);  usbSerial.println("Sending request to Notecard...");  J *req = notecard.newRequest("hub.set");  if (req != NULL) {    JAddStringToObject(req, "product", productUID);    JAddStringToObject(req, "mode", "continuous");    notecard.sendRequest(req);    usbSerial.println("Request sent.");  } else {    usbSerial.println("Failed to create request.");  }}void loop() {  // put your main code here, to run repeatedly:}

Statistics: Posted by aliarifat794 — Sat May 18, 2024 12:23 am



Viewing all articles
Browse latest Browse all 82

Trending Articles