Coder Social home page Coder Social logo

pyrtt-viewer's Introduction

PyRTT Viewer

Lint status

This is a simple Python 3 script for simple RTT interaction with an nRF5x device.

If you just want to use it directly, you can install using pip:

pip install pyrtt-viewer

Then you can run the script as a normal executable:

pyrtt-viewer -h

Usage

pyrtt-viewer [-s <serial-number>] [-c <rtt-channel>]

If you think you'd like to modify the script a bit, install it as a local package:

pip install -e .

Requirements

  • Python 3.x
  • pynrfjprog -- pip install pynrfjprog

pyrtt-viewer's People

Contributors

mostafaberg avatar thomasstenersen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

pyrtt-viewer's Issues

NRFJPROG DLL: -254 INTERNAL_ERROR

It runs fine on some machines, but on others it fails with this output from Python:

Traceback (most recent call last):
File "pyrtt-viewer-mt-original.py", line 188, in <module>
main()
File "pyrtt-viewer-mt-original.py", line 174, in main
nrf = connect(args.segger_id)
File "pyrtt-viewer-mt-original.py", line 64, in connect
nrf.open()
File "/home/ihor/.local/lib/python3.8/site-packages/pynrfjprog/LowLevel.py", line 177, in open
raise APIError(result, error_data=self.get_errors())
pynrfjprog.APIError.APIError: An error was reported by NRFJPROG DLL: -254 INTERNAL_ERROR.

It runs fine on Ubuntu 20.04, Windows 7, Windows 10.

It fails on few other Ubuntu 20.04, Kubuntu 21.10, and two macOS.

All systems have installed Segger JLink software pack, Nordic Command Line Tools, and pynrfjprog.

RTT-Session not closed after terminate the script (CTRL-Z in terminal)

Session not closed correctly. After termiante / stop the script in the terminal it is not possible to open RTT-viewer again.

The following error occurs:
/pyrtt-viewer$ python3 pyrtt-viewer
Connected devices:
0: 801011524

Select a device number or quit (q): 0
Traceback (most recent call last):
File "pyrtt-viewer", line 185, in
main()
File "pyrtt-viewer", line 171, in main
nrf = connect(args.segger_id)
File "pyrtt-viewer", line 73, in connect
nrf.connect_to_emu_with_snr(snr, jlink_khz)
File "/home/user/.local/lib/python3.8/site-packages/pynrfjprog/LowLevel.py", line 243, in connect_to_emu_with_snr
raise APIError(result)
pynrfjprog.APIError.APIError: An error was reported by NRFJPROG DLL: -102 JLINKARM_DLL_ERROR.

Unable to accept input

I have an NRF device with CLI over RTT. If I connect using JLinkRTTClient or RTTViewer (on Windows), I can interact with the prompt. However using pyrtt-viewer, the device does not appear to receive input. I can see output coming out, so RTT is connected, but any input is not received by the device.

I attempted this on both Mac OSX (High Sierra) and Windows 10. Both behaved the same.

Make device selection easier on Linux/MacOS

On Windows, the nrf.connect_to_emu_without_snr() works well as it pops up the JLink dialog to select the device. However, on MacOS and Linux, there is no such dialog.
Instead, you should be able to get the available devices and select your favorite in some easy way.

pip install pyrtt-viewer fails

Hi,

thanks for providings the rtt viewer, unfortunately installation fails

[ spachner@MacBookPro ] ~
$ pip search pyrtt
pyrtt-viewer (0.1.1)  - A simple script for RTT I/O
[ spachner@MacBookPro ] ~
$ pip install pyrtt-viewer
Collecting pyrtt-viewer
  Could not find a version that satisfies the requirement pyrtt-viewer (from versions: )
No matching distribution found for pyrtt-viewer

Any hints?
regards

spachner

Support nRF53

nRF53 devices are not supported yet. Please check and accept these nRF53-device-family. Python script is working for nRF53 mcus.

Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.