Serial Wombat Arduino Library
List of all members
SerialWombat Class Reference

This class name is depricated. Do not use for new development. Use SerialWombatChip instead. More...

#include <SerialWombat.h>

Inheritance diagram for SerialWombat:
SerialWombatChip

Additional Inherited Members

- Public Member Functions inherited from SerialWombatChip
void configureDigitalPin (uint8_t pin, uint8_t highLow)
 
int16_t initialize ()
 
void readUniqueIdentifier ()
 
void readDeviceIdentifier ()
 
uint16_t returnErrorCode (uint8_t *rx)
 
 SerialWombatChip ()
 
int16_t begin (HardwareSerial &serial, bool reset=true)
 initialize a Serial Wombat chip to use a Serial Interface. More...
 
int16_t begin (uint8_t i2cAddress)
 initialize a Serial Wombat chip to use the default Wire I2C Interface and specified address. More...
 
int16_t begin (TwoWire &wire, uint8_t i2cAddress, bool reset=true)
 initialize a Serial Wombat chip to use a specified I2C Interface and address. More...
 
 ~SerialWombatChip ()
 
int sendPacket (uint8_t tx[], uint8_t rx[])
 Send an 8 byte packet to the Serial Wombat chip and wait for 8 bytes back. More...
 
int sendPacket (uint8_t tx[])
 Send an 8 byte packet to the Serial Wombat chip. More...
 
int sendPacket (uint8_t tx[], uint8_t rx[], bool retryIfEchoDoesntMatch, uint8_t beginningBytesToMatch=8, uint8_t endBytesToMatch=0)
 Send an 8 byte packet to the Serial Wombat chip and wait for 8 bytes back. More...
 
int sendPacket (uint8_t tx[], bool retryIfEchoDoesntMatch)
 Send an 8 byte packet to the Serial Wombat chip. More...
 
int sendPacketNoResponse (uint8_t tx[])
 Send an 8 byte packet to the Serial Wombat chip, don't wait for a response. More...
 
char * readVersion (void)
 Request version string (combined model and firmware) and return pointer to it. More...
 
uint32_t readVersion_uint32 (void)
 Request version as a uint32. More...
 
uint16_t readPublicData (uint8_t pin)
 Read the 16 Bit public data associated with a Serial Wombat Pin Mode. More...
 
uint16_t readPublicData (SerialWombatDataSource dataSource)
 Read the 16 Bit public data associated with a Serial Wombat Pin Mode. More...
 
uint16_t writePublicData (uint8_t pin, uint16_t value)
 Write a 16 bit value to a Serial Wombat pin Mode. More...
 
uint16_t readSupplyVoltage_mV (void)
 Measure the Serial Wombat chip's Supply voltage. More...
 
int16_t readTemperature_100thsDegC (void)
 Measure the Serial Wombat chip's internal temperature. More...
 
void hardwareReset ()
 Send a reset command to the Serial Wombat chip. More...
 
void pinMode (uint8_t pin, uint8_t mode, bool pullDown=false, bool openDrain=false)
 Set a pin to INPUT or OUTPUT, with options for pull Ups and open Drain settings. More...
 
void digitalWrite (uint8_t pin, uint8_t val)
 Set an output pin High or Low. More...
 
int digitalRead (uint8_t pin)
 Reads the state of a Pin. More...
 
int analogRead (uint8_t pin)
 Configures pin as analog input and does an immediate A/D conversion.
More...
 
void analogWrite (uint8_t pin, int val)
 Set a pin to PWM output. More...
 
bool queryVersion ()
 Send a version request to the Serial Wombat chip. More...
 
uint32_t readFramesExecuted ()
 Get the number of 1mS frames that have been executed since Serial Wombat chip reset. More...
 
uint16_t readOverflowFrames ()
 Get the number of times an overflow Frame has occured. More...
 
void jumpToBoot ()
 Jump to Bootloader and wait for a UART download of new firmware. More...
 
