There are a TON of explorations I did here, many may be unnecessary, but this is a stake in the ground.
The main issue was the strange queue logic in canconmanager::sendFrame which puts the tx data in the rx
queue so it will show up in the displayed data. It caused SIGABRT and SIGSEG to show up everywhere.
It is NOT fixed yet, but TX works over the wire you just can't see it in the tableview.
I thought at first it was only when overwrite data was active, so I put in a a pile of changes to keep
frames and filtered frames as two seperate copies of data where frames was always complete and filtered
was only what was seen in the mainwindow. It made it so the graphing window would work with overwrite
data active which is an improvement. I wouldn't roll these changes back. Because of these changes I
had to update the frame sorting code adjust the refresh function in canframemode.cpp
I also thought it was related to UI updates, but its not, that's been confirmed.
I put a mutex around the custom sender tick timer so that the 1ms timer wouldn't re-enter its callback.
This didn't fix the crash, but it sure seems to make a lot of sense, and the way I did it no elasped
time is lost for tracking purposes, and in reality theres no way 1ms was consistent anyway.
I put a mutex around the shrinking of frames and filteredframes to make sure we weren't deleting at
the same time as accessing, but honestly we acccess those lists in many places without semaphores so
that probably did nothing.
Fixed a bug in FrameSenderWindow:DoModifiers that was improperly parsing and sometimes crashing when
looking for the ~ operator before a symbol.
Also added some minor work to keep row expansion functioning when changing filters or sorting. Need
to make some tweaks so it stops trying so hard when overwrite is not active
Theres also code in main.c taht makes debugging output super verbose.
Committing now to start cleanup
More standard way of looking at parsed data
Handles multiple message types. Each message gets its own columns.
With many message types there are a lot of blank cells but its easy to
analyze.
now working with multiple active busses.
Removed commented out test code and put a fix in for for
the filters list not having its capacity properly reserved
in recalcOverwrite so multiple entries of the same message
show up in the filtered view
No longer tossing partial frames, saving the data to concat with future data.
On startup there can be some data loss, but after it gets rolling there is none.
Added rough provision to ensure the buffer doesn't get filled with bad data, but
the decodeFrames recursive calls do a pretty good job of getting rid of it so I
haven't seen the buffer grow after millions of frames coming over a UDP-based VPN.
Added disabled filenames in node combobox so you can understand what is what
Added node column to table
Made table columns sortable so you can sort by node name or message name
Want to make table fixed width font capable
Want to make table rearrangable
Want to make table rows shorter to fix more info in a window
Want to make it possible to have multiple signal viewer windows
Want to add ability to click on signals and add them to graphs like the main window
my custom code. The issue that made me go down this path
is related to the little endian checkbox mysteriously and
inconsistently unchecking and therefore interpreting enum values
wrong...would really like to find this.
Masked error caused by saving dbc while editor is open that causes
msg IDs to go crazy by making editor modal, but that affects all
other windows, so might be a better fix.
Added new value type of VALUE_STRING, probably better named
ENUMERATED_STRING, and it uses the table in the editor to define
the enum.
Fixed a bug in the signal viewer load when a signal is not matched
(I found it by renaming a signal and then loading)
when adjusting filters due to appending a QVector of frames which
appears to change the capacity to the number of items appended.
Also fixed bug where preallocsize was being locally defined and
therefore the global version wasn't being updated with unknown
effets.
to be 99% of the capacity instead of 95%.
Reset initial capacity to be 10M frames for 64-bit machines now that testing is done.
Want to make the capacity adjustable by user, too.
Sometimes when opening socketcand 1 or more busses won't start right and there's a ton of debug data saying "received datagramm: ...."
It seems to happen because the switch to RAW mode is in progress and we receive the OK with a frame in the same datagramm and we don't parse the OK out of the string
but rather expect the whole string to just be OK. Offending code is in socketcand.cpp SocketCANd::procRXData line 386
Fixed by looking to see if the < ok > message was at index 0 of the incoming message...could also look for it elsewhere (as in index != -1), but not sure if necessary
passing in the name and comment concatenated together. Made a new function to
find by name+comment since extracting only name from the text in the column would
require too much guessing.