0
\$\begingroup\$

My objective is to send a bit pattern of 1000 bits from one microcontroller (PIC or Atmel) to another one using the SPI method.

How can I visualize the bit pattern so I can find the errors of received bit pattern?

In Arduino serial monitor can be used for this. But I want to know a way for PIC or Atmel microcontrollers.

\$\endgroup\$
  • 2
    \$\begingroup\$ This is usually done with a scope or logic analyzer. \$\endgroup\$ – Eugene Sh. Mar 20 at 16:13
  • \$\begingroup\$ But it is not clear how you are going to send raw bits using SPI. SPI is usually having some kind of framing, grouping the bits into bytes or something. \$\endgroup\$ – Eugene Sh. Mar 20 at 16:15
  • \$\begingroup\$ Just send a frame of bits that the receiver can recognize as being correct then it can self-flag if there is an error. \$\endgroup\$ – Andy aka Mar 20 at 17:34
0
\$\begingroup\$

Get a usb logic analyzer they can be had for as little as 7$ USD .The bandwidth of the logic analyzer needs to be two times higher than the signal your observing. Logic analyzers set a threshold voltage and tell you if the signal is high or low (useful for digital).

Oscilloscopes allow you to see many different values (analogue) or a range of voltages, and can be useful for troubleshooting noise issues.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.