![]() |
OSTC Companion
3.0
Companion sofftware for H&W dive computers
|
Implementing various operations for H&W OSTC4 dive computer. More...
#include <OSTC4Operations.h>

Classes | |
| struct | FirmwareOSTC4.version |
Public Member Functions | |
| EXPORT | OSTC4Operations () |
Public Member Functions inherited from OSTC3Operations | |
| OSTC3Operations () | |
| ~OSTC3Operations () | |
| int | firmware () const override |
| The fw version found during the last getIdentty(). More... | |
| int | serialNumber () const override |
| The serial number found during the last getIdentty(). More... | |
| QString | customText () const override |
| The user-defined string found during the last getIdentty(). More... | |
| void | writeText (const QString &msg) override |
| Display a short text on OSTC3 while on service mode. OSTC3 can handle 16 chars. So the string is automatically padded with spaces to clean any leftover. More... | |
| bool | connect () override |
| bool | disconnect (bool closing=false) override |
| Close connection. More... | |
| void | setDate (const QDateTime &date) override |
| Set HW dive computer date and time. More... | |
| void | setName (const QString &newName) override |
| Set HW dive computer user text. More... | |
| void | setIcons (const QString &fileName) override |
| Set HW dive computer icon set. More... | |
| QImage | dumpScreen () const override |
| Take a snapshot of the connected computer's screen. More... | |
| void | loadFirmware (HexFile &hex, const QString &fileName) const override |
| Read in the specific firmware file format. More... | |
Public Member Functions inherited from HardwareOperations | |
| virtual | ~HardwareOperations () |
| mandatory (and empty) virtual descructor in the base class. More... | |
| Serial & | serial () |
| Gives access to serial port in use. Used for other high and low level operations, eg. in OSTC Planner. More... | |
| HardwareDescriptor | hardwareDescriptor () |
| Ask the connect device for its hardware options. More... | |
Additional Inherited Members | |
Public Types inherited from HardwareOperations | |
| enum | HardwareOption { HW_CHARGEABLE_BATTERY = 0x01, HW_LIGHT_SENSOR = 0x02, HW_S8_COM = 0x04, HW_OPTICAL_COM = 0x08, HW_BLUETOOTH_COM = 0x10, HW_DUALCORE = 0x20 } |
| Optional features present in the dive computer hardware. More... | |
| enum | HardwareDescriptor { HW_UNKNOWN_OSTC = 0, HW_Frog = HW_BLUETOOTH_COM, HW_OSTCSport_a = HW_LIGHT_SENSOR | HW_BLUETOOTH_COM, HW_OSTCSport_b = HW_OSTCSport_a | HW_CHARGEABLE_BATTERY, HW_OSTC2c = HW_CHARGEABLE_BATTERY, HW_OSTC2_a = HW_CHARGEABLE_BATTERY | HW_BLUETOOTH_COM, HW_OSTC2_b = HW_OSTCSport_b, HW_OSTC2_c = HW_OSTC2_b | HW_OPTICAL_COM, HW_OSTC3 = HW_LIGHT_SENSOR | HW_OPTICAL_COM, HW_OSTC3p_a = HW_LIGHT_SENSOR | HW_OPTICAL_COM | HW_BLUETOOTH_COM, HW_OSTC3p_b = HW_OSTCSport_b, HW_OSTCcR_a = HW_CHARGEABLE_BATTERY | HW_S8_COM, HW_OSTCcR_b = HW_OSTCcR_a | HW_LIGHT_SENSOR, HW_OSTC4 } |
| Dive computer set of features. More... | |
| enum | CompanionFeatures { PARAMETERS = (1<<0), DATE = (1<<1), NAME = (1<<2), ICON = (1<<3), DUMPSCREEN = (1<<4), FIRMWARE = (1<<5), HELIUM_DIVE = (1<<6), CCR_DIVE = (1<<7), BLUETOOTH = (1<<8), VPM_MODEL = (1<<9) } |
| Features supported by OSTC Companion on the connected device. More... | |
Static Public Member Functions inherited from HardwareOperations | |
| static EXPORT unsigned char | retryCommand (Serial &serial, unsigned char cmd, int retries=10) |
| Send a command, wait ack, and retry on error. More... | |
Protected Types inherited from OSTC3Operations | |
| enum | Mode { CLOSED_MODE = 0, DOWNLOAD_MODE, SERVICE_MODE } |
Protected Member Functions inherited from OSTC3Operations | |
| void | eraseRange (unsigned int addr, unsigned int size) |
| Erase OSTC3 PROM memory. PROM memory should be erased beforeprogramming the new firmware. This command is used to erase a set of 4KB pages. More... | |
| void | writeBlock (unsigned int addr, const unsigned char *data, unsigned int size) |
| Write a big block of bytes to OSTC3 RAM memory. More... | |
| void | readBlock (unsigned int addr, unsigned char *ptr, unsigned int size) |
| Read-back a big block of bytes from OSTC3 RAM memory. More... | |
| void | upgradeFirmware (unsigned int checksum) |
| Burn firmare. More... | |
| virtual void | getCommonIdentity () |
| void | connectServiceMode () override |
| Open service mode communication to the dive computer. More... | |
Protected Member Functions inherited from HardwareOperations | |
| QStringList | listBluetoothPorts () const |
| List serial ports for Bluetooth based devices. More... | |
| QStringList | listUSBPorts () const |
| List serial ports for USB based devices. More... | |
Protected Attributes inherited from OSTC3Operations | |
| QString | descriptionString |
| QString | emulatorName |
| char | computerText [60] |
| enum OSTC3Operations::Mode | _connectMode |
Protected Attributes inherited from HardwareOperations | |
| Serial | _serial |
| Communication port used for all I/O operations. More... | |
Implementing various operations for H&W OSTC4 dive computer.
| struct OSTC4Operations::FirmwareOSTC4.version |
| OSTC4Operations::OSTC4Operations | ( | ) |
1.8.8