emhell: Embedded shell

This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.

[maintain] [Publish]

Warnings:

Tooling for register exploration using SVD files and GDB-MI or OpenOCD backends


[Skip to Readme]

Properties

Versions 0.1, 0.1, 0.1.1.0
Change log CHANGELOG.md
Dependencies attoparsec, base (>=4 && <5), data-default-class, data-svd (>=0.1.1), directory, emhell, haskeline, hgdbmi (>=0.3), hocd (>=0.1.1.1), optparse-applicative, repline (>=0.4.0.0 && <0.5), text, transformers, unix [details]
License BSD-3-Clause
Copyright (c) 2020 sorki <srk@48.io>
Author sorki <srk@48.io>
Maintainer sorki <srk@48.io>
Category Embedded
Home page https://github.com/srk/emhell
Bug tracker https://github.com/srk/emhell/issues
Source repo head: git clone git://github.com/DistRap/emhell.git
Uploaded by srk at 2023-12-27T14:46:17Z

Modules

Flags

Automatic Flags
NameDescriptionDefault
hgdb

Build hgdb

Disabled

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees


Readme for emhell-0.1

[back to package description]

GitHub Workflow Status Hackage version Dependencies

emhell

Embedded development could be hell without a good tooling!

Applications

emhell

emhell is a SVD (System View Description) register browser

hocd

hocd is a register viewer utilizing OpenOCD as a backend using hocd

hgdb

hgdb is a register viewer and a GDB frontend, built on top hgdbmi

Inspecting registers

To use arm-none-eabi-gdb with BlackMagicProbe available via /dev/bmp launch hgdb in following manner

hgdb --arm --bmp /dev/bmp --svd ~/svd2ada/CMSIS-SVD/Cortex_M/cm4f.svd

You can then inspect registers via REPL using their names (tab completion available) delimited by comma, e.g.

λ> scb.scr
Register SCR
- System Control Register
- Address 0xE000ED10 (including offset 0x10)

0000000004
0x00000004
0b00000000000000000000000000000100
0b0000 0000 0000 0000 0000 0000 0000 0000 0100
Bit 2 SLEEPDEEP


+-------+---------+-+---------+-----------+-+
|◦[26:0]|SEVONPEND|◦|SLEEPDEEP|SLEEPONEXIT|◦|
+-------+---------+-+---------+-----------+-+
|   0   |    0    |0|    1    |     0     |0|
+-------+---------+-+---------+-----------+-+

Command line options

For full list refer to hgdb --help

Internal commands

All other REPL commands are forwarded to GDB as CLI input.

Build

Using Cabal

git clone https://github.com/DistRap/emhell
cabal build

Using Nix

nix-build

Notes

The interface is not final and will probably change. With more recent Gdb than currently available on distributions we could also do completion for function names and variables (requires -symbol-list-functions and -symbol-list-variables).

Demo

asciicast