Advertisement
Sabersense

Edited

Feb 24th, 2024
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.53 KB | None | 0 0
  1. #ifdef CONFIG_TOP
  2. #include "proffieboard_config.h"
  3. #define NUM_BLADES 2
  4. #define NUM_BUTTONS 2
  5. #define VOLUME 1300
  6. const unsigned int maxLedsPerStrip = 145;
  7. #define CLASH_THRESHOLD_G 4.0
  8. #define ENABLE_AUDIO
  9. #define ENABLE_MOTION
  10. #define ENABLE_WS2811
  11. #define ENABLE_SD
  12. #define ENABLE_SERIAL
  13. #define DISABLE_DIAGNOSTIC_COMMANDS
  14.  
  15.  
  16. #define ORIENTATION ORIENTATION_USB_TOWARDS_BLADE
  17.  
  18. #define GESTURE_AUTO_BATTLE_MODE
  19. #define SA22C_THRUST_ON
  20. #define SA22C_TWIST_OFF
  21. #define SA22C_SWING_ON
  22. #define SA22C_SWING_ON_SPEED 700
  23.  
  24.  
  25. #define MOTION_TIMEOUT 60 * 3 * 1000
  26.  
  27. #define SAVE_STATE
  28.  
  29. #define ENABLE_SERIAL
  30.  
  31.  
  32. #endif
  33.  
  34.  
  35.  
  36. #ifdef CONFIG_PROP
  37.  
  38. #include "../props/saber_sa22c_buttons.h"
  39.  
  40. #endif
  41.  
  42. #ifdef CONFIG_PRESETS
  43. Preset presets[] = {
  44.  
  45. {"Nightsister", "tracks/Sister2.wav",
  46.  
  47. //Crystal Accent Yellow
  48. StylePtr<Layers<AudioFlicker<RgbArg<BASE_COLOR_ARG,Rgb<255,255,0>>,Mix<Int<24576>,Black,RgbArg<BASE_COLOR_ARG,Rgb<255,255,0>>>>,InOutTrL<TrInstant,TrWipeInX<RetractionTime<0>>,Pulsing<Black,RgbArg<OFF_COLOR_ARG,Rgb<255,255,0>>,8000>>>>(),
  49.  
  50. //Ventress Yellow
  51. StylePtr<Layers<AudioFlicker<RgbArg<BASE_COLOR_ARG,Rgb<255,255,0>>,Mix<Int<24576>,Black,RgbArg<BASE_COLOR_ARG,Rgb<255,255,0>>>>,TransitionEffectL<TrConcat<TrJoin<TrDelayX<WavLen<>>,TrWipeIn<200>>,AlphaL<AudioFlickerL<RgbArg<STAB_COLOR_ARG,Rgb<255,199,119>>>,SmoothStep<IntArg<MELT_SIZE_ARG,26174>,Int<2000>>>,TrWipe<200>>,EFFECT_STAB>,TransitionEffectL<TrRandom<TrWaveX<RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>,Int<200>,Int<200>,Int<400>,Scale<BladeAngle<>,Int<28000>,Int<8000>>>,TrConcat<TrInstant,AlphaMixL<Bump<Scale<BladeAngle<>,Int<28000>,Int<8000>>,Int<14000>>,RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>,Mix<Int<16384>,Black,RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>>>,TrFade<300>>,TrWaveX<RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>,Int<200>,Int<100>,Int<400>,Scale<BladeAngle<>,Int<28000>,Int<8000>>>,TrConcat<TrInstant,AlphaMixL<Bump<Scale<BladeAngle<>,Int<28000>,Int<8000>>,Int<10000>>,RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>,Mix<Int<16384>,Black,RgbArg<BLAST_COLOR_ARG,Rgb<255,199,119>>>>,TrFade<300>>>,EFFECT_BLAST>,Mix<IsLessThan<ClashImpactF<>,Int<26000>>,TransitionEffectL<TrConcat<TrInstant,AlphaL<RgbArg<CLASH_COLOR_ARG,Rgb<255,199,119>>,Bump<Scale<BladeAngle<>,Scale<BladeAngle<0,16000>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<-12000>>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<10000>>>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<-10000>>>,Scale<ClashImpactF<>,Int<12000>,Int<60000>>>>,TrFadeX<Scale<ClashImpactF<>,Int<200>,Int<400>>>>,EFFECT_CLASH>,TransitionEffectL<TrWaveX<RgbArg<CLASH_COLOR_ARG,Rgb<255,199,119>>,Scale<ClashImpactF<>,Int<100>,Int<400>>,Int<100>,Scale<ClashImpactF<>,Int<100>,Int<400>>,Scale<BladeAngle<>,Scale<BladeAngle<0,16000>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<-12000>>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<10000>>>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<-10000>>>>,EFFECT_CLASH>>,LockupTrL<AlphaMixL<Bump<Scale<BladeAngle<>,Scale<BladeAngle<0,16000>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<-12000>>,Sum<IntArg<LOCKUP_POSITION_ARG,21854>,Int<10000>>>,Scale<SwingSpeed<100>,Int<14000>,Int<18000>>>>,AudioFlickerL<RgbArg<LOCKUP_COLOR_ARG,Rgb<255,199,119>>>,BrownNoiseFlickerL<RgbArg<LOCKUP_COLOR_ARG,Rgb<255,199,119>>,Int<200>>>,TrConcat<TrInstant,RgbArg<LOCKUP_COLOR_ARG,Rgb<255,199,119>>,TrFade<400>>,TrConcat<TrInstant,RgbArg<LOCKUP_COLOR_ARG,Rgb<255,199,119>>,TrFade<400>>,SaberBase::LOCKUP_NORMAL>,ResponsiveLightningBlockL<Strobe<RgbArg<LB_COLOR_ARG,Rgb<255,199,119>>,AudioFlicker<RgbArg<LB_COLOR_ARG,Rgb<255,199,119>>,Blue>,50,1>,TrConcat<TrInstant,AlphaL<RgbArg<LB_COLOR_ARG,Rgb<255,199,119>>,Bump<Int<12000>,Int<18000>>>,TrFade<200>>,TrConcat<TrInstant,HumpFlickerL<AlphaL<RgbArg<LB_COLOR_ARG,Rgb<255,199,119>>,Int<16000>>,30>,TrSmoothFade<600>>>,LockupTrL<AlphaL<Stripes<2000,4000,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>,Mix<Sin<Int<50>>,Black,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>>,Mix<Int<4096>,Black,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>>>,SmoothStep<IntArg<DRAG_SIZE_ARG,28000>,Int<3000>>>,TrConcat<TrJoin<TrDelay<4000>,TrWipeIn<200>>,AlphaL<Stripes<2000,3000,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>,Mix<Sin<Int<30>>,Black,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>>,Mix<Int<8192>,Black,RgbArg<DRAG_COLOR_ARG,Rgb<255,199,119>>>>,SmoothStep<IntArg<DRAG_SIZE_ARG,28000>,Int<3000>>>,TrFade<4000>>,TrFade<300>,SaberBase::LOCKUP_DRAG>,LockupTrL<AlphaL<Remap<Scale<RampF,Int<65536>,Int<0>>,StaticFire<Mix<TwistAngle<>,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>,RotateColorsX<Int<3000>,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>>>,Mix<TwistAngle<>,RotateColorsX<Int<3000>,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>>,RotateColorsX<Int<3000>,Mix<Int<12000>,Black,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>>>>,0,3,5,3000,10>>,SmoothStep<IntArg<MELT_SIZE_ARG,26174>,Int<4000>>>,TrConcat<TrWipeIn<100>,AlphaL<RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>,SmoothStep<IntArg<MELT_SIZE_ARG,26174>,Int<4000>>>,TrJoin<TrDelay<4000>,TrFade<300>>,AlphaL<Mix<TwistAngle<>,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>,RotateColorsX<Int<3000>,RgbArg<STAB_COLOR_ARG,Rgb<255,24,0>>>>,SmoothStep<IntArg<MELT_SIZE_ARG,26174>,Int<4000>>>,TrFade<4000>>,TrWipe<200>,SaberBase::LOCKUP_MELT>,InOutTrL<TrWipeX<IgnitionTime<500>>,TrWipeInX<RetractionTime<500>>,Black>>>(),
  52. "ventress"},
  53.  
  54.  
  55. };
  56.  
  57.  
  58. BladeConfig blades[] = {
  59.  
  60. { 0,
  61. SubBlade(0, 0, WS281XBladePtr<91,bladePin,Color8::GRB,PowerPINS<bladePowerPin2,bladePowerPin3>>()),
  62. SubBlade(1, 91, NULL),
  63.  
  64. CONFIGARRAY(presets)},
  65.  
  66. };
  67. #endif
  68.  
  69. #ifdef CONFIG_BUTTONS
  70. Button PowerButton(BUTTON_POWER, powerButtonPin, "pow");
  71. Button AuxButton(BUTTON_AUX, auxPin, "aux");
  72. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement