Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Openthread Progress Tracking PR #5

Open
wants to merge 110 commits into
base: openthread
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
110 commits
Select commit Hold shift + click to select a range
e774950
examples/lora/build-RadioLib.sh: remove depenency on /bin/bash
lschuermann Jan 25, 2024
cc1ce16
shell.nix: remove custom GCC & newlib build, remove jlink
lschuermann Jan 25, 2024
df156ea
shell.nix: update to Tockloader v1.11.0
lschuermann Jan 25, 2024
e65854b
Merge pull request #364 from lschuermann/dev/radiolib-bin-bash
bradjc Jan 26, 2024
f445842
Merge pull request #365 from lschuermann/dev/nix-shell-remove-custom-…
bradjc Jan 29, 2024
ae99ddc
AppMakefile: depend on libc++ and newlib for cc,cpp,cxx build rules
lschuermann Feb 3, 2024
f4743c1
GitHub actions CI: run on push events
lschuermann Feb 3, 2024
604c3ce
Merge pull request #367 from lschuermann/dev/fix-ci-libcpp-fetch
bradjc Feb 5, 2024
e29550f
use new exit syscall on process finish
bradjc Aug 20, 2021
9c85f99
exit: use return value of main
bradjc Aug 24, 2021
61f0733
add while(1) yield loops to processes that need it
bradjc Aug 24, 2021
8dddf41
add comments indicating the need for while yield loop
bradjc Aug 25, 2021
2a34097
crt0: explicitly 0 unused argc/argv
ppannuto Aug 27, 2021
84600f0
examples: explicit while(1) yield() if needed
bradjc Jan 24, 2024
4331fbf
format courses/2018-11-SenSys/sensys_udp_rx/main.c
bradjc Feb 6, 2024
1699803
Resolved rollover bug in alarm.c gettimeasticks
tyler-potyondy Jan 31, 2024
6012326
Removed unnecessary header files used for testing
tyler-potyondy Jan 31, 2024
a938d03
updated formatting
tyler-potyondy Feb 3, 2024
8e52148
Merge pull request #366 from tyler-potyondy/alarm-overflow
bradjc Feb 7, 2024
7cc4484
Work on alarm
Samir-Rashid Jan 26, 2024
bc6e886
Add my code
Samir-Rashid Jan 26, 2024
d3f1cc3
entropy. readme
Samir-Rashid Jan 26, 2024
2982fb5
finish alarm (but without locking)
Samir-Rashid Jan 26, 2024
5a4978b
misc and flash are nonblockers
Samir-Rashid Jan 26, 2024
3288e5e
Tyler's `otInstanceInit` build patch
Samir-Rashid Jan 27, 2024
3a0ac70
Fix compiler errors
Samir-Rashid Jan 27, 2024
a58ed89
Add radio debug prints
Samir-Rashid Jan 27, 2024
4266ee9
openthread-system.h is wrong file
Samir-Rashid Jan 28, 2024
711073f
mark unused var, fix printf
Samir-Rashid Jan 28, 2024
db9f050
Hanging issue diagnosed (see below)
Samir-Rashid Jan 28, 2024
3d398bc
100% debug print coverage
Samir-Rashid Jan 28, 2024
9090c3c
force alarm to work (temp workaround)
Samir-Rashid Jan 28, 2024
1e49f82
fix printing order so you can reproduce the issue
Samir-Rashid Jan 29, 2024
dfcdcb6
im bad seconds fix, but ms is still rollover
Samir-Rashid Jan 30, 2024
5a73c12
sample reproduce ms component rollover
Samir-Rashid Jan 30, 2024
548fc2b
refactor alarm implementation
Samir-Rashid Jan 30, 2024
26a82a2
copy micro alarm implementation
Samir-Rashid Jan 30, 2024
0c60078
Implement flash
Samir-Rashid Feb 6, 2024
fab789c
Do not error the radio
Samir-Rashid Feb 6, 2024
d655fd8
Fix alarm to use clock ticks in libtock call
Samir-Rashid Feb 8, 2024
bccf9c4
Add nonvolatile storage comments
Samir-Rashid Feb 8, 2024
22c39d0
Update readme tracking status
Samir-Rashid Feb 8, 2024
ea88bec
System platform file done
Samir-Rashid Feb 8, 2024
9218950
Add newline to fn call prints
Samir-Rashid Feb 8, 2024
df6a893
Fix create_ot-tock shebang
Samir-Rashid Feb 8, 2024
653a296
Add some radio functions, small fixes
Samir-Rashid Feb 8, 2024
eb31a91
Fix building
Samir-Rashid Feb 8, 2024
cafe169
testFlashPAL
Samir-Rashid Feb 8, 2024
312fe55
newlib/libcpp: update commit hash in dockerfile
bradjc Feb 9, 2024
0e72c92
Merge pull request #369 from tock/docker-commit
lschuermann Feb 9, 2024
4314fcf
Merge pull request #246 from tock/use-exit
lschuermann Feb 15, 2024
cf937a9
flash testing application
atar13 Feb 15, 2024
a68d318
removed testFlashPAL from openthread_hello
atar13 Feb 15, 2024
3ef4717
make: tocklibrary: never build with -Werror
bradjc Feb 8, 2024
711a625
header files are for humans only
Samir-Rashid Feb 20, 2024
25218b6
remove patch
Samir-Rashid Feb 20, 2024
91ea715
15.4 send direct implementation
tyler-potyondy Feb 13, 2024
e4e034d
Updated naming from direct to raw
tyler-potyondy Feb 26, 2024
ed8d0b9
Merge pull request #371 from tyler-potyondy/15.4-direct
brghena Feb 27, 2024
c8d7268
skeleton alarm_at_ms
atar13 Mar 2, 2024
38ee4e0
Merge pull request #368 from tock/library-werror
lschuermann Mar 5, 2024
afd7a05
add u8g2 library
bradjc Jan 12, 2024
3785a69
add u8g2-tock.h header
bradjc Jan 14, 2024
f6f6ea6
add circle demo
bradjc Jan 14, 2024
50687ac
add spin demo
bradjc Jan 14, 2024
9774cc7
add tock... scrolling demo
bradjc Jan 14, 2024
1d711ee
add triangle demo
bradjc Jan 14, 2024
6bad69d
add u8g2 tock logo test
bradjc Jan 12, 2024
f4c3b25
add count demo
bradjc Jan 14, 2024
08a23a5
u8g2: fetch and build, support make -j4
bradjc Feb 8, 2024
90dac88
u8g2: avoid error in library compilation
bradjc Feb 16, 2024
88d533e
u8g2: init return error
bradjc Feb 17, 2024
d74af02
u8g2: readme on how to use
bradjc Mar 5, 2024
dec9c2b
u8g2: comment makefile
bradjc Mar 5, 2024
1b65439
u8g2: clean up u8g2-tock, comment
bradjc Mar 5, 2024
3be5477
libtock: screen: make syscall functions public
bradjc Mar 5, 2024
8b2dc67
initial flash with app_state
atar13 Mar 5, 2024
691045f
Merge pull request #363 from tock/u8g2
alevy Mar 10, 2024
8d6e87d
Resolve fetching sha256sum failure
tyler-potyondy Mar 15, 2024
ce27277
Merge pull request #374 from tyler-potyondy/master
bradjc Mar 15, 2024
a12f8a8
Update 15.4 to utilize ring buffer
tyler-potyondy Mar 18, 2024
135aab5
Update 15.4 getters for new metadata size
tyler-potyondy Mar 19, 2024
d99f53f
Remove length arg from 15.4 receive
tyler-potyondy Mar 19, 2024
fad75b8
Update 15.4 test apps for ring buffer
tyler-potyondy Mar 19, 2024
4de0e70
readme: no RISCV flag
bradjc Mar 22, 2024
a63e3b3
Merge pull request #376 from tyler-potyondy/15.4-dev
ppannuto Mar 22, 2024
28f5fc0
Merge pull request #378 from tock/readme-old-riscv-flag
ppannuto Mar 22, 2024
2eceacd
Update elf2tab in nix shell
alevy Mar 22, 2024
e5c540b
Merge pull request #379 from tock/update-nix-shell
alevy Mar 22, 2024
7622872
Revert "initial flash with app_state"
atar13 Mar 23, 2024
af31898
implement ms_to_ticks
atar13 Mar 23, 2024
63c04f0
debugging alarm_at_ms overflow case
atar13 Mar 23, 2024
f3a2c22
nix flake to launch shell
atar13 Mar 23, 2024
4c9c807
Comments
Samir-Rashid Mar 23, 2024
f13e0c3
build(deps): bump express
dependabot[bot] Mar 28, 2024
1f56214
Merge pull request #382 from tock/dependabot/npm_and_yarn/examples/co…
bradjc Apr 2, 2024
f667017
make: tocklib: fix debug comment
bradjc Apr 2, 2024
44bf89c
Merge pull request #388 from tock/make-lib-debug-fix
ppannuto Apr 2, 2024
d0163ad
make: TockLibrary: unconditionaly set build dir
bradjc Apr 2, 2024
f5697ad
clean dirt
Samir-Rashid Apr 3, 2024
faaef90
Fix "No rule to make target ot-tock.a"
Samir-Rashid Apr 3, 2024
48a6e16
u8g2: use paths in src file
bradjc Apr 3, 2024
5aabfcb
switch to timer_in from alarm_at_ms
Samir-Rashid Apr 3, 2024
3c288b5
YIPIE evidence that overflowing timers for timer_in works
Samir-Rashid Apr 4, 2024
1c439e6
Merge pull request #392 from tock/u8g2-src-paths
ppannuto Apr 5, 2024
7a30e46
Merge pull request #390 from tock/make-builddir
ppannuto Apr 5, 2024
44e6a2b
Merge remote-tracking branch 'origin/master' into openthread-WIP
Samir-Rashid Apr 5, 2024
67004cc
Merge changes from "timer: handle timer overflow" PR
Samir-Rashid Apr 6, 2024
b1d50d8
Tyler changes
Samir-Rashid Apr 6, 2024
fe9a1e5
Update shell.nix
Samir-Rashid Apr 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ env:
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
pull_request: # Run CI for PRs on any branch
merge_group:

