firmware/lib/pb_gen/fx.pb.c
Patrick Moessler 0c83634f42 Initial commit
2019-10-13 00:37:11 +02:00

249 lines
16 KiB
C

/* Automatically generated nanopb constant definitions */
/* Generated by nanopb-0.3.9.3 at Sun Oct 13 00:30:37 2019. */
#include "fx.pb.h"
/* @@protoc_insertion_point(includes) */
#if PB_PROTO_HEADER_VERSION != 30
#error Regenerate this file with the current version of nanopb generator.
#endif
const pb_field_t fx_RGB_fields[4] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_RGB, r, r, 0),
PB_FIELD( 2, UINT32 , REQUIRED, STATIC , OTHER, fx_RGB, g, r, 0),
PB_FIELD( 3, UINT32 , REQUIRED, STATIC , OTHER, fx_RGB, b, g, 0),
PB_LAST_FIELD
};
const pb_field_t fx_RGBW_fields[5] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_RGBW, r, r, 0),
PB_FIELD( 2, UINT32 , REQUIRED, STATIC , OTHER, fx_RGBW, g, r, 0),
PB_FIELD( 3, UINT32 , REQUIRED, STATIC , OTHER, fx_RGBW, b, g, 0),
PB_FIELD( 4, UINT32 , REQUIRED, STATIC , OTHER, fx_RGBW, w, b, 0),
PB_LAST_FIELD
};
const pb_field_t fx_ColorType_fields[4] = {
PB_ONEOF_FIELD(colorTypes, 1, MESSAGE , ONEOF, STATIC , FIRST, fx_ColorType, rgb, rgb, &fx_RGB_fields),
PB_ONEOF_FIELD(colorTypes, 2, MESSAGE , ONEOF, STATIC , UNION, fx_ColorType, rgbw, rgbw, &fx_RGBW_fields),
PB_ONEOF_FIELD(colorTypes, 3, FIXED32 , ONEOF, STATIC , UNION, fx_ColorType, color, color, 0),
PB_LAST_FIELD
};
const pb_field_t fx_Options_fields[5] = {
PB_FIELD( 1, BOOL , REQUIRED, STATIC , FIRST, fx_Options, reverse, reverse, 0),
PB_FIELD( 2, UENUM , REQUIRED, STATIC , OTHER, fx_Options, fadeRate, reverse, 0),
PB_FIELD( 3, BOOL , REQUIRED, STATIC , OTHER, fx_Options, gammaCorrect, fadeRate, 0),
PB_FIELD( 4, UENUM , REQUIRED, STATIC , OTHER, fx_Options, size, gammaCorrect, 0),
PB_LAST_FIELD
};
const pb_field_t fx_init_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_service_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_start_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_stop_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_pause_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_resume_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_strip_off_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_fade_out_msg_fields[2] = {
PB_FIELD( 1, UINT32 , OPTIONAL, STATIC , FIRST, fx_fade_out_msg, fadeTime, fadeTime, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setMode_msg_fields[3] = {
PB_FIELD( 1, UINT32 , OPTIONAL, STATIC , FIRST, fx_setMode_msg, segment, segment, 0),
PB_FIELD( 2, UENUM , REQUIRED, STATIC , OTHER, fx_setMode_msg, mode, segment, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setOptions_msg_fields[3] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setOptions_msg, segment, segment, 0),
PB_FIELD( 2, MESSAGE , REQUIRED, STATIC , OTHER, fx_setOptions_msg, options, segment, &fx_Options_fields),
PB_LAST_FIELD
};
const pb_field_t fx_setSpeed_msg_fields[3] = {
PB_FIELD( 1, UINT32 , OPTIONAL, STATIC , FIRST, fx_setSpeed_msg, segment, segment, 0),
PB_FIELD( 2, UINT32 , REQUIRED, STATIC , OTHER, fx_setSpeed_msg, speed, segment, 0),
PB_LAST_FIELD
};
const pb_field_t fx_increaseSpeed_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_increaseSpeed_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_decreaseSpeed_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_decreaseSpeed_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setColor_msg_fields[3] = {
PB_FIELD( 1, UINT32 , OPTIONAL, STATIC , FIRST, fx_setColor_msg, segment, segment, 0),
PB_FIELD( 2, MESSAGE , REPEATED, CALLBACK, OTHER, fx_setColor_msg, color, segment, &fx_ColorType_fields),
PB_LAST_FIELD
};
const pb_field_t fx_setBrightness_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setBrightness_msg, brightness, brightness, 0),
PB_LAST_FIELD
};
const pb_field_t fx_increaseBrightness_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_increaseBrightness_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_decreaseBrightness_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_decreaseBrightness_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setLength_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setLength_msg, numPixels, numPixels, 0),
PB_LAST_FIELD
};
const pb_field_t fx_increaseLength_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_increaseLength_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_decreaseLength_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_decreaseLength_msg, step, step, 0),
PB_LAST_FIELD
};
const pb_field_t fx_trigger_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_setNumSegments_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setNumSegments_msg, numSegments, numSegments, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setSegment_msg_fields[7] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setSegment_msg, segment, segment, 0),
PB_FIELD( 2, UINT32 , REQUIRED, STATIC , OTHER, fx_setSegment_msg, start, segment, 0),
PB_FIELD( 3, UINT32 , REQUIRED, STATIC , OTHER, fx_setSegment_msg, end, start, 0),
PB_FIELD( 4, UENUM , REQUIRED, STATIC , OTHER, fx_setSegment_msg, mode, end, 0),
PB_FIELD( 5, MESSAGE , REPEATED, CALLBACK, OTHER, fx_setSegment_msg, color, mode, &fx_ColorType_fields),
PB_FIELD( 6, MESSAGE , REQUIRED, STATIC , OTHER, fx_setSegment_msg, options, color, &fx_Options_fields),
PB_LAST_FIELD
};
const pb_field_t fx_resetSegments_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_resetSegmentRuntimes_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_resetSegmentRuntime_msg_fields[2] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_resetSegmentRuntime_msg, segment, segment, 0),
PB_LAST_FIELD
};
const pb_field_t fx_setPixelColor_msg_fields[3] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_setPixelColor_msg, offset, offset, 0),
PB_FIELD( 2, MESSAGE , REQUIRED, STATIC , OTHER, fx_setPixelColor_msg, color, offset, &fx_ColorType_fields),
PB_LAST_FIELD
};
const pb_field_t fx_copyPixels_msg_fields[4] = {
PB_FIELD( 1, UINT32 , REQUIRED, STATIC , FIRST, fx_copyPixels_msg, destination, destination, 0),
PB_FIELD( 2, UINT32 , REQUIRED, STATIC , OTHER, fx_copyPixels_msg, source, destination, 0),
PB_FIELD( 3, UINT32 , REQUIRED, STATIC , OTHER, fx_copyPixels_msg, count, source, 0),
PB_LAST_FIELD
};
const pb_field_t fx_show_msg_fields[1] = {
PB_LAST_FIELD
};
const pb_field_t fx_Root_fields[29] = {
PB_ONEOF_FIELD(msg, 1, MESSAGE , ONEOF, STATIC , FIRST, fx_Root, init, init, &fx_init_msg_fields),
PB_ONEOF_FIELD(msg, 2, MESSAGE , ONEOF, STATIC , UNION, fx_Root, start, start, &fx_start_msg_fields),
PB_ONEOF_FIELD(msg, 3, MESSAGE , ONEOF, STATIC , UNION, fx_Root, stop, stop, &fx_stop_msg_fields),
PB_ONEOF_FIELD(msg, 4, MESSAGE , ONEOF, STATIC , UNION, fx_Root, pause, pause, &fx_pause_msg_fields),
PB_ONEOF_FIELD(msg, 5, MESSAGE , ONEOF, STATIC , UNION, fx_Root, resume, resume, &fx_resume_msg_fields),
PB_ONEOF_FIELD(msg, 6, MESSAGE , ONEOF, STATIC , UNION, fx_Root, strip_off, strip_off, &fx_strip_off_msg_fields),
PB_ONEOF_FIELD(msg, 7, MESSAGE , ONEOF, STATIC , UNION, fx_Root, fade_out, fade_out, &fx_fade_out_msg_fields),
PB_ONEOF_FIELD(msg, 8, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setMode, setMode, &fx_setMode_msg_fields),
PB_ONEOF_FIELD(msg, 9, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setOptions, setOptions, &fx_setOptions_msg_fields),
PB_ONEOF_FIELD(msg, 10, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setSpeed, setSpeed, &fx_setSpeed_msg_fields),
PB_ONEOF_FIELD(msg, 11, MESSAGE , ONEOF, STATIC , UNION, fx_Root, increaseSpeed, increaseSpeed, &fx_increaseSpeed_msg_fields),
PB_ONEOF_FIELD(msg, 12, MESSAGE , ONEOF, STATIC , UNION, fx_Root, decreaseSpeed, decreaseSpeed, &fx_decreaseSpeed_msg_fields),
PB_ONEOF_FIELD(msg, 13, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setColor, setColor, &fx_setColor_msg_fields),
PB_ONEOF_FIELD(msg, 14, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setBrightness, setBrightness, &fx_setBrightness_msg_fields),
PB_ONEOF_FIELD(msg, 15, MESSAGE , ONEOF, STATIC , UNION, fx_Root, increaseBrightness, increaseBrightness, &fx_increaseBrightness_msg_fields),
PB_ONEOF_FIELD(msg, 16, MESSAGE , ONEOF, STATIC , UNION, fx_Root, decreaseBrightness, decreaseBrightness, &fx_decreaseBrightness_msg_fields),
PB_ONEOF_FIELD(msg, 17, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setLength, setLength, &fx_setLength_msg_fields),
PB_ONEOF_FIELD(msg, 18, MESSAGE , ONEOF, STATIC , UNION, fx_Root, increaseLength, increaseLength, &fx_increaseLength_msg_fields),
PB_ONEOF_FIELD(msg, 19, MESSAGE , ONEOF, STATIC , UNION, fx_Root, decreaseLength, decreaseLength, &fx_decreaseLength_msg_fields),
PB_ONEOF_FIELD(msg, 20, MESSAGE , ONEOF, STATIC , UNION, fx_Root, trigger, trigger, &fx_trigger_msg_fields),
PB_ONEOF_FIELD(msg, 21, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setNumSegments, setNumSegments, &fx_setNumSegments_msg_fields),
PB_ONEOF_FIELD(msg, 22, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setSegment, setSegment, &fx_setSegment_msg_fields),
PB_ONEOF_FIELD(msg, 23, MESSAGE , ONEOF, STATIC , UNION, fx_Root, resetSegments, resetSegments, &fx_resetSegments_msg_fields),
PB_ONEOF_FIELD(msg, 24, MESSAGE , ONEOF, STATIC , UNION, fx_Root, resetSegmentRuntimes, resetSegmentRuntimes, &fx_resetSegmentRuntimes_msg_fields),
PB_ONEOF_FIELD(msg, 25, MESSAGE , ONEOF, STATIC , UNION, fx_Root, resetSegmentRuntime, resetSegmentRuntime, &fx_resetSegmentRuntime_msg_fields),
PB_ONEOF_FIELD(msg, 26, MESSAGE , ONEOF, STATIC , UNION, fx_Root, setPixelColor, setPixelColor, &fx_setPixelColor_msg_fields),
PB_ONEOF_FIELD(msg, 27, MESSAGE , ONEOF, STATIC , UNION, fx_Root, copyPixels, copyPixels, &fx_copyPixels_msg_fields),
PB_ONEOF_FIELD(msg, 28, MESSAGE , ONEOF, STATIC , UNION, fx_Root, show, show, &fx_show_msg_fields),
PB_LAST_FIELD
};
/* Check that field information fits in pb_field_t */
#if !defined(PB_FIELD_32BIT)
/* If you get an error here, it means that you need to define PB_FIELD_32BIT
* compile-time option. You can do that in pb.h or on compiler command line.
*
* The reason you need to do this is that some of your messages contain tag
* numbers or field sizes that are larger than what can fit in 8 or 16 bit
* field descriptors.
*/
PB_STATIC_ASSERT((pb_membersize(fx_ColorType, colorTypes.rgb) < 65536 && pb_membersize(fx_ColorType, colorTypes.rgbw) < 65536 && pb_membersize(fx_setOptions_msg, options) < 65536 && pb_membersize(fx_setSegment_msg, options) < 65536 && pb_membersize(fx_setPixelColor_msg, color) < 65536 && pb_membersize(fx_Root, msg.init) < 65536 && pb_membersize(fx_Root, msg.start) < 65536 && pb_membersize(fx_Root, msg.stop) < 65536 && pb_membersize(fx_Root, msg.pause) < 65536 && pb_membersize(fx_Root, msg.resume) < 65536 && pb_membersize(fx_Root, msg.strip_off) < 65536 && pb_membersize(fx_Root, msg.fade_out) < 65536 && pb_membersize(fx_Root, msg.setMode) < 65536 && pb_membersize(fx_Root, msg.setOptions) < 65536 && pb_membersize(fx_Root, msg.setSpeed) < 65536 && pb_membersize(fx_Root, msg.increaseSpeed) < 65536 && pb_membersize(fx_Root, msg.decreaseSpeed) < 65536 && pb_membersize(fx_Root, msg.setColor) < 65536 && pb_membersize(fx_Root, msg.setBrightness) < 65536 && pb_membersize(fx_Root, msg.increaseBrightness) < 65536 && pb_membersize(fx_Root, msg.decreaseBrightness) < 65536 && pb_membersize(fx_Root, msg.setLength) < 65536 && pb_membersize(fx_Root, msg.increaseLength) < 65536 && pb_membersize(fx_Root, msg.decreaseLength) < 65536 && pb_membersize(fx_Root, msg.trigger) < 65536 && pb_membersize(fx_Root, msg.setNumSegments) < 65536 && pb_membersize(fx_Root, msg.setSegment) < 65536 && pb_membersize(fx_Root, msg.resetSegments) < 65536 && pb_membersize(fx_Root, msg.resetSegmentRuntimes) < 65536 && pb_membersize(fx_Root, msg.resetSegmentRuntime) < 65536 && pb_membersize(fx_Root, msg.setPixelColor) < 65536 && pb_membersize(fx_Root, msg.copyPixels) < 65536 && pb_membersize(fx_Root, msg.show) < 65536), YOU_MUST_DEFINE_PB_FIELD_32BIT_FOR_MESSAGES_fx_RGB_fx_RGBW_fx_ColorType_fx_Options_fx_init_msg_fx_service_msg_fx_start_msg_fx_stop_msg_fx_pause_msg_fx_resume_msg_fx_strip_off_msg_fx_fade_out_msg_fx_setMode_msg_fx_setOptions_msg_fx_setSpeed_msg_fx_increaseSpeed_msg_fx_decreaseSpeed_msg_fx_setColor_msg_fx_setBrightness_msg_fx_increaseBrightness_msg_fx_decreaseBrightness_msg_fx_setLength_msg_fx_increaseLength_msg_fx_decreaseLength_msg_fx_trigger_msg_fx_setNumSegments_msg_fx_setSegment_msg_fx_resetSegments_msg_fx_resetSegmentRuntimes_msg_fx_resetSegmentRuntime_msg_fx_setPixelColor_msg_fx_copyPixels_msg_fx_show_msg_fx_Root)
#endif
#if !defined(PB_FIELD_16BIT) && !defined(PB_FIELD_32BIT)
/* If you get an error here, it means that you need to define PB_FIELD_16BIT
* compile-time option. You can do that in pb.h or on compiler command line.
*
* The reason you need to do this is that some of your messages contain tag
* numbers or field sizes that are larger than what can fit in the default
* 8 bit descriptors.
*/
PB_STATIC_ASSERT((pb_membersize(fx_ColorType, colorTypes.rgb) < 256 && pb_membersize(fx_ColorType, colorTypes.rgbw) < 256 && pb_membersize(fx_setOptions_msg, options) < 256 && pb_membersize(fx_setSegment_msg, options) < 256 && pb_membersize(fx_setPixelColor_msg, color) < 256 && pb_membersize(fx_Root, msg.init) < 256 && pb_membersize(fx_Root, msg.start) < 256 && pb_membersize(fx_Root, msg.stop) < 256 && pb_membersize(fx_Root, msg.pause) < 256 && pb_membersize(fx_Root, msg.resume) < 256 && pb_membersize(fx_Root, msg.strip_off) < 256 && pb_membersize(fx_Root, msg.fade_out) < 256 && pb_membersize(fx_Root, msg.setMode) < 256 && pb_membersize(fx_Root, msg.setOptions) < 256 && pb_membersize(fx_Root, msg.setSpeed) < 256 && pb_membersize(fx_Root, msg.increaseSpeed) < 256 && pb_membersize(fx_Root, msg.decreaseSpeed) < 256 && pb_membersize(fx_Root, msg.setColor) < 256 && pb_membersize(fx_Root, msg.setBrightness) < 256 && pb_membersize(fx_Root, msg.increaseBrightness) < 256 && pb_membersize(fx_Root, msg.decreaseBrightness) < 256 && pb_membersize(fx_Root, msg.setLength) < 256 && pb_membersize(fx_Root, msg.increaseLength) < 256 && pb_membersize(fx_Root, msg.decreaseLength) < 256 && pb_membersize(fx_Root, msg.trigger) < 256 && pb_membersize(fx_Root, msg.setNumSegments) < 256 && pb_membersize(fx_Root, msg.setSegment) < 256 && pb_membersize(fx_Root, msg.resetSegments) < 256 && pb_membersize(fx_Root, msg.resetSegmentRuntimes) < 256 && pb_membersize(fx_Root, msg.resetSegmentRuntime) < 256 && pb_membersize(fx_Root, msg.setPixelColor) < 256 && pb_membersize(fx_Root, msg.copyPixels) < 256 && pb_membersize(fx_Root, msg.show) < 256), YOU_MUST_DEFINE_PB_FIELD_16BIT_FOR_MESSAGES_fx_RGB_fx_RGBW_fx_ColorType_fx_Options_fx_init_msg_fx_service_msg_fx_start_msg_fx_stop_msg_fx_pause_msg_fx_resume_msg_fx_strip_off_msg_fx_fade_out_msg_fx_setMode_msg_fx_setOptions_msg_fx_setSpeed_msg_fx_increaseSpeed_msg_fx_decreaseSpeed_msg_fx_setColor_msg_fx_setBrightness_msg_fx_increaseBrightness_msg_fx_decreaseBrightness_msg_fx_setLength_msg_fx_increaseLength_msg_fx_decreaseLength_msg_fx_trigger_msg_fx_setNumSegments_msg_fx_setSegment_msg_fx_resetSegments_msg_fx_resetSegmentRuntimes_msg_fx_resetSegmentRuntime_msg_fx_setPixelColor_msg_fx_copyPixels_msg_fx_show_msg_fx_Root)
#endif
/* @@protoc_insertion_point(eof) */