|Anonymous | Login | Signup for a new account||2019-12-13 11:05 UTC|
|Main | My View | View Issues | Roadmap | Repositories|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0000053||Firmware||Analogue Inputs||public||2008-11-15 16:34||2011-11-22 12:18|
|Target Version||0.2.X||Fixed in Version|
|Summary||0000053: Add Important Variables Into Structs And Refactor Placement Of Existing Ones|
|Description||Some variables are in places that they do not belong.|
Many variables don't exist yet.
I should go through them in conjunction with the datalog thread and tidy them up a bunch.
If the other issue turns out to be a goer and the format changes, it would be a good opportunity to place them in order into separate memory regions such that a direct copy from RAM Is possible with minimal CPU overhead.
|Tags||No tags attached.|
|Risk of Breakage||medium|
To clarify what I meant by separate RAM region :
Set aside a piece of global RAM and pre init it with header data. After the header data block would be the various structs placed sequentially such that when a datalog needs to be sent it is a single memcpy() call of maximal efficiency only.
| header | struct 1 | struct 2 | struct n -1 | struct n | normal RAM ....
then the memcpy call can just take the configured length and it is single stage with no excessive ifs etc. Once it is in the serial buffer a normal checksum and send call can be made.
|The previous comment is no longer relevant, but I'd still like to go through the code and ensure all vars that are not local are neatly arranged into groups, and inside structs where appropriate.|
Just pulled out of the source, verbatim:
// TODO various new structs
// Status struct
// Ignition struct
// Injection struct
// Engine position struct
// Validity flags, or they should be in the status struct?
|Placement is now good, though still need to add randomly spread vars to said structs to keep things neat and efficient, so leaving open.|
|Copyright © 2000 - 2011 MantisBT Group|