Skip to content

stdio_rtt: Convert to ztimer#17122

Merged
fjmolinas merged 4 commits intoRIOT-OS:masterfrom
bergzand:pr/stdio_rtt/ztimer
Dec 7, 2021
Merged

stdio_rtt: Convert to ztimer#17122
fjmolinas merged 4 commits intoRIOT-OS:masterfrom
bergzand:pr/stdio_rtt/ztimer

Conversation

@bergzand
Copy link
Copy Markdown
Member

@bergzand bergzand commented Nov 3, 2021

Contribution description

Convert stdio_rtt to ztimer

Testing procedure

Tested on the nRF52840dk by adding USEMODULE += stdio_rtt to the default example:

koen@morgen ~/dev/RIOT-review $ make -C examples/default/ BOARD=nrf52840dk RIOT_TERMINAL=jlink term                 
make: Entering directory '/home/koen/dev/RIOT-review/examples/default'                                              
/home/koen/dev/RIOT-review/dist/tools/jlink/jlink.sh term-rtt                                                       
### Starting RTT terminal ###                                                                                       
help                                                                                                                
Twisted not available, please install it if you want to use pyterm's JSON capabilities
2021-11-03 11:18:26,828 # Host name for TCP connection is missing, defaulting to "localhost"                        
2021-11-03 11:18:26,828 # Connect to localhost:19021                                                                
Welcome to pyterm!                                                                                                  
Type '/exit' to exit.                                                                                               
2021-11-03 11:18:27,831 # SEGGER J-Link V6.80c - Real time terminal output                                          
help                                                                                                                
2021-11-03 11:18:27,832 # J-Link OB-SAM3U128-V2-NordicSemi compiled Mar 17 2020 14:43:00 V1.0, SN=683806234
2021-11-03 11:18:27,832 # Process: JLinkExe                                                                         
2021-11-03 11:18:27,833 # NETOPT_RX_END_IRQ not implemented by driver                                               
2021-11-03 11:18:27,833 # NETOPT_TX_END_IRQ not implemented by driver                                               
2021-11-03 11:18:27,833 # main(): This is RIOT! (Version: 2022.01-devel-324-g1aa18-pr/stdio_rtt/ztimer)             
2021-11-03 11:18:27,833 # Welcome to RIOT!                                                                          
> 2021-11-03 11:18:27,866 # help                                                                                    
2021-11-03 11:18:27,867 # Command              Description                                                          
2021-11-03 11:18:27,867 # ---------------------------------------                                                   
2021-11-03 11:18:27,867 # reboot               Reboot the node                                                      
2021-11-03 11:18:27,867 # version              Prints current RIOT_VERSION                                          
2021-11-03 11:18:27,868 # pm                   interact with layered PM subsystem                                   
2021-11-03 11:18:27,868 # ps                   Prints information about running threads.                            
2021-11-03 11:18:27,868 # random_init          initializes the PRNG                                                 
2021-11-03 11:18:27,869 # random_get           returns 32 bit of pseudo randomness                                  
2021-11-03 11:18:27,869 # ifconfig             Configure network interfaces                                         
2021-11-03 11:18:27,869 # txtsnd               Sends a custom string as is over the link layer                      

Issues/PRs references

Ticks item off #17111

@bergzand bergzand requested a review from jia200x as a code owner November 3, 2021 10:22
@bergzand bergzand requested a review from fjmolinas November 3, 2021 10:22
@github-actions github-actions bot added Area: build system Area: Build system Area: doc Area: Documentation Area: sys Area: System labels Nov 3, 2021
@bergzand bergzand added Type: cleanup The issue proposes a clean-up / The PR cleans-up parts of the codebase / documentation CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Area: sys Area: System and removed Area: doc Area: Documentation Area: build system Area: Build system Area: sys Area: System labels Nov 3, 2021

ifneq (,$(filter stdio_rtt,$(USEMODULE)))
USEMODULE += xtimer
USEMODULE += ztimer_msec
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
USEMODULE += ztimer_msec
USEMODULE += ztimer_msec

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Thanks, force-pushed it in

Copy link
Copy Markdown
Contributor

@fjmolinas fjmolinas left a comment

Choose a reason for hiding this comment

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

There is a coccinelle warning I don't quite get? Does it want the buffer to have an underscore?

@bergzand bergzand force-pushed the pr/stdio_rtt/ztimer branch from e505836 to 197fd69 Compare November 3, 2021 10:28
@github-actions github-actions bot added Area: build system Area: Build system Area: doc Area: Documentation labels Nov 3, 2021
@bergzand
Copy link
Copy Markdown
Member Author

bergzand commented Nov 3, 2021

There is a coccinelle warning I don't quite get? Does it want the buffer to have an underscore?

It wants the static removed from the declaration. I don't think adding an underscore helps, it put a similar comment here where the variable name already starts with an underscore

Copy link
Copy Markdown
Contributor

@fjmolinas fjmolinas left a comment

Choose a reason for hiding this comment

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

ACK, test output provided.

@fjmolinas fjmolinas added this to the Release 2022.01 milestone Nov 18, 2021
@fjmolinas fjmolinas added CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR and removed CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Nov 18, 2021
@github-actions github-actions bot added the Area: tests Area: tests and testing framework label Nov 18, 2021
@fjmolinas
Copy link
Copy Markdown
Contributor

@bergzand can you do the same as 0433548 for the tests with conflicts?

@bergzand bergzand force-pushed the pr/stdio_rtt/ztimer branch from 546b94d to 11ac994 Compare December 7, 2021 09:08
@bergzand bergzand requested a review from miri64 as a code owner December 7, 2021 09:08
@bergzand
Copy link
Copy Markdown
Member Author

bergzand commented Dec 7, 2021

@bergzand can you do the same as 0433548 for the tests with conflicts?

rebased and pushed a similar commit

@fjmolinas fjmolinas merged commit 9e5facf into RIOT-OS:master Dec 7, 2021
@bergzand bergzand deleted the pr/stdio_rtt/ztimer branch December 7, 2021 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: build system Area: Build system Area: doc Area: Documentation Area: sys Area: System Area: tests Area: tests and testing framework CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: cleanup The issue proposes a clean-up / The PR cleans-up parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants