Hello, this problem began last night as I was trying to clean up my Teensy's code a little bit. I'm using a microcontroller sending Serial MIDI via UART (Axoloti only receives midi messages, doesn't send).
I have 12 pots controlled via UART, which worked fine, but they were previously listed individually in the code (like a long ugly chain of 12 separate midi control change messages), so I wanted to turn them into an array. The ultimate goal was to clean it up in order to send MIDI messages to different channels in the microcontroller. Didn't get that far because I wanted to see if the array worked first.
As a note, the old code includes an Adafruit Trellis (with a button array), which I left out of the new code for now while I tested the pots.
The code uploaded to the Teensy and everything, tested the serial print, and it all looked fine. Opened the software, connected the Axoloti, opened a patch in which I created 4 dials to test the top row of pots with, and I got this when trying to go live:
Generate code complete
Disconnect request
This naturally caused the Axoloti to disconnect. When clicking "connect" again on the Axoloti main window, there's a long pause, and then this error:
connected
java.lang.Exception: cpuserial has wrong length
java.lang.Exception: cpuserial has wrong length
at axoloti.HWSignature.Verify(HWSignature.java:111)
at axoloti.USBBulkConnection.connect(USBBulkConnection.java:315)
at axoloti.MainFrame.jCheckBoxConnectActionPerformed(MainFrame.java:727)
at axoloti.MainFrame.access$500(MainFrame.java:89)
at axoloti.MainFrame$8.actionPerformed(MainFrame.java:521)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2348)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
at javax.swing.JToggleButton$ToggleButtonModel.setPressed(JToggleButton.java:308)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:252)
at java.awt.Component.processMouseEvent(Component.java:6533)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
at java.awt.Component.processEvent(Component.java:6298)
at java.awt.Container.processEvent(Container.java:2236)
at java.awt.Component.dispatchEventImpl(Component.java:4889)
at java.awt.Container.dispatchEventImpl(Container.java:2294)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4888)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4525)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4466)
at java.awt.Container.dispatchEventImpl(Container.java:2280)
at java.awt.Window.dispatchEventImpl(Window.java:2746)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:90)
at java.awt.EventQueue$4.run(EventQueue.java:731)
at java.awt.EventQueue$4.run(EventQueue.java:729)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
Ping: WaitSync Timeout, disconnecting now
Disconnect request
Ping: WaitSync Timeout, disconnecting now
Ping: WaitSync Timeout, disconnecting now
Strangely, when I reupload the old code (the one that's big and ugly), it works just fine. Patches go live and everything works.
With the new-array-code, I tried removing the controller object in Preferences, and removing the "object" folder, where my controller patch is located, from the file directory. Still got the same result as above. Really not sure what else I should try.
Not sure if worth noting, but this exact same problem happened when I only tried to change the controller from MIDI Channel 1 to Midi Channel 0 in Teensyduino. In this case, the code was identical to the one that currently works reliably, I just changed that one value, which uploaded to Teensy just fine.
Any help would be greatly appreciated. I don't mind using the old ugly settings I have, but I'm only limited to one midi channel on the controller and would rather not create a mess with midi/intern/cc objects!