Expand Down
7 changes: 4 additions & 3 deletions AppMakefile.mk
Original file line number Diff line number Diff line change
Expand Up @@ -107,24 +107,25 @@ $$(BUILDDIR)/$(1):
$$(TRACE_DIR)
$$(Q)mkdir -p $$@


# First step doesn't actually compile, just generate header dependency information
# More info on our approach here: http://stackoverflow.com/questions/97338
$$(BUILDDIR)/$(1)/%.o: %.c | $$(BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1))
$$(TRACE_CC)
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -c -o $$@ $$<

$$(BUILDDIR)/$(1)/%.o: %.cc | $$(BUILDDIR)/$(1)
$$(BUILDDIR)/$(1)/%.o: %.cc | $$(BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1)) libc++-$$(LIBCPP_VERSION_$(1))
$$(TRACE_CXX)
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -c -o $$@ $$<

$$(BUILDDIR)/$(1)/%.o: %.cpp | $$(BUILDDIR)/$(1)
$$(BUILDDIR)/$(1)/%.o: %.cpp | $$(BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1)) libc++-$$(LIBCPP_VERSION_$(1))
$$(TRACE_CXX)
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -c -o $$@ $$<

$$(BUILDDIR)/$(1)/%.o: %.cxx | $$(BUILDDIR)/$(1)
$$(BUILDDIR)/$(1)/%.o: %.cxx | $$(BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1)) libc++-$$(LIBCPP_VERSION_$(1))
$$(TRACE_CXX)
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -c -o $$@ $$<
Expand Down
7 changes: 7 additions & 0 deletions Configuration.mk
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ else ifeq ($(CC_rv32_version_major),13)
else
LIBCPP_VERSION_rv32 := 13.2.0
endif
LIBCPP_VERSION_rv32i := $(LIBCPP_VERSION_rv32)
LIBCPP_VERSION_rv32imc := $(LIBCPP_VERSION_rv32)
LIBCPP_VERSION_rv32imac := $(LIBCPP_VERSION_rv32)
LIBCPP_BASE_DIR_rv32 := $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-$(LIBCPP_VERSION_rv32)

