Abstract
The ability to add processes, especially to load different applications in them (which you can with commands we didn’t talk about last chapter), is a useful capability. But there are some downsides. Getting one process to communicate with another, for example, involves an outside mechanism. You can write to a file and have the second process read that file in, so long as you have some kind of file locking in place, so reads and writes don’t happen at the same time. You can use a standard UNIX/Linux tool called a pipe, which looks like a file that is write-only to one process and read-only to the other. There are ways around the communication problem, many well established from the dinosaur UNIX days.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2018 James R. Strickland
About this chapter
Cite this chapter
Strickland, J.R. (2018). One Process, Multiple Threads. In: Raspberry Pi for Arduino Users. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-3414-3_8
Download citation
DOI: https://doi.org/10.1007/978-1-4842-3414-3_8
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-3413-6
Online ISBN: 978-1-4842-3414-3
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)