Skip to content
This repository has been archived by the owner on Sep 20, 2022. It is now read-only.

RIOT-OS Submodule : Update to 2022.07 release #78

Merged
merged 6 commits into from
Sep 19, 2022

Conversation

akshaim
Copy link
Member

@akshaim akshaim commented Sep 6, 2022

Update the submodule version. Apparently, release managers forget about this.

Disclaimer I could not test the existing applications. I wanted to update the submodule so that I can use the latest boards.

@akshaim
Copy link
Member Author

akshaim commented Sep 6, 2022

ping @miri64

@MrKevinWeiss
Copy link

Maybe we can do this automatically? One less thing for the release manager to worry about.

@miri64
Copy link
Member

miri64 commented Sep 6, 2022

Maybe we can do this automatically? One less thing for the release manager to worry about.

At least opening a PR should (that then runs the tests introduced in #79), should be doable with the RIOT-release-manager script

@MrKevinWeiss
Copy link

It seems like it is not the correct commit, at least when I checked...

diff --git a/RIOT b/RIOT
index 81a01df..72b14ac 160000
--- a/RIOT
+++ b/RIOT
@@ -1 +1 @@
-Subproject commit 81a01df5d94729b8d8a2be7ce8e68f9fc7c7b95f
+Subproject commit 72b14ac73c6fc26e1be53a4da5cd17924b9387b3

The signature changed; no need for changes in code as the context
argument is discarded anyway.
@chrysn
Copy link
Member

chrysn commented Sep 16, 2022

An idea raised in today's coordination meeting was to just move the applications in with the examples -- IMO they're occupying points in the space spanned by what is in the examples already.

For that, it'd be good to have this in (and yes, the revision is incorrect, but the precise version matters little, and if we went through with the move it'd become moot).

I'm taking the liberty to add a few fixes right inside this PR; they make the code buildable again after API changes.

The ztimer64_xtimer_compat module is not automatically enabled when
ztimer provides xtimer compatibility.
The ztimer64_xtimer_compat module is not automatically enabled when
ztimer provides xtimer compatibility. It does not provide the
xtimer_usec_from_ticks64 function, but that was not particularly used
anyway. A header file became unavailable but was not needed.
chrysn added a commit to chrysn-pull-requests/RIOT that referenced this pull request Sep 16, 2022
This merges changes proposed in
<RIOT-OS/applications#78> into the tree of
<RIOT-OS#18602>, and thus fixes building
with the latest RIOT version.
@@ -16,6 +16,7 @@ USEMODULE += shell
USEMODULE += shell_commands
Copy link
Member

Choose a reason for hiding this comment

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

USEMODULE += gnrc_netdev_default

is deprecated in 2022.07. Please use netdev_default instead.

spectrum-scanner/Makefile Outdated Show resolved Hide resolved
Copy link
Member

@miri64 miri64 left a comment

Choose a reason for hiding this comment

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

(and in coap-chat/Makefile as well...)

@miri64
Copy link
Member

miri64 commented Sep 19, 2022

I had some diff lying around for my demo that I meant to PR. Maybe it still fits in this PR (it also contains an unrelated change of the sniffer tool to work properly with python 3):

diff --git a/sniffer/Makefile b/sniffer/Makefile
index 7c2e39a..72a24db 100644
--- a/sniffer/Makefile
+++ b/sniffer/Makefile
@@ -10,13 +10,12 @@ RIOTBASE ?= $(CURDIR)/../RIOT
 # Define modules that are used
 USEMODULE += fmt
 USEMODULE += gnrc
-USEMODULE += gnrc_netdev_default
 USEMODULE += auto_init_gnrc_netif
+USEMODULE += netdev_default
 USEMODULE += shell
 USEMODULE += shell_commands
 USEMODULE += ps
-USEMODULE += xtimer
-USEMODULE += ztimer64_xtimer_compat
+USEMODULE += ztimer64_usec
 
 # Change this to 0 show compiler invocation lines by default:
 QUIET ?= 1
diff --git a/sniffer/main.c b/sniffer/main.c
index 3f48a3b..32d241a 100644
--- a/sniffer/main.c
+++ b/sniffer/main.c
@@ -23,10 +23,11 @@
 #include <stdio.h>
 
 #include "fmt.h"
+#include "net/gnrc.h"
 #include "thread.h"
-#include "xtimer.h"
 #include "shell.h"
-#include "net/gnrc.h"
+#include "shell_commands.h"
+#include "ztimer64.h"
 
 /**
  * @brief   Buffer size used by the shell
@@ -62,7 +63,7 @@ void dump_pkt(gnrc_pktsnip_t *pkt)
             pkt = gnrc_pktbuf_remove_snip(pkt, pkt->next);
         }
     }
-    uint64_t now = xtimer_now64();
+    uint64_t now_us = ztimer64_now(ZTIMER64_USEC);
 
     print_str("rftest-rx --- len ");
     print_u32_hex((uint32_t)gnrc_pkt_len(pkt));
diff --git a/sniffer/tools/sniffer.py b/sniffer/tools/sniffer.py
index 98b9600..8f44868 100755
--- a/sniffer/tools/sniffer.py
+++ b/sniffer/tools/sniffer.py
@@ -56,10 +56,10 @@ DEFAULT_BAUDRATE = 115200
 def configure_interface(port, channel):
     line = ""
     iface = 0
-    port.write(b'ifconfig\n')
+    port.write('ifconfig\n'.encode())
     while True:
         line = port.readline()
-        if line == '':
+        if line == b'':
             print("Application has no network interface defined",
                   file=sys.stderr)
             sys.exit(2)

@miri64 miri64 mentioned this pull request Sep 19, 2022
3 tasks
@chrysn
Copy link
Member

chrysn commented Sep 19, 2022

I've pushed the deprecated module changes. The sniffer changes probably conflict with #61, leaving them as is.

Comment on lines 14 to +15
USEMODULE += xtimer
USEMODULE += ztimer64_xtimer_compat
Copy link
Member

Choose a reason for hiding this comment

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

Why not use ztimer64 outright?

Copy link
Member

Choose a reason for hiding this comment

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

Works just as well, now using that.

Copy link
Member

Choose a reason for hiding this comment

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

Mhhh I accidentally commented on the wrong file, but you fixed it for the correct one ^^, but I guess the same question is true for spectrum-scanner too.

Copy link
Member

Choose a reason for hiding this comment

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

There there's a concrete reason: It does arithmetic on the ztimer values (rather than just showing them), and that has prerequisites that are not met.

(Strictly speaking that's also the case for the one where I've changed it, but there it's timestamps that are merely being displayed, so shrug)

@miri64
Copy link
Member

miri64 commented Sep 19, 2022

Mhhh for some reason the sniffer application does not list an interface anymore with the commit the RIOT submodule currently points to :-/. Nevermind PBCAK...

@miri64
Copy link
Member

miri64 commented Sep 19, 2022

Tested all applications, they all still seem to work (not 100% sure about the spectrum-scanner, as it seems to output always ~90% at my location for all channels).

@miri64 miri64 merged commit 058a56f into RIOT-OS:master Sep 19, 2022
chrysn added a commit to chrysn-pull-requests/RIOT that referenced this pull request Sep 20, 2022
chrysn pushed a commit to chrysn-pull-requests/RIOT that referenced this pull request Sep 20, 2022
RIOT-OS Submodule : Update to 2022.07 release
@akshaim akshaim deleted the update-submodule branch September 30, 2022 10:44
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants