JUCE
Classes | Namespaces | Typedefs | Enumerations | Variables
juce_BlocksProtocolDefinitions.h File Reference

Classes

struct  BlocksProtocol::BlockStringData< MaxSize >
 Structure for generic block data. More...
 
struct  BlocksProtocol::BlockSerialNumber
 Structure describing a block's serial number. More...
 
struct  BlocksProtocol::DeviceStatus
 Structure for the device status. More...
 
struct  BlocksProtocol::DeviceConnection
 Structure for the device connection. More...
 
struct  BlocksProtocol::DeviceVersion
 Structure for the device version. More...
 
struct  BlocksProtocol::DeviceName
 Structure used for the device name. More...
 
struct  BlocksProtocol::TouchPosition
 The coordinates of a touch. More...
 
struct  BlocksProtocol::TouchVelocity
 The velocities for each dimension of a touch. More...
 

Namespaces

 BlocksProtocol
 
 BlocksProtocol::SpecialMessageFromHost
 Messages that the host may send to a device that do not have the usual message format.
 

Typedefs

using BlocksProtocol::ProtocolVersion = IntegerWithBitSize< 8 >
 
using BlocksProtocol::PacketTimestamp = IntegerWithBitSize< 32 >
 A timestamp for a packet, in milliseconds since device boot-up. More...
 
using BlocksProtocol::PacketTimestampOffset = IntegerWithBitSize< 5 >
 This relative timestamp is for use inside a packet, and it represents a number of milliseconds that should be added to the packet's timestamp. More...
 
using BlocksProtocol::MessageType = IntegerWithBitSize< 7 >
 This is the first item in a BLOCKS message, identifying the message type. More...
 
using BlocksProtocol::TopologyIndex = uint8
 This is a type of index identifier used to refer to a block within a group. More...
 
using BlocksProtocol::DeviceCount = IntegerWithBitSize< 7 >
 
using BlocksProtocol::ConnectionCount = IntegerWithBitSize< 8 >
 
using BlocksProtocol::BatteryLevel = IntegerWithBitSize< 5 >
 Battery charge level. More...
 
using BlocksProtocol::BatteryCharging = IntegerWithBitSize< 1 >
 Battery charger connection flag. More...
 
using BlocksProtocol::ConnectorPort = IntegerWithBitSize< 5 >
 ConnectorPort is an index, starting at 0 for the leftmost port on the top edge, and going clockwise. More...
 
using BlocksProtocol::VersionNumber = BlockStringData< 21 >
 
using BlocksProtocol::BlockName = BlockStringData< 33 >
 
using BlocksProtocol::TouchIndex = IntegerWithBitSize< 5 >
 The index of a touch, i.e. More...
 
using BlocksProtocol::PacketCounter = IntegerWithBitSize< 10 >
 
using BlocksProtocol::DeviceCommand = IntegerWithBitSize< 9 >
 
using BlocksProtocol::ConfigCommand = IntegerWithBitSize< 4 >
 
using BlocksProtocol::ConfigItemIndex = IntegerWithBitSize< 8 >
 
using BlocksProtocol::ConfigItemValue = IntegerWithBitSize< 32 >
 
using BlocksProtocol::ControlButtonID = IntegerWithBitSize< 12 >
 An ID for a control-block button type. More...
 
using BlocksProtocol::RotaryDialIndex = IntegerWithBitSize< 7 >
 
using BlocksProtocol::RotaryDialAngle = IntegerWithBitSize< 14 >
 
using BlocksProtocol::RotaryDialDelta = IntegerWithBitSize< 14 >
 
using BlocksProtocol::PacketIndex = IntegerWithBitSize< 16 >
 
using BlocksProtocol::DataChangeCommand = IntegerWithBitSize< 3 >
 
using BlocksProtocol::ByteCountFew = IntegerWithBitSize< 4 >
 
using BlocksProtocol::ByteCountMany = IntegerWithBitSize< 8 >
 
using BlocksProtocol::ByteValue = IntegerWithBitSize< 8 >
 
using BlocksProtocol::ByteSequenceContinues = IntegerWithBitSize< 1 >
 
using BlocksProtocol::FirmwareUpdateACKCode = IntegerWithBitSize< 7 >
 
using BlocksProtocol::FirmwareUpdateACKDetail = IntegerWithBitSize< 32 >
 
using BlocksProtocol::FirmwareUpdatePacketSize = IntegerWithBitSize< 7 >
 

Enumerations

