System settings/configuration saving and loading


I have FEZ Cobra. I am doing Home automation project. I need a way to save and load many parameters from persistent storage (either ExtendedWeakReference (unfortunately this behaves very strangely, so I prefer SD) or SD).

Type of parameters I need to use: int, float, double, byte, string, arrays of (int, float, double, byte, string, object), objects with object and arrays.

I have already implemented JSON standard (because many data are exchanged via web interface), but I have efficiency problem on loading data. Loading 70 files 15kB all together with recreation of program objects takes about 20 seconds, which is too long:

  1. Finally it will be at least 2 times bigger.
  2. It is too long to wait after device reset (during development/debugging or by watchdog reset).
    This approach requires:
  3. byte to UTF8 String decoding
  4. non-String values converting
  5. JSON parsing.

My question is:
How to load (kind of deserialize) many objects like 200 and more in a quick way (where objects has other objects).

Using RLP is applicable.

Thanks in advance.