60 if (!read_ThreeAxisGyroscopes(reader)) {
63 if (!read_ThreeAxisLinearAccelerometers(reader)) {
66 if (!read_ThreeAxisMagnetometers(reader)) {
69 if (!read_OrientationSensors(reader)) {
72 if (!read_TemperatureSensors(reader)) {
75 if (!read_SixAxisForceTorqueSensors(reader)) {
78 if (!read_ContactLoadCellArrays(reader)) {
81 if (!read_EncoderArrays(reader)) {
84 if (!read_SkinPatches(reader)) {
87 if (!read_PositionSensors(reader)) {
106 if (!write_ThreeAxisGyroscopes(writer)) {
109 if (!write_ThreeAxisLinearAccelerometers(writer)) {
112 if (!write_ThreeAxisMagnetometers(writer)) {
115 if (!write_OrientationSensors(writer)) {
118 if (!write_TemperatureSensors(writer)) {
121 if (!write_SixAxisForceTorqueSensors(writer)) {
124 if (!write_ContactLoadCellArrays(writer)) {
127 if (!write_EncoderArrays(writer)) {
130 if (!write_SkinPatches(writer)) {
133 if (!write_PositionSensors(writer)) {
146 return write(writer);
173 yarp().setOwner(*
this);
199 return obj !=
nullptr;
218 if (group == 0 && is_dirty) {
225 will_set_ThreeAxisGyroscopes();
227 mark_dirty_ThreeAxisGyroscopes();
229 did_set_ThreeAxisGyroscopes();
235 return obj->ThreeAxisGyroscopes;
253 will_set_ThreeAxisLinearAccelerometers();
255 mark_dirty_ThreeAxisLinearAccelerometers();
257 did_set_ThreeAxisLinearAccelerometers();
263 return obj->ThreeAxisLinearAccelerometers;
281 will_set_ThreeAxisMagnetometers();
283 mark_dirty_ThreeAxisMagnetometers();
285 did_set_ThreeAxisMagnetometers();
291 return obj->ThreeAxisMagnetometers;
309 will_set_OrientationSensors();
311 mark_dirty_OrientationSensors();
313 did_set_OrientationSensors();
319 return obj->OrientationSensors;
337 will_set_TemperatureSensors();
339 mark_dirty_TemperatureSensors();
341 did_set_TemperatureSensors();
347 return obj->TemperatureSensors;
365 will_set_SixAxisForceTorqueSensors();
367 mark_dirty_SixAxisForceTorqueSensors();
369 did_set_SixAxisForceTorqueSensors();
375 return obj->SixAxisForceTorqueSensors;
393 will_set_ContactLoadCellArrays();
395 mark_dirty_ContactLoadCellArrays();
397 did_set_ContactLoadCellArrays();
403 return obj->ContactLoadCellArrays;
421 will_set_EncoderArrays();
423 mark_dirty_EncoderArrays();
425 did_set_EncoderArrays();
431 return obj->EncoderArrays;
449 will_set_SkinPatches();
451 mark_dirty_SkinPatches();
453 did_set_SkinPatches();
459 return obj->SkinPatches;
477 will_set_PositionSensors();
479 mark_dirty_PositionSensors();
481 did_set_PositionSensors();
487 return obj->PositionSensors;
528 writer.
writeString(
"send: 'help' or 'patch (param1 val1) (param2 val2)'");
543 if (!writer.
writeTag(
"many", 1, 0)) {
551 if (field ==
"ThreeAxisGyroscopes") {
555 if (!writer.
writeString(
"SensorMeasurements ThreeAxisGyroscopes")) {
559 if (field ==
"ThreeAxisLinearAccelerometers") {
563 if (!writer.
writeString(
"SensorMeasurements ThreeAxisLinearAccelerometers")) {
567 if (field ==
"ThreeAxisMagnetometers") {
571 if (!writer.
writeString(
"SensorMeasurements ThreeAxisMagnetometers")) {
575 if (field ==
"OrientationSensors") {
579 if (!writer.
writeString(
"SensorMeasurements OrientationSensors")) {
583 if (field ==
"TemperatureSensors") {
587 if (!writer.
writeString(
"SensorMeasurements TemperatureSensors")) {
591 if (field ==
"SixAxisForceTorqueSensors") {
595 if (!writer.
writeString(
"SensorMeasurements SixAxisForceTorqueSensors")) {
599 if (field ==
"ContactLoadCellArrays") {
603 if (!writer.
writeString(
"SensorMeasurements ContactLoadCellArrays")) {
607 if (field ==
"EncoderArrays") {
611 if (!writer.
writeString(
"SensorMeasurements EncoderArrays")) {
615 if (field ==
"SkinPatches") {
619 if (!writer.
writeString(
"SensorMeasurements SkinPatches")) {
623 if (field ==
"PositionSensors") {
627 if (!writer.
writeString(
"SensorMeasurements PositionSensors")) {
637 writer.
writeString(
"ThreeAxisLinearAccelerometers");
649 bool have_act =
false;
650 if (tag !=
"patch") {
651 if (((len - 1) % 2) != 0) {
654 len = 1 + ((len - 1) / 2);
658 for (
int i = 1; i < len; ++i) {
672 if (key ==
"ThreeAxisGyroscopes") {
673 will_set_ThreeAxisGyroscopes();
674 if (!obj->nested_read_ThreeAxisGyroscopes(reader)) {
677 did_set_ThreeAxisGyroscopes();
678 }
else if (key ==
"ThreeAxisLinearAccelerometers") {
679 will_set_ThreeAxisLinearAccelerometers();
680 if (!obj->nested_read_ThreeAxisLinearAccelerometers(reader)) {
683 did_set_ThreeAxisLinearAccelerometers();
684 }
else if (key ==
"ThreeAxisMagnetometers") {
685 will_set_ThreeAxisMagnetometers();
686 if (!obj->nested_read_ThreeAxisMagnetometers(reader)) {
689 did_set_ThreeAxisMagnetometers();
690 }
else if (key ==
"OrientationSensors") {
691 will_set_OrientationSensors();
692 if (!obj->nested_read_OrientationSensors(reader)) {
695 did_set_OrientationSensors();
696 }
else if (key ==
"TemperatureSensors") {
697 will_set_TemperatureSensors();
698 if (!obj->nested_read_TemperatureSensors(reader)) {
701 did_set_TemperatureSensors();
702 }
else if (key ==
"SixAxisForceTorqueSensors") {
703 will_set_SixAxisForceTorqueSensors();
704 if (!obj->nested_read_SixAxisForceTorqueSensors(reader)) {
707 did_set_SixAxisForceTorqueSensors();
708 }
else if (key ==
"ContactLoadCellArrays") {
709 will_set_ContactLoadCellArrays();
710 if (!obj->nested_read_ContactLoadCellArrays(reader)) {
713 did_set_ContactLoadCellArrays();
714 }
else if (key ==
"EncoderArrays") {
715 will_set_EncoderArrays();
716 if (!obj->nested_read_EncoderArrays(reader)) {
719 did_set_EncoderArrays();
720 }
else if (key ==
"SkinPatches") {
721 will_set_SkinPatches();
722 if (!obj->nested_read_SkinPatches(reader)) {
725 did_set_SkinPatches();
726 }
else if (key ==
"PositionSensors") {
727 will_set_PositionSensors();
728 if (!obj->nested_read_PositionSensors(reader)) {
731 did_set_PositionSensors();
759 if (is_dirty_ThreeAxisGyroscopes) {
769 if (!obj->nested_write_ThreeAxisGyroscopes(writer)) {
773 if (is_dirty_ThreeAxisLinearAccelerometers) {
780 if (!writer.
writeString(
"ThreeAxisLinearAccelerometers")) {
783 if (!obj->nested_write_ThreeAxisLinearAccelerometers(writer)) {
787 if (is_dirty_ThreeAxisMagnetometers) {
794 if (!writer.
writeString(
"ThreeAxisMagnetometers")) {
797 if (!obj->nested_write_ThreeAxisMagnetometers(writer)) {
801 if (is_dirty_OrientationSensors) {
811 if (!obj->nested_write_OrientationSensors(writer)) {
815 if (is_dirty_TemperatureSensors) {
825 if (!obj->nested_write_TemperatureSensors(writer)) {
829 if (is_dirty_SixAxisForceTorqueSensors) {
836 if (!writer.
writeString(
"SixAxisForceTorqueSensors")) {
839 if (!obj->nested_write_SixAxisForceTorqueSensors(writer)) {
843 if (is_dirty_ContactLoadCellArrays) {
850 if (!writer.
writeString(
"ContactLoadCellArrays")) {
853 if (!obj->nested_write_ContactLoadCellArrays(writer)) {
857 if (is_dirty_EncoderArrays) {
867 if (!obj->nested_write_EncoderArrays(writer)) {
871 if (is_dirty_SkinPatches) {
881 if (!obj->nested_write_SkinPatches(writer)) {
885 if (is_dirty_PositionSensors) {
895 if (!obj->nested_write_PositionSensors(writer)) {
903 void SensorStreamingData::Editor::communicate()
908 if (
yarp().canWrite()) {
915 void SensorStreamingData::Editor::mark_dirty()
921 void SensorStreamingData::Editor::mark_dirty_ThreeAxisGyroscopes()
923 if (is_dirty_ThreeAxisGyroscopes) {
927 is_dirty_ThreeAxisGyroscopes =
true;
932 void SensorStreamingData::Editor::mark_dirty_ThreeAxisLinearAccelerometers()
934 if (is_dirty_ThreeAxisLinearAccelerometers) {
938 is_dirty_ThreeAxisLinearAccelerometers =
true;
943 void SensorStreamingData::Editor::mark_dirty_ThreeAxisMagnetometers()
945 if (is_dirty_ThreeAxisMagnetometers) {
949 is_dirty_ThreeAxisMagnetometers =
true;
954 void SensorStreamingData::Editor::mark_dirty_OrientationSensors()
956 if (is_dirty_OrientationSensors) {
960 is_dirty_OrientationSensors =
true;
965 void SensorStreamingData::Editor::mark_dirty_TemperatureSensors()
967 if (is_dirty_TemperatureSensors) {
971 is_dirty_TemperatureSensors =
true;
976 void SensorStreamingData::Editor::mark_dirty_SixAxisForceTorqueSensors()
978 if (is_dirty_SixAxisForceTorqueSensors) {
982 is_dirty_SixAxisForceTorqueSensors =
true;
987 void SensorStreamingData::Editor::mark_dirty_ContactLoadCellArrays()
989 if (is_dirty_ContactLoadCellArrays) {
993 is_dirty_ContactLoadCellArrays =
true;
998 void SensorStreamingData::Editor::mark_dirty_EncoderArrays()
1000 if (is_dirty_EncoderArrays) {
1004 is_dirty_EncoderArrays =
true;
1009 void SensorStreamingData::Editor::mark_dirty_SkinPatches()
1011 if (is_dirty_SkinPatches) {
1015 is_dirty_SkinPatches =
true;
1020 void SensorStreamingData::Editor::mark_dirty_PositionSensors()
1022 if (is_dirty_PositionSensors) {
1026 is_dirty_PositionSensors =
true;
1031 void SensorStreamingData::Editor::dirty_flags(
bool flag)
1034 is_dirty_ThreeAxisGyroscopes = flag;
1035 is_dirty_ThreeAxisLinearAccelerometers = flag;
1036 is_dirty_ThreeAxisMagnetometers = flag;
1037 is_dirty_OrientationSensors = flag;
1038 is_dirty_TemperatureSensors = flag;
1039 is_dirty_SixAxisForceTorqueSensors = flag;
1040 is_dirty_ContactLoadCellArrays = flag;
1041 is_dirty_EncoderArrays = flag;
1042 is_dirty_SkinPatches = flag;
1043 is_dirty_PositionSensors = flag;
1044 dirty_count = flag ? 10 : 0;