RawMemoryWrite[ptr,val]
writes a binary representation of val to the raw memory at the pointer ptr.
RawMemoryWrite[ptr,val,offset]
writes to an offset pointer.


RawMemoryWrite
RawMemoryWrite[ptr,val]
writes a binary representation of val to the raw memory at the pointer ptr.
RawMemoryWrite[ptr,val,offset]
writes to an offset pointer.
Details

- Supported values of ptr include RawPointer expressions and ManagedObject expressions whose values are pointers.
Examples
open all close allBasic Examples (2)
Scope (1)
RawMemoryWrite supports passing a managed pointer as its first argument:
Properties & Relations (1)
Allocate a buffer of 5 objects of type "Integer16" and fill it with the value -1:
RawMemoryExport can be used for the same purpose:
Tech Notes
Related Guides
History
Text
Wolfram Research (2023), RawMemoryWrite, Wolfram Language function, https://reference.wolfram.com/language/ref/RawMemoryWrite.html.
CMS
Wolfram Language. 2023. "RawMemoryWrite." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RawMemoryWrite.html.
APA
Wolfram Language. (2023). RawMemoryWrite. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RawMemoryWrite.html
BibTeX
@misc{reference.wolfram_2025_rawmemorywrite, author="Wolfram Research", title="{RawMemoryWrite}", year="2023", howpublished="\url{https://reference.wolfram.com/language/ref/RawMemoryWrite.html}", note=[Accessed: 11-August-2025]}
BibLaTeX
@online{reference.wolfram_2025_rawmemorywrite, organization={Wolfram Research}, title={RawMemoryWrite}, year={2023}, url={https://reference.wolfram.com/language/ref/RawMemoryWrite.html}, note=[Accessed: 11-August-2025]}