# Set the toolchain specific flags.
Expand Down Expand Up @@ -400,6 +403,10 @@ else ifeq ($(CC_cortex-m_version_major),13)
else
LIBCPP_VERSION_cortex-m := 13.2.0
endif
LIBCPP_VERSION_cortex-m0 := $(LIBCPP_VERSION_cortex-m)
LIBCPP_VERSION_cortex-m3 := $(LIBCPP_VERSION_cortex-m)
LIBCPP_VERSION_cortex-m4 := $(LIBCPP_VERSION_cortex-m)
LIBCPP_VERSION_cortex-m7 := $(LIBCPP_VERSION_cortex-m)
LIBCPP_BASE_DIR_cortex-m := $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-$(LIBCPP_VERSION_cortex-m)

# Based on the toolchain used by each architecture, add in toolchain-specific
Expand Down
5 changes: 5 additions & 0 deletions Precompiled.mk
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,11 @@ $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-12.3.0:
$(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-13.2.0:
cd $(TOCK_USERLAND_BASE_DIR)/lib; ./fetch-libc++.sh 13.2.0

# Helper rule to specify libc++ as a dependency in the libtock-c build system.
libc++-10.5.0: | $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-10.5.0
libc++-12.3.0: | $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-12.3.0
libc++-13.2.0: | $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-13.2.0

# LIBC++ 10.5.0

$(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-10.5.0/arm/arm-none-eabi/lib/thumb/v6-m/nofp/libstdc++.a: $(TOCK_USERLAND_BASE_DIR)/lib/libtock-libc++-10.5.0
Expand Down
5 changes: 5 additions & 0 deletions Program.mk
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,8 @@ program: $(BUILDDIR)/$(PACKAGE_NAME).tab
.PHONY: flash
flash: $(BUILDDIR)/$(PACKAGE_NAME).tab
$(FLASH)

.PHONY: develop
develop: flash
tockloader listen

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ Prerequisites
the LLVM clang compiler. If you have a compatible clang toolchain, you can
add `CLANG=1` to the make command to use clang instead of the default GCC.

$ make RISCV=1 CLANG=1
$ make CLANG=1

This support is only included for RISC-V targets as Cortex-M targets require
the FDPIC support only present in GCC.
Expand Down
8 changes: 4 additions & 4 deletions TockLibrary.mk
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ ifeq ($(strip $($(LIBNAME)_SRCS)),)
endif

# directory for built output
$(LIBNAME)_BUILDDIR ?= $($(LIBNAME)_DIR)/build
$(LIBNAME)_BUILDDIR := $($(LIBNAME)_DIR)/build

# Handle complex paths.
#
Expand Down Expand Up @@ -101,8 +101,8 @@ $$($(LIBNAME)_BUILDDIR)/$(1):

$$($(LIBNAME)_BUILDDIR)/$(1)/%.o: %.c | $$($(LIBNAME)_BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1))
$$(TRACE_CC)
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) -c -o $$@ $$<
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) $$(CPPFLAGS_$(LIBNAME)) -MF"$$(@:.o=.d)" -MG -MM -MP -MT"$$(@:.o=.d)@" -MT"$$@" "$$<"
$$(Q)$$(TOOLCHAIN_$(1))$$(CC_$(1)) $$(CFLAGS) $$(CFLAGS_$(1)) $$(CPPFLAGS) $$(CPPFLAGS_$(1)) $$(CPPFLAGS_$(LIBNAME)) -c -o $$@ $$<