uint8_t readRamAddress (uint16_t address)
 Read Address from RAM based on 16 bit address. More...
 
int16_t writeRamAddress (uint16_t address, uint8_t value)
 Write byte to Address in RAM based on 16 bit address. More...
 
uint32_t readFlashAddress (uint32_t address)
 Read Address from Flash based on 32 bit address. More...
 
int16_t readUserBuffer (uint16_t index, uint8_t *buffer, uint16_t count)
 Read data from the Serial Wombat 18AB's internal RAM buffer. More...
 
void sleep ()
 Shuts down most functions of the Serial Wombat chip reducing power consumption. More...
 
void wake ()
 Called to send a dummy packet to the Serial Wombat chip to wake it from sleep and ready it for other commands. More...
 
bool isSW18 ()
 Returns true if the instance received a model number corresponding to the Serial Wombat 18 series of chips at begin. More...
 
int16_t eraseFlashPage (uint32_t address)
 Erases a page in flash. Intended for use with the Bootloader, not by end users outside of bootloading sketch. More...
 
int16_t writeFlashRow (uint32_t address)
 Writes a row in flash. Intended for use with the Bootloader, not by end users outside of bootloading sketc. More...
 
int16_t setThroughputPin (uint8_t pin)
 Set a pin to be a throughput monitoring pin. More...
 
int writeUserBuffer (uint16_t index, uint8_t *buffer, uint16_t count)
 Write bytes to the User Memory Buffer in the Serial Wombat chip. More...
 
int writeUserBuffer (uint16_t index, char *s)
 Write bytes to the User Memory Buffer in the Serial Wombat chip. More...
 
int writeUserBuffer (uint16_t index, const char s[])
 Write bytes to the User Memory Buffer in the Serial Wombat chip. More...
 
int16_t writeFrameTimerPin (uint8_t pin)
 Set a pin to be a frame timer for system utilization (SW18AB Only) More...
 
int16_t readLastErrorCommand (uint8_t *cmd)
 Returns the last Serial Wombat command that produced a protocol error. More...
 
void registerErrorHandler (SerialWombatErrorHandler_t handler)
 Registers an error handler that is called by the SerialWombatChip sendPacket() command when a protocol error is returned by the Serial Wombat \handler A function pointer to a function of SerialWombatErrorHandler_t type. More...
 
int16_t echo (uint8_t data[], uint8_t count=7)
 
int16_t echo (char *data)
 
uint32_t readBirthday ()
 
int16_t readBrand (char *data)
 
- Static Public Member Functions inherited from SerialWombatChip
static uint8_t find (bool keepTrying=false)
 Search the I2C Bus addresses 0x68 to 0x6F for I2C devices, and test to see if they respond to Serial Wombat version commands. Returns first address that responds properly or 0 if none found. More...
 
- Public Attributes inherited from SerialWombatChip
uint16_t _supplyVoltagemV = 0
 
uint8_t model [4] = { 0 }
 Contains the last model retreived by queryVersion() as a zero-terminated string. More...
 
uint8_t fwVersion [4] = { 0 }
 Contains the last firmware Version retreived by queryVersion() as a zero-terminated string. More...
 
uint8_t uniqueIdentifier [16]
 
uint8_t uniqueIdentifierLength = 0
 
uint16_t deviceIdentifier
 
uint16_t deviceRevision
 
uint16_t errorCount = 0
 Incremented every time a communication or command error is detected. More...
 
bool inBoot = false
 Set to true if boot mode is indicated by a version query. More...
 
int16_t lastErrorCode = 0
 The last error code returned as part of a protocol error message expressed as a positive integer. More...
 
uint32_t sendReadyTime = 0
 
uint8_t address = 0
 The I2C address of the SerialWombatChip instance. More...
 
uint8_t communicationErrorRetries = 5
 How many times to retry a packet if communcation bus (such as I2C) error. More...
 

Detailed Description

This class name is depricated. Do not use for new development. Use SerialWombatChip instead.