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

Add description on translateWith and map function with chinese version update. #259

Merged
merged 14 commits into from
Jun 15, 2024
Merged
10 changes: 10 additions & 0 deletions source/SpinalHDL/Libraries/stream.rst
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,16 @@ Functions
| When cond is true, transaction are dropped
- Stream[T]
- 0
* - x.translateWith(that : T2)
- | Return a Stream with payload `that`
| Modify the payload of the `x` stream, while preserving the `valid` and `ready` signals
- Stream[T2]
- 0
* - x.map(translate: (T) => T2)
- | Return a Stream with payload calculated by translate function
| Modify the payload of the `x` stream, while preserving the `valid` and `ready` signals
- Stream[T2]
- 0


The following code will create this logic :
Expand Down
Loading
Loading