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

WIP: Add low-level RF send and receive functions #306

Open
wants to merge 37 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
e2033c9
Add functions to clear FIFOs and interrupts
danielschloms Apr 21, 2024
41f74c6
Add MFT code for rf::Send() and make it compile
danielschloms Apr 22, 2024
fb3cdad
Fix typos and add TODO and FIXME comments
PatrickKa Jun 27, 2024
a713fbe
Use void pointers for low-level RF functions
PatrickKa Jun 27, 2024
0cc6cbe
Use "new" SPI interface to make Rf.cpp compile again
PatrickKa Jun 27, 2024
8842114
Add rf::RecieveTestData() from mft branch and make it compile
PatrickKa Jun 27, 2024
60cf90b
Extend Rf.test.cpp by sending a message
PatrickKa Jun 27, 2024
70cf686
Format code
PatrickKa Jun 27, 2024
0c4a997
DEBUG_PRINT() actual baud rate of RF SPI
PatrickKa Jun 27, 2024
f65a7e3
Use WaitForCts() in WriteToFifo()
PatrickKa Jun 27, 2024
18a395e
Add DEBUG_PRINT()s in rf::Send() and rf::WriteToFifo()
PatrickKa Jun 27, 2024
ccf96af
Add rf::ReadDeviceState()
PatrickKa Jun 27, 2024
b410b7e
Add rf::ReadFunctionInfo()
PatrickKa Jun 27, 2024
0df9ae3
Add rf::ReadPartInfo()
PatrickKa Jun 27, 2024
38e58ea
Read and DEBUG_PRINT() answers from GPIO_PIN_CFG command
PatrickKa Jun 27, 2024
7d86407
Add a polling delay of 50 us in WaitForCts()
PatrickKa Jun 27, 2024
8306712
Add DEBUG_PRINT()s to both SendCommand functions
PatrickKa Jun 27, 2024
6c5a9b3
Reorder rf::Read...() in Rf.test.cpp
PatrickKa Jun 29, 2024
fd46f7b
Rename some constants
PatrickKa Jun 29, 2024
1399819
Configure pins of RF module only once at the beginning
PatrickKa Jun 29, 2024
0fbb19e
Fix WaitForCts() and receiving answers
PatrickKa Jun 29, 2024
88fbebc
Fix printing part info in Rf.test.cpp
PatrickKa Jun 29, 2024
2ea2e30
Send test message in Rf.test.cpp again
PatrickKa Jun 29, 2024
9429ebb
Send test message multiple times
PatrickKa Jun 29, 2024
aef9fae
Set LED 1 pin when sending in Rf.test.cpp
PatrickKa Jul 2, 2024
59b1e81
Initialize PA_ENABLE pin in rf::InitializeGpiosAndSpi()
PatrickKa Jul 2, 2024
802b70e
Update message that's sent in Rf.test.cpp
PatrickKa Jul 2, 2024
0eea8cd
Remove all DEBUG_PRINT()s from rf::Send() and rf::WriteToFifo()
PatrickKa Jul 2, 2024
b90d02b
Fix typo in rf::ReceiveTestData()
PatrickKa Jul 6, 2024
b153d30
Update RF module configuration
PatrickKa Jul 6, 2024
6e67f6f
Receive test data in Rf.test.cpp
PatrickKa Jul 6, 2024
3e75f72
Only read part number in Rf.test.cpp before TX and RX
PatrickKa Jul 6, 2024
d1d92d9
Remove unnecessary StartTx() calls in rf::Send()
PatrickKa Jul 13, 2024
450112b
Add rf::ReadModemStatus()
PatrickKa Jul 14, 2024
3697678
Rework rf::ClearInterrupts() to rf::ReadAndClearInterruptStatus()
PatrickKa Jul 14, 2024
80ee1d3
Add rf::ApplyPatch()
PatrickKa Jul 14, 2024
379a220
feat(Rf): use parameters generated by WDS tool
XDjackieXD Jul 15, 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
2 changes: 2 additions & 0 deletions Sts1CobcSw/Hal/Spi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ class Spi

auto Initialize(RODOS::HAL_SPI * spi, std::uint32_t baudRate) -> void;

// TODO: Why are these functions still here? I think they can and should be removed.

// TODO: Maybe remove extent to reduce code bloat, or probably build time since it is just a single
// call to the Rodos function, which is trivial to inline.
template<typename T, std::size_t extent>
Expand Down
1 change: 1 addition & 0 deletions Sts1CobcSw/Periphery/Fram.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ auto Initialize() -> void;
[[nodiscard]] auto ReadDeviceId() -> DeviceId;
auto ActualBaudRate() -> std::int32_t;

// TODO: This should also work without extent and thereby without any template parameters
template<std::size_t extent>
auto WriteTo(Address address, std::span<Byte const, extent> data, std::int64_t timeout) -> void;

Expand Down
Loading
Loading