begin adding citations to standards
This commit is contained in:
parent
8de1af8e89
commit
53602709fa
|
@ -27,7 +27,8 @@
|
|||
|
||||
namespace DMX {
|
||||
|
||||
// Table D1 - Reserved START Codes
|
||||
/// \cite DMX
|
||||
/// Table D1 - Reserved START Codes
|
||||
static const uint8_t E111_NULL_START = 0;
|
||||
static const uint8_t E111_ASC_TEXT_ASCII = 23;
|
||||
static const uint8_t E111_ASC_TEST = 85;
|
||||
|
@ -35,10 +36,11 @@ namespace DMX {
|
|||
static const uint8_t E111_ASC_MANUFACTURER = 145;
|
||||
static const uint8_t E111_ASC_SIP = 207;
|
||||
|
||||
// 8.5.3.1 Alternate START code refresh interval
|
||||
// A DMX512 transmitter interleaving NULL START Code packets with
|
||||
// Alternate START Code packets shall send a NULL START Code packet at least
|
||||
// once per second.
|
||||
/// \cite DMX
|
||||
/// 8.5.3.1 Alternate START code refresh interval
|
||||
/// A DMX512 transmitter interleaving NULL START Code packets with
|
||||
/// Alternate START Code packets shall send a NULL START Code packet at least
|
||||
/// once per second.
|
||||
static const uint16_t E111_DATA_LOSS_TIMEOUT = 1000;
|
||||
|
||||
} // namespace DMX
|
||||
|
|
|
@ -132,6 +132,7 @@ void Receiver::dataReceiver(ACN::PDU::Message<ACN::RLP::Pdu> root)
|
|||
auto block = static_cast<ACN::PDU::Block<DATA::Pdu>*>(root->data());
|
||||
for(auto const &frame : *block->pdu)
|
||||
{
|
||||
/// \cite sACN
|
||||
/// 6.2.1 E1.31 Data Packet: Vector
|
||||
/// Sources sending an E1.31 Data Packet shall set the E1.31 Layer's Vector
|
||||
/// to VECTOR_E131_DATA_PACKET. This value indicates that the E1.31 framing
|
||||
|
@ -163,11 +164,11 @@ void Receiver::extendedReceiver(ACN::PDU::Message<ACN::RLP::Pdu> root)
|
|||
for(auto const &frame : *block->pdu)
|
||||
{
|
||||
switch(frame->vector()) {
|
||||
/// 6.3 E1.31 Synchronization Packet Framing Layer
|
||||
/// \cite sACN 6.3 E1.31 Synchronization Packet Framing Layer
|
||||
case VECTOR_E131_EXTENDED_SYNCHRONIZATION:
|
||||
syncFrameHandler(frame);
|
||||
break;
|
||||
/// 6.4 E1.31 Universe Discovery Packet Framing Layer
|
||||
/// \cite sACN 6.4 E1.31 Universe Discovery Packet Framing Layer
|
||||
case VECTOR_E131_EXTENDED_DISCOVERY:
|
||||
discoveryFrameHandler(frame);
|
||||
break;
|
||||
|
@ -195,12 +196,14 @@ void Receiver::dataFrameHandler(ACN::PDU::Message<DATA::Pdu> frame) {
|
|||
return;
|
||||
auto universe = universes_.at(source->universe())->sourceUniverse(*source);
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.3 E1.31 Data Packet: Priority
|
||||
/// No priority outside the range of 0 to 200 shall be transmitted on
|
||||
/// the network.
|
||||
if (source->priority() > 200)
|
||||
frame->stream()->setstate(std::ios_base::failbit);
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.6 E1.31 Data Packet: Options
|
||||
/// Preview_Data: Bit 7 (most significant bit)
|
||||
/// This bit, when set to 1, indicates that the data in this packet is
|
||||
|
@ -209,6 +212,7 @@ void Receiver::dataFrameHandler(ACN::PDU::Message<DATA::Pdu> frame) {
|
|||
if (source->isPreview())
|
||||
return;
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.6 E1.31 Data Packet: Options
|
||||
/// Stream_Terminated: Bit 6
|
||||
/// allow E1.31 sources to terminate transmission of a stream or of
|
||||
|
@ -220,6 +224,7 @@ void Receiver::dataFrameHandler(ACN::PDU::Message<DATA::Pdu> frame) {
|
|||
return;
|
||||
}
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.4.1 Synchronization Address Usage in an E1.31 Data Packet
|
||||
/// a value of 0 in the Synchronization Address indicates that the universe
|
||||
/// data is not synchronized.
|
||||
|
@ -230,6 +235,7 @@ void Receiver::dataFrameHandler(ACN::PDU::Message<DATA::Pdu> frame) {
|
|||
auto block = static_cast<ACN::PDU::Block<ACN::DMP::Pdu>*>(frame->data());
|
||||
for (auto const &dmp : *block->pdu)
|
||||
{
|
||||
/// \cite sACN
|
||||
/// 7.2 DMP Layer: Vector
|
||||
/// The DMP Layer's Vector shall be set to VECTOR_DMP_SET_PROPERTY, which
|
||||
/// indicates a DMP Set Property message by sources. Receivers shall
|
||||
|
@ -265,6 +271,7 @@ void Receiver::discoveryFrameHandler(ACN::PDU::Message<EXTENDED::Pdu> frame) {
|
|||
auto block = static_cast<ACN::PDU::Block<EXTENDED::DISCOVERY::Pdu>*>(frame->data());
|
||||
for(auto const &pdu : *block->pdu)
|
||||
{
|
||||
/// \cite sACN
|
||||
/// 8 Universe Discovery Layer
|
||||
/// Universe Discovery data only appears in E1.31 Universe Discovery
|
||||
/// Packets and shall not be included in E1.31 Data Packets or E1.31
|
||||
|
|
|
@ -28,7 +28,8 @@
|
|||
// E1.31 Lightweight streaming protocol for transport of DMX512 using ACN
|
||||
namespace SACN {
|
||||
|
||||
// Appendix A: Defined Parameters (Normative)
|
||||
/// \cite sACN
|
||||
/// Appendix A: Defined Parameters (Normative)
|
||||
static const uint32_t VECTOR_ROOT_E131_DATA = 0x00000004;
|
||||
static const uint32_t VECTOR_ROOT_E131_EXTENDED = 0x00000008;
|
||||
|
||||
|
|
|
@ -45,6 +45,7 @@ Universe::Universe()
|
|||
void Universe::set(std::shared_ptr<ACN::DMP::Pdu> dmp,
|
||||
std::shared_ptr<Provenance> source)
|
||||
{
|
||||
/// \cite sACN
|
||||
/// 7.3 Address Type and Data Type
|
||||
/// Sources shall set the DMP Layer's Address Type and Data Type to 0xa1.
|
||||
/// Receivers shall discard the packet if the received value is not 0xa1.
|
||||
|
@ -61,18 +62,21 @@ void Universe::set(std::shared_ptr<ACN::DMP::Pdu> dmp,
|
|||
auto set_data = static_cast<ACN::DMP::address_pair_list*>(dmp->data());
|
||||
const auto& [range, data] = set_data->properties.front();
|
||||
|
||||
/// \cite sACN
|
||||
/// 7.4 First Property Address
|
||||
/// Sources shall set the DMP Layer's First Property Address to 0x0000.
|
||||
/// Receivers shall discard the packet if the received value is not 0x0000.
|
||||
if (range.address != 0)
|
||||
return;
|
||||
|
||||
/// \cite sACN
|
||||
/// 7.5 Address Increment
|
||||
/// Sources shall set the DMP Layer's Address Increment to 0x0001.
|
||||
/// Receivers shall discard the packet if the received value is not 0x0001.
|
||||
if (range.incriment != 1)
|
||||
return;
|
||||
|
||||
/// \cite sACN
|
||||
/// 7.6 Property Value Count
|
||||
/// The DMP Layer's Property Value Count is used to encode the number of
|
||||
/// DMX512-A [DMX] Slots (including the START Code slot).
|
||||
|
@ -81,10 +85,12 @@ void Universe::set(std::shared_ptr<ACN::DMP::Pdu> dmp,
|
|||
|
||||
setProvenance(source);
|
||||
|
||||
/// \cite sACN
|
||||
/// 7.7 Property Values (DMX512-A Data)
|
||||
/// The DMP Layer's Property values field is used to encode the
|
||||
/// DMX512-A [DMX] START Code and data.
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.4.1 If a receiver is presented with an E1.31 Data Packet containing a
|
||||
/// Synchronization Address of 0, it shall discard any data waiting to be
|
||||
/// processed and immediately act on that Data Packet.
|
||||
|
@ -135,6 +141,8 @@ std::shared_ptr<Provenance> Universe::source() const
|
|||
*/
|
||||
uint8_t Universe::slot(const uint16_t addr)
|
||||
{
|
||||
|
||||
/// \cite sACN
|
||||
/// 6.2.6 E1.31 Data Packet: Options
|
||||
/// Force_Synchronization: Bit 5
|
||||
/// This bit indicates whether to lock or revert to an unsynchronized state
|
||||
|
|
|
@ -41,7 +41,8 @@ bool SessionId::operator== (const SessionId & other) const {
|
|||
/**
|
||||
* @brief Session::Session
|
||||
*/
|
||||
Session::Session() {
|
||||
Session::Session()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
@ -49,8 +50,9 @@ Session::Session() {
|
|||
/**
|
||||
* @brief Session::~Session & leaves the session gracefully.
|
||||
*/
|
||||
Session::~Session() {
|
||||
// TODO: Disconnect the session.
|
||||
Session::~Session()
|
||||
{
|
||||
/// \todo Disconnect the session.
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -502,6 +502,7 @@ void uuid::uuid4() {
|
|||
* @brief uuid::time_ 4.1.4. Timestamp
|
||||
* @return
|
||||
*
|
||||
* \cite rfc4122
|
||||
* The timestamp is a 60-bit value. For UUID version 1, this is represented
|
||||
* by Coordinated Universal Time (UTC) as a count of 100-nanosecond intervals
|
||||
* since 00:00:00.00, 15 October 1582 (the date of Gregorian reform to the
|
||||
|
|
Loading…
Reference in New Issue