Switch/Tunnel for ThroughSerial-SoftwareBitBang.
More...
#include <PJONInteractiveRouter.h>
|
PJONInteractiveRouter
< PJONVirtualBusRouter
< PJONSwitch > > | router (2,(PJONAny *[2]){&bus1,&bus2}) |
|
void | setup () |
|
void | loop () |
|
void | sendnotification_function (const uint8_t *const payload, const uint16_t length, const uint8_t receiver_bus, const uint8_t sender_bus, const PJON_Packet_Info &packet_info) |
|
|
StrategyLink< SoftwareBitBang > | link1 |
|
StrategyLink< ThroughSerial > | link2 |
|
Switch/Tunnel for ThroughSerial-SoftwareBitBang.
- Author
- drtrigon
- Date
- 2018-07-06
- Version
- 1.0
* OneWire PJON Generic "OWPG" scheme:
* Server e.g. linux machine or raspi
* OWPJON/LINUX/Local/LocalUDP/RemoteWorker/DeviceGeneric/
* OWPJON/LINUX/Local/ThroughSerial/RemoteWorker/DeviceGeneric/
* Tunnel(er) similar to 1wire master (similar cause we are on a multi-master bus) e.g. AVR
* OWPJON/ARDUINO/Local/SoftwareBitBang/Tunneler/BlinkingSwitch/
* OWPJON/ARDUINO/Local/SoftwareBitBang/Tunneler/BlinkingSwitch_SWBB-TS/ (this sketch)
* OWPJON/ARDUINO/Local/ThroughSerial/SoftwareBitBangSurrogate/Surrogate/ (obsolete)
* Devices e.g. AVR
* OWPJON/ARDUINO/Local/SoftwareBitBang/DeviceGeneric/
* OWPJON/ARDUINO/Local/SoftwareBitBang/OWP_DG_LCD_Sensors/
* ...
*
* Compatible with: atmega328 (Uno, Nano), atmega32u4 (Yun)
*
* Pinout:
* 1wire PJON data bus (OWPJON SWBB):
* 1WIRE DATA -> Arduino Pin D7
* GND black -> Arduino GND
* 1wire Sniffer/Master/Client Shield
*
* Test on Ubuntu or Raspberry Pi Server (owpshell) confer the docu of
* following files:
* - @ref OWPJON/LINUX/Local/LocalUDP/RemoteWorker/DeviceGeneric/DeviceGeneric.cpp
* - @ref OWPJON/LINUX/Local/ThroughSerial/RemoteWorker/DeviceGeneric/DeviceGeneric.cpp
*
* Thanks to:
* gioblu - PJON 11.0 and support
* @see https://www.pjon.org/
* @see https://github.com/gioblu/PJON
* fredilarsen - support
*
OneWirePJON device status update function.
- Returns
- (void)
PJONInteractiveRouter<PJONVirtualBusRouter<PJONSwitch> > router |
( |
2 |
, |
|
|
(PJONAny *[2]){&bus1,&bus2} |
|
|
) |
| |
void sendnotification_function |
( |
const uint8_t *const |
payload, |
|
|
const uint16_t |
length, |
|
|
const uint8_t |
receiver_bus, |
|
|
const uint8_t |
sender_bus, |
|
|
const PJON_Packet_Info & |
packet_info |
|
) |
| |
Arduino IDE: put your setup code here, to run once.