$$($(LIBNAME)_BUILDDIR)/$(1)/%.o: %.S | $$($(LIBNAME)_BUILDDIR)/$(1) newlib-$$(NEWLIB_VERSION_$(1))
$$(TRACE_AS)
Expand Down Expand Up @@ -150,7 +150,7 @@ LIBS_$(1) += $$($(LIBNAME)_BUILDDIR)/$(1)/$(LIBNAME).a
endef

# uncomment to print generated rules
# $(info $(foreach platform,$(TOCK_ARCHS), $(call LIB_RULES,$(call ARCH_FN,$(platform)))))
# $(info $(foreach platform,$(TOCK_ARCHS), $(call LIB_RULES,$(arch))))
# actually generate the rules for each architecture
$(foreach arch,$(TOCK_ARCHS),$(eval $(call LIB_RULES,$(arch))))

Expand Down
4 changes: 4 additions & 0 deletions examples/ble-uart/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,8 @@ int main (void) {
// Advertise the UART service
ble_uuid_t adv_uuid = {0x0001, BLE_UUID_TYPE_VENDOR_BEGIN};
simple_adv_service(&adv_uuid);

while (1) {
yield();
}
}
5 changes: 4 additions & 1 deletion examples/ble_advertising/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,5 +70,8 @@ int main(void) {
// configuration complete
printf("Now advertising every %d ms as '%s'\n", advertising_interval_ms,
device_name);
return 0;

while (1) {
yield();
}
}
5 changes: 4 additions & 1 deletion examples/ble_passive_scanning/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,8 @@ int main(void)
if (err < RETURNCODE_SUCCESS) {
printf("ble_start_passive_scan, error: %s\r\n", tock_strrcode(static_cast<returncode_t>(err)));
}
return 0;

while (1) {
yield();
}
}
4 changes: 3 additions & 1 deletion examples/buttons/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,7 @@ int main(void) {
button_enable_interrupt(i);
}

return 0;
while (1) {
yield();
}
}
4 changes: 4 additions & 0 deletions examples/c_hello/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,9 @@ static void nop(

int main(void) {
putnstr_async(hello, strlen(hello), nop, NULL);
// Because we used the async method (as opposed to something synchronous,
// such as printf), we must explicitly wait for the asynchronous write to complete.
yield();
// Now we are done.
return 0;
}
8 changes: 6 additions & 2 deletions examples/courses/2018-11-SenSys/sensys_udp_rx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,10 @@ int main(void) {
printf("Failed to bind to socket %d\n", result);
break;
}
/* Tock keeps the app alive waiting for callbacks after
* returning from main, so no need to busy wait */
// Note: Prior to 2.0, libtock-c kept apps alive in an implicit busy loop.
// Since 2.0, apps must now explicitly include their own event loop to
// avoid termination.
while (1) {
yield();
}
}
Loading
Loading