enum  BlocksProtocol::MessageFromDevice {
  BlocksProtocol::MessageFromDevice::deviceTopology = 0x01, BlocksProtocol::packetACK = 0x02, BlocksProtocol::firmwareUpdateACK = 0x03, BlocksProtocol::MessageFromDevice::deviceTopologyExtend = 0x04,
  BlocksProtocol::MessageFromDevice::deviceTopologyEnd = 0x05, BlocksProtocol::MessageFromDevice::deviceVersion = 0x06, BlocksProtocol::MessageFromDevice::deviceName = 0x07, BlocksProtocol::MessageFromDevice::touchStart = 0x10,
  BlocksProtocol::MessageFromDevice::touchMove = 0x11, BlocksProtocol::MessageFromDevice::touchEnd = 0x12, BlocksProtocol::MessageFromDevice::touchStartWithVelocity = 0x13, BlocksProtocol::MessageFromDevice::touchMoveWithVelocity = 0x14,
  BlocksProtocol::MessageFromDevice::touchEndWithVelocity = 0x15, BlocksProtocol::MessageFromDevice::configMessage = 0x18, BlocksProtocol::MessageFromDevice::controlButtonDown = 0x20, BlocksProtocol::MessageFromDevice::controlButtonUp = 0x21,
  BlocksProtocol::programEventMessage = 0x28, BlocksProtocol::MessageFromDevice::logMessage = 0x30
}
 Messages that a device may send to the host. More...
 
enum  BlocksProtocol::MessageFromHost {
  BlocksProtocol::MessageFromHost::deviceCommandMessage = 0x01, BlocksProtocol::MessageFromHost::sharedDataChange = 0x02, BlocksProtocol::programEventMessage = 0x03, BlocksProtocol::MessageFromHost::firmwareUpdatePacket = 0x04,
  BlocksProtocol::MessageFromHost::configMessage = 0x10, BlocksProtocol::MessageFromHost::factoryReset = 0x11, BlocksProtocol::MessageFromHost::blockReset = 0x12, BlocksProtocol::MessageFromHost::setName = 0x20
}
 Messages that the host may send to a device. More...
 
enum  BlocksProtocol::ConfigItemId {
  BlocksProtocol::midiStartChannel = 0, BlocksProtocol::midiEndChannel = 1, BlocksProtocol::midiUseMPE = 2, BlocksProtocol::pitchBendRange = 3,
  BlocksProtocol::octave = 4, BlocksProtocol::transpose = 5, BlocksProtocol::slideCC = 6, BlocksProtocol::slideMode = 7,
  BlocksProtocol::octaveTopology = 8, BlocksProtocol::midiChannelRange = 9, BlocksProtocol::MPEZone = 40, BlocksProtocol::velocitySensitivity = 10,
  BlocksProtocol::glideSensitivity = 11, BlocksProtocol::slideSensitivity = 12, BlocksProtocol::pressureSensitivity = 13, BlocksProtocol::liftSensitivity = 14,
  BlocksProtocol::fixedVelocity = 15, BlocksProtocol::fixedVelocityValue = 16, BlocksProtocol::pianoMode = 17, BlocksProtocol::glideLock = 18,
  BlocksProtocol::glideLockEnable = 19, BlocksProtocol::mode = 20, BlocksProtocol::volume = 21, BlocksProtocol::scale = 22,
  BlocksProtocol::hideMode = 23, BlocksProtocol::chord = 24, BlocksProtocol::arpPattern = 25, BlocksProtocol::tempo = 26,
  BlocksProtocol::key = 27, BlocksProtocol::autoTransposeToKey = 28, BlocksProtocol::xTrackingMode = 30, BlocksProtocol::yTrackingMode = 31,
  BlocksProtocol::zTrackingMode = 32, BlocksProtocol::gammaCorrection = 33, BlocksProtocol::globalKeyColour = 34, BlocksProtocol::rootKeyColour = 35,
  BlocksProtocol::brightness = 36, BlocksProtocol::user0 = 64, BlocksProtocol::user1 = 65, BlocksProtocol::user2 = 66,
  BlocksProtocol::user3 = 67, BlocksProtocol::user4 = 68, BlocksProtocol::user5 = 69, BlocksProtocol::user6 = 70,
  BlocksProtocol::user7 = 71, BlocksProtocol::user8 = 72, BlocksProtocol::user9 = 73, BlocksProtocol::user10 = 74,
  BlocksProtocol::user11 = 75, BlocksProtocol::user12 = 76, BlocksProtocol::user13 = 77, BlocksProtocol::user14 = 78,
  BlocksProtocol::user15 = 79, BlocksProtocol::user16 = 80, BlocksProtocol::user17 = 81, BlocksProtocol::user18 = 82,
  BlocksProtocol::user19 = 83, BlocksProtocol::user20 = 84, BlocksProtocol::user21 = 85, BlocksProtocol::user22 = 86,
  BlocksProtocol::user23 = 87, BlocksProtocol::user24 = 88, BlocksProtocol::user25 = 89, BlocksProtocol::user26 = 90,
  BlocksProtocol::user27 = 91, BlocksProtocol::user28 = 92, BlocksProtocol::user29 = 93, BlocksProtocol::user30 = 94,
  BlocksProtocol::user31 = 95
}
 Configuration Item Identifiers. More...
 
