Skip to content

tools/jlink: Fix do_term#11604

Merged
cgundogan merged 2 commits intoRIOT-OS:masterfrom
leandrolanzieri:pr/tools/jlink_term_fix
May 29, 2019
Merged

tools/jlink: Fix do_term#11604
cgundogan merged 2 commits intoRIOT-OS:masterfrom
leandrolanzieri:pr/tools/jlink_term_fix

Conversation

@leandrolanzieri
Copy link
Copy Markdown
Contributor

Contribution description

As described in #11343 currently running make term does not work on boards that use J-Link Segger RTT, pyterm cannot connect to the Segger RTT server and it fails. By adding a delay after the server is launched pyterm is able to connect to the specified port.

This PR adds that delay, and also modifies the do_term function so it exits when pressing "Ctrl+C".

Testing procedure

Try to run make term on some board that uses Segger RTT for the terminal (e.g. Ruuvitag, Thingy:52, Hamilton) on master: it should fail. After applying this PR the terminal should work.

e.g.: BOARD=ruuvitag make flash term

Issues/PRs references

Fixes #11343
Fixes #11344
Closes #11341

@leandrolanzieri leandrolanzieri added Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) Impact: minor The PR is small in size and might only require a quick look of a knowledgeable reviewer CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Area: tools Area: Supplementary tools labels May 29, 2019
Copy link
Copy Markdown
Member

@cgundogan cgundogan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sleep appears to be necessary. Otherwise, JLink is invoked before the server is started. Also 👍 for calling the cleanup function on INT events. This makes Ctrl+C possible. ACK

@cgundogan cgundogan added Reviewed: 1-fundamentals The fundamentals of the PR were reviewed according to the maintainer guidelines Reviewed: 2-code-design The code design of the PR was reviewed according to the maintainer guidelines Reviewed: 4-code-style The adherence to coding conventions by the PR were reviewed according to the maintainer guidelines Reviewed: 5-documentation The documentation details of the PR were reviewed according to the maintainer guidelines labels May 29, 2019
@cgundogan cgundogan merged commit 500d2ce into RIOT-OS:master May 29, 2019
@leandrolanzieri leandrolanzieri deleted the pr/tools/jlink_term_fix branch May 29, 2019 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: tools Area: Supplementary tools CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Impact: minor The PR is small in size and might only require a quick look of a knowledgeable reviewer Reviewed: 1-fundamentals The fundamentals of the PR were reviewed according to the maintainer guidelines Reviewed: 2-code-design The code design of the PR was reviewed according to the maintainer guidelines Reviewed: 4-code-style The adherence to coding conventions by the PR were reviewed according to the maintainer guidelines Reviewed: 5-documentation The documentation details of the PR were reviewed according to the maintainer guidelines Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RTT: make test not working RTT: make term without make debug

2 participants