Skip to content

DualTachyon/rk3588-svd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Support

System View Description (SVD) for the RockChip RK3588 SoC

This repository include a rk3588.svd file for use with debuggers/IDEs compatible with such files. It contains definitions for the various peripheral blocks and its registers and bitfields.

This is a work-in-progress and not all peripherals are included yet.

Since editing SVD files directly is very tedious, the contents are generated off a bunch of .def files that describe each register in detail.

The .def files were generated by copy pasting the contents of the TRM PDF and using automation to reformat the layout appropriately. Manual editing and corrections are often necessary since copy from a PDF doesn't preserve layouts properly. "Sublime Text 4" has been a real winner here with its multi-cursor editing. The original RockChip TRM also has inconsistencies with some registers. Together with some of my own and some keyboard accidents, there are bound to be some bitfields that have issues. RockChip inconsistencies have been prefixed with DOC_BUG_ where possible.

Re-generating the SVD

You can re-generate the SVD file with the following invocation:

$ make clean all

Updating registers

You can add/modify/customise the .def files to suit your needs. The format is more or less the following:

[peripheral_name, optional_group_name]

@ base_address, size

# These type of comments do not appear in the resulting SVD.

register_name = offset, optionl_access
# Bitfields are optional
> bit_start, bit_width, name, optional_access ; Comment that goes into SVD as a description
= 0, enum_name1 ; Comment that goes into SVD as a description # Optional
= 1, enum_name2 ; Comment that goes into SVD as a description # Optional

You can use a _ as an enum name if you don't have one for a specific value.

Check existing .def files for examples.

Requirements

Python 3 is required to run the convert-def.py script.

License

Copyright 2024 Dual Tachyon https://github.com/DualTachyon

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published