![]() With PlatformIO and a cheap JTAG debugger off Aliexpress, you can do inline debugging on some boards right in VSCode. PlatformIO is just a build wrapper to make using VSCode easier. Yes, it dies the same if I don't use platformIO. After a bunch of random prints, I found it dies in this function, specifically. The prints are there for debugging, as I'm trying to figure out where this dies. SO than it still gets me back to wondering how you are outputting data to this sketch? Through PlatfromIO? Does it work with Serial Monitor of Arduino?Īlso in cases like this I would probably build a version of it that builds on Arduino and see if it works on it. But as you do it very 200ms would only be 5 per second, so Terminal monitor should work. Mine was more or less yours, other than being outside of the class and I removed your two outside prints that clog up the Terminal monitor waiting for data. Ok it is called in the Dispatch method of command.Īs Paul and I also tried out the calls. I don't see any call to ReadSerialPortData Wait until we get a configuration before we do the rest G_commandSystem = new CommandManager(g_RobotMotors, &g_TimerCounter, &g_PrevTimerCounter, g_sensorSystem, g_safetySystem) G_safetySystem = new SafetyManager(&g_TimerCounter) put your setup code here, to run once: With your function you had some Serial.print statements even when count was 0, which if you are calling constantly could overflow your Serial monitor program. M_commandBuffer += Serial.readStringUntil('~') we got a valid buffer but it's likely fragmented Keep reading until we see the ~ character. SerialBytesRecieved = Serial.available() ReadSerialPortData keeps reading the port until it sees a ~ character, appends what it reads to the command
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |