/dtv

Device Tree Visualizer

Primary LanguagePerl

Device Tree Visualizer

Differences with upstream: These are just minor changes i made for myself, all good logic is by bmx666 & TheCodeArtist

Opening repeated file dialogs in last chosen directory

Saving list of recently opened files

Not creating temporary/cache files in $(cwd)

And a wild suggestion, maybe have a symlink in /usr/local/bin/dtv to dtv.py (the paths have been updated so this will work fine)

Only .dts files supported, rest will cause panic :)

screenshots

DTV with original dtc

DTV with original dtc

DTV with patched dtc

DTV with patched dtc

requirements

  1. python3 -m pip install -r requirements.txt
    for Ubuntu 16.04: in requirements.txt set PyQt5==5.14.0
  2. cpp >= 5.4.0
  3. dtc >= 1.5.0 (must support --annotate flag) or patched dtc

Patched dtc version add extra annotate flags:

  • show full list of sources for properties
  • prepend comment /* __[|>*DELETED*<|]__ */ for deleted nodes, labels or properties and comment out them all
  • mark all childs of deleted nodes as deleted and do not remove childs

config file - dtv.conf

  • set your preferred editor in env editor_cmd
  • include extra dts paths into list include_dir_stubs

overlays

Linux

/ {
  fragment@0 {
    target = <&some_node>;
      __overlay__ {
        some_prop = "okay";
        ...
      };
  };
};

TBD: automatically apply overlays

Android

Google strongly recommends you do not use fragment@x and syntax __overlay__, and instead use the reference syntax. For example:

&some_node {
  some_prop = "okay";
  ...
};

Solution for display final overlays

Include base and overlays into temporary dts-file and remove from overlays /dts-v1/; and /plugin/;

#include "base.dts"
#include "overlay1.dts"
#include "overlay2.dts"

TBD: automatically generate temporary file

See more