Has anyone been able to serial communicate to the CubeCell from another board?
Sorry for the long post but the serial journey with CubeCell has been complicated for me.
I have been trying to get my Teensy to talk to my Cubecell board (teensy = touch sensors and a homemade NE555 timer). My first issue was scrambled serial data with my CubeCell plugged into my computer. I resolved this issue by lowering the baud rate and added a slight delay(9) to my serial read command. So far so good. Works when Cubecell is plugged into my computer and sending long messages.
With the above fixed I happily plug both boards together and try to send some data but this does not work as expected. The Teensy is connected to the CubeCell via an OTA USB cable (male to male). However if I serial.print from Teensy I do not see any messages reaching the Cubecell. Just a simple serial.print on the Teensy and a serial.read on the CubeCell. I tried this on 2 different Teensy and Cubecell board combinations with no luck. So then I keep connected the 2 boards via OTA USB cable AND connect the boards’ vss and ground pins AND RX/TX pins from Teensy to the Cubecell PINS 7/8 (fyi these are the grayed out RX/TX pins in the pinout diagram). These 2 pins for RX/TX on the Cubecell apparently do not do anything as the Cubecell chip only has 1 UART (the USB). That is why I tried just to connect these boards via the OTA cable. When this did not work I decided to try the RX/TX method. FYI I use RX/TX comms for another project but to the Heltec ESP32 to Teensy RX/TX with no issues - works perfectly. To my surprise the CubeCell was able to communicate with the Teensy using the RX/TX for a short period of time, please read below.
During my testing using both boards connected via OTA USB cable, RX/TX pins, and +/- I discovered the following odd behavior. With the 2 board connected as described above if I unplug the Cubecell USB from the Teensy then plug the Cubecell into my computer, (with the RX/TX +/- still attached) then open the serial monitor and send any character via serial monitor I see the message getting to my Cubecell unscrambled (as expected) from the computer, BUT if at this point I unplug my CubeCell from the computer…this is the weird part…I get data sent to my CubeCell via PINS 8/9 with no USB cable attached! Yes just RX/TX pins 8/9 and +/- attaching the 2 boards. After some time however the messages stop coming over from Teensy to CubeCell. After this “timeout” I plug the Cubecell back into the computer and open the serial monitor I get Java lang NullPointer exception related to serial write. If I repeat this exercise to get the serial messages flowing but BEFORE the timeout click the reset button on the Cubecell I then have to unplug the boards again, plug the Cubcell back into my computer, open the serial monitor and send another test message to “prime” the serial communications.
Is there an easier way to serial communicate to the Cubecell from another custom board?