Research

Parallel Processing vs. Series Processing

Parallel processing is mainly used for breaking up a complex task into less complex tasks. Each processor would have a portion of the overall task to complete. This is not optimal for the purposes of this project due to the fact that the process that will be run is not extremely complex, and so it is not necessary to divide the work among different processors. Although there may be multiple processes going on, these are not very complex tasks, and could be handled by a single processor if handled correctly. Another potential issue for parallel processing could be created if one of the processors goes offline; then one of the tasks would not be handled, because there is no backup process. A processor failing is a legitimate concern for this project, as there will be several factors (such as vibrations, pressure differences, etc.) that may cause failure.

Series processing will be used for the project, as it fits the needs of the project the best. In terms of preventing failures, it allows for backing up processes, an important advantage. In terms of handling processes, series will be adequate, as the messages being passed to the processor may be handled one at a time. This can be done with the use of a stack and the prioritization of certain messages over others. This will allow a single processor to handle multiple messages, even if they are sent at the same time, and to handle them in an efficient order.

The function of the other processors is still in debate, however, at least one processor should be utilized as a backup to the main processor. This processor would survey the status of the main processor consistently by sending a message to it. The main processor’s job when this message is received would be to send it back to the backup processor. If the backup processor receives this message back in a timely manner, then it knows the main processor is working fine. If it is not received, then it should begin to expect, if not assume, that an error has occurred, and would then take over the process of handling messages.

An important distinction that should be made is which of the processors will be the main processor, which will be next in line, and so on. The processor that is connected to all sensors and actuators should be the last in the hierarchy of processors, and the next processor connected to that one should be second last, and so on. This is due to the fact that if the processor that is connected to all of the sensors and actuators fails, all connections with those peripherals is lost. The sensor readings and messages for actuators will have to go through the other processors. For this reason, the processors used should be minimized, as sending these readings over multiple processors could significantly slow the overall process.

https://searchdatacenter.techtarget.com/definition/parallel-processing


Error-Detection Between Processors

Parity Bit

A parity bit is an extra bit added on to data that is sent between two processors. The goal of the parity bit is to make the data (in binary) have either an even or odd number of 1s. The system should stick to using only even or only odd 1s, not both. For example, if the processor expects an odd number of 1s including the parity bit, and it detects an even number of 1s, an error has occurred. It is worth noting that if more than one error occurs at the same time (i.e. an even number of bits are flipped), it is possible the parity bit would not detect the error.

Message Handling

One processor would send some kind of an empty message to another, and the job of the receiving processor would be to simply send the same message back. If this is done in a timely fashion (within a few ms), everything is in order. If original message-sending processor does not receive the message back within the time threshold, it should suspect an error has occurred in the other processor. The downside to this is that the data of the processor being polled could be completely wrong and it may still be able to return the message. This method would mainly be used to detect if the processor got stuck in a loop, or has gone offline completely.

More error handling: https://pdfs.semanticscholar.org/ccca/bd63e7a29332fc5cf2dd26a8a78aeee2ed2f.pdf