enum  BlocksProtocol::DeviceCommands {
  BlocksProtocol::beginAPIMode = 0x00, BlocksProtocol::requestTopologyMessage = 0x01, BlocksProtocol::endAPIMode = 0x02, BlocksProtocol::ping = 0x03,
  BlocksProtocol::debugMode = 0x04, BlocksProtocol::saveProgramAsDefault = 0x05
}
 
enum  BlocksProtocol::ConfigCommands {
  BlocksProtocol::setConfig = 0x00, BlocksProtocol::requestConfig = 0x01, BlocksProtocol::requestFactorySync = 0x02, BlocksProtocol::requestUserSync = 0x03,
  BlocksProtocol::updateConfig = 0x04, BlocksProtocol::updateUserConfig = 0x05, BlocksProtocol::setConfigState = 0x06, BlocksProtocol::factorySyncEnd = 0x07,
  BlocksProtocol::clusterConfigSync = 0x08, BlocksProtocol::factorySyncReset = 0x09
}
 
enum  BlocksProtocol::DataChangeCommands {
  BlocksProtocol::endOfPacket = 0, BlocksProtocol::endOfChanges = 1, BlocksProtocol::skipBytesFew = 2, BlocksProtocol::skipBytesMany = 3,
  BlocksProtocol::setSequenceOfBytes = 4, BlocksProtocol::setFewBytesWithValue = 5, BlocksProtocol::setFewBytesWithLastValue = 6, BlocksProtocol::setManyBytesWithValue = 7
}
 
enum  BlocksProtocol::BitSizes {
  BlocksProtocol::topologyMessageHeader = (int) MessageType::bits + (int) ProtocolVersion::bits + (int) DeviceCount::bits + (int) ConnectionCount::bits, BlocksProtocol::topologyDeviceInfo = (int) BlockSerialNumber::maxLength * 7 + (int) BatteryLevel::bits + (int) BatteryCharging::bits, BlocksProtocol::topologyConnectionInfo = topologyIndexBits + (int) ConnectorPort::bits + topologyIndexBits + (int) ConnectorPort::bits, BlocksProtocol::typeDeviceAndTime = (int) MessageType::bits + (int) PacketTimestampOffset::bits,
  BlocksProtocol::touchMessage = (int) typeDeviceAndTime + (int) TouchIndex::bits + (int) TouchPosition::bits, BlocksProtocol::touchMessageWithVelocity = (int) touchMessage + (int) TouchVelocity::bits, BlocksProtocol::programEventMessage = (int) MessageType::bits + 32 * numProgramMessageInts, BlocksProtocol::programEventMessage = 0x28,
  BlocksProtocol::programEventMessage = 0x03, BlocksProtocol::packetACK = (int) MessageType::bits + (int) PacketCounter::bits, BlocksProtocol::packetACK = 0x02, BlocksProtocol::firmwareUpdateACK = (int) MessageType::bits + (int) FirmwareUpdateACKCode::bits + (int) FirmwareUpdateACKDetail::bits,
  BlocksProtocol::firmwareUpdateACK = 0x03, BlocksProtocol::controlButtonMessage = (int) typeDeviceAndTime + (int) ControlButtonID::bits, BlocksProtocol::configSetMessage = (int) MessageType::bits + (int) ConfigCommand::bits + (int) ConfigItemIndex::bits + (int) ConfigItemValue::bits, BlocksProtocol::configRespMessage = (int) MessageType::bits + (int) ConfigCommand::bits + (int) ConfigItemIndex::bits + ((int) ConfigItemValue::bits * 3),
  BlocksProtocol::configSyncEndMessage = (int) MessageType::bits + (int) ConfigCommand::bits
}
 Contains the number of bits required to encode various items in the packets. More...
 

Variables

constexpr uint8 BlocksProtocol::SpecialMessageFromHost::resetMaster [6] = { 0xf0, 0x00, 0x21, 0x10, 0x49, 0xf7 }