-
Notifications
You must be signed in to change notification settings - Fork 242
SoftwareBitBang troubleshooting
Study in detail your project's program because 99.9% of the times the problem is in there, specially if you are using supported hardware and doing legit stuff. If the issue is not solved donwload PJON's latest stable version from www.PJON.org or www.github.com/gioblu/PJON (very often issues are caused by an outdated or edited version of the library) and test your project's program.
If the problem is not solved go further testing the following examples:
- examples/ARDUINO/Local/SoftwareBitBang/NetworkAnalysis tests transmitter's side
- examples/ARDUINO/Local/SoftwareBitBang/SpeedTest tests receiver's side
NetworkAnalysis and SpeedTest are designed to benchmark connectivity performance and reliability using the following terms:
-
Packet overheador how many bytes are added by PJON to data -
Bandwidthor maximum amount of bytes transmitted in a second -
Data throughputor how many data bytes are transmitted every second -
Packets sentor number of packets transmitted in the test window -
Mistakesor how many errors detected with CRC -
Failor number of transmission failures occurred in the test window -
Busyor how many times the channel is found busy -
Accuracyor ratio between correct packets and packets that contain mistakes
The result can be interpreted as follows:
- Many
Failand orMistakesmay mean that the maximum communication range between devices has been reached - Many
Busyand orMistakesand or lowBandwidthmay mean that interference is present, see mitigate interference - Many
Failand orMistakesand or lowBandwidthmay indicate a bad timing configuration, if you are porting a new MCU/architecture to SoftwareBitBang consider different timing configuration may be required because of system discrepancies. Try tweakingSWBB_BIT_WIDTH,SWBB_BIT_SPACER,SWBB_READ_DELAYandSWBB_ACCEPTANCEinTiming.h - Low performance also after painstaking timing tweaks may indicate that the new MCU/architecture may not be fast enough to run SoftwareBitBang at the mode you are working with, try using a faster clock or optimize digital I/O perfomance or choosing a slower mode.
examples/ARDUINO/Local/SoftwareBitBang/PacketSeparationTest can be used to verify that frame separation is 100% reliable. This test has a transmitter device that sends a continuous random byte stream. The receiver device attempts to receive packets from pin 12, if an incoming packet is detected a false positive occurred. The receiver device prints the result of the test via serial. If any false positive is detected while testing a supported device, the system may dispatch corrupted data so please report this occurrence opening an issue in our github repository.
- Update PJON 12.x to 13.0
- Addressing
- Configuration
- Data reception
- Data transmission
- Error handling
- IO pins setup
- Routing
- ATtiny interfacing
- ESP8266 interfacing
- Nucleo interfacing
- Raspberry Pi interfacing
- WINX86 interfacing
- Troubleshooting