BayEOS-PHP
 All Data Structures Namespaces Files Functions Variables Pages
Public Member Functions
BayEOSWriter Class Reference
Inheritance diagram for BayEOSWriter:
BayEOSSimpleClient

Public Member Functions

 __construct ($path, $max_chunk=5000, $max_time=60)
 
 save ($values, $origin='', $type=0x41, $offset=0, $ts=0)
 
 saveDataFrame ($values, $type=0x1, $offset=0, $ts=0)
 
 saveOriginDataFrame ($origin, $values, $type=0x1, $offset=0, $ts=0)
 
 saveOriginFrame ($origin, $frame, $ts=0)
 
 saveRoutedFrameRSSI ($MyId, $PanId, $rssi, $frame, $ts=0)
 
 saveMessage ($sting, $ts=0)
 
 saveErrorMessage ($sting, $ts=0)
 
 saveFrame ($frame, $ts=0)
 

Detailed Description

Definition at line 368 of file BayEOSGatewayClient.php.

Constructor & Destructor Documentation

__construct (   $path,
  $max_chunk = 5000,
  $max_time = 60 
)

Create a BayEOSWriter Instance

Parameters
string$pathPath of queue directory
int$max_chunkMaximum file size when a new file is started
int$max_timeMaximum time when a new file is started

Definition at line 379 of file BayEOSGatewayClient.php.

Member Function Documentation

save (   $values,
  $origin = '',
  $type = 0x41,
  $offset = 0,
  $ts = 0 
)

Write a Frame to buffer

Parameters
array$valuein the form ('channel_number'=>'value',...)
string$originOrigin if set this will be the name of the board in the gateway
int$typevalid bayeos data frame type number
intoffset offset parameter for bayeos data frames (not relevant for all types)
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 415 of file BayEOSGatewayClient.php.

saveDataFrame (   $values,
  $type = 0x1,
  $offset = 0,
  $ts = 0 
)

Write a dataFrame to the buffer

Parameters
array$valuein the form ('channel_number'=>'value',...)
int$typevalid bayeos data frame type number
intoffset offset parameter for bayeos data frames (not relevant for all types)
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 440 of file BayEOSGatewayClient.php.

saveErrorMessage (   $sting,
  $ts = 0 
)

Save Error Message

Parameters
string$stingMessage to save
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 533 of file BayEOSGatewayClient.php.

saveFrame (   $frame,
  $ts = 0 
)

Save Frame

Base Function

Parameters
string$framemust be a valid bayeosframe
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 548 of file BayEOSGatewayClient.php.

saveMessage (   $sting,
  $ts = 0 
)

Save Message

Parameters
string$stingMessage to save
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 520 of file BayEOSGatewayClient.php.

saveOriginDataFrame (   $origin,
  $values,
  $type = 0x1,
  $offset = 0,
  $ts = 0 
)

Save Data Frame wrapped in Origin Frame

Parameters
string$originis the name to appear in the gateway
array$valuein the form ('channel_number'=>'value',...)
int$typevalid bayeos data frame type number
intoffset offset parameter for bayeos data frames (not relevant for all types)
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 459 of file BayEOSGatewayClient.php.

saveOriginFrame (   $origin,
  $frame,
  $ts = 0 
)

Save Origin Frame

Parameters
string$originis the name to appear in the gateway
string$framemust be a valid bayeosframe
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 478 of file BayEOSGatewayClient.php.

saveRoutedFrameRSSI (   $MyId,
  $PanId,
  $rssi,
  $frame,
  $ts = 0 
)

Save Routed Frame RSSI

Parameters
int$MyIdTX-XBee MyId
int$PanIdXBee PANID
int$rssiRSSI
string$framemust be a valid bayeosframe
float$tsUnix epoch timestamp. If zero write uses system time

Definition at line 502 of file BayEOSGatewayClient.php.


The documentation for this class was generated from the following file: