bladePins and bladePowerPins

I’m a little confused with the blade pin and bladepowerpins in the blade config. I understand for the most part but if I want to add another blade( I.E.i am try to add one or two 2020 Neopixel strips with 4 LEDs each right on the board so it shines through the board cover. ) I already have the main blade the Shtok v3 connector, and two small neopixel for the crystal chamber. Edit: sorry forgot to add I’m not sure which blade pins and power pins I. Need to use or change in the config

Would it be better to use a subblade on the crystal blade or Shtok v3 blade? Or to just add a whole other blade to the config ?

I am currently running to appointments so I can post my blade config once I get home later tonight

It depends on how things are wired.

But first, some background:

  • A bladePin is a pin intended to be used for sending WS2811/NeoPixel data.
  • A bladePowerPin is a pin which controls one of the LED MOSFETs, and is where you connect a blade/LED’s negative or GND pin.
  • A “Blade” in Proffie is anything controlled by bladestyles. E.g. blades, accents, illuminated switches, etc.
  • A “SubBlade” is the idea of splitting a single, physical WS281X blade into multiple effective blades in the config, to each be controlled by an individual bladestyle.

Whether you should add another WS281X Blade or turn one of your existing blades into a SubBlade configuration and add these accents to that depends on how things are wired/how you’re planning or wanting to wire things.

If it’s more convenient to wire up the accent strip to a new data bladePin and LED pad, then creating another blade makes more sense.

If it’s more convenient to unsolder your crystal or blade connector and put the accent in between in series to create a daisy chain, then a SubBlade makes more sense.

It’s a matter of the physical layout of your saber. To me it sounds like your two reasonable options, depending on how things are setup, are going to be either a SubBlade with the crystal chamber or a separate blade.

Further Reading:

1 Like

Thanks for the quick reply! I think I’m going to go with another blade. Right now I have it wired in series I will just have to adjust what pins the blades are going to. Have to read over to Docs of sub blades a couple times. To be honest it’s still a little confusing and I’m only adding two strips of accent LEDs so I fell like the blade config would be easier if I did this. If you don’t mind later I’m going to post my updated blade config, could you check it out and see if it’s good when I do?

Of course!

So if I understand correctly, your accents are currently wired in series (a wiring that would be SubBlade’d), but the SubBlades were confusing so you’re going to instead rewire and just set it up as a separate blade?

So currently I don’t have the accents set up my current wiring is the main blade Shtok v3 and Crystal chamber wired in series no subblades. So I was thinking if I picked either of the options it would look like this
The Shtok V3 would be a sub blade in this

BladeConfig blades[] = {
 { 0, WS281XBladePtr<144, bladePin, Color8::GRB, PowerPINS<bladePowerPin2, bladePowerPin3> >(),
    WS281XBladePtr<16, blade2Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >(),
    SubBladeWithStride(0, 14, 2, WS281XBladePtr<16, blade3Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >()),
    SubBladeWithStride(1, 15, 2, NULL),
    WS281XBladePtr<10 blade3Pin, Color8::GRB, PowerPINS<bladePowerPin1> >()
     WS281XBladePtr<2 blade4Pin, Color8::GRB, PowerPINS<bladePowerPin6> >() 
  , CONFIGARRAY(presets) }, 
};
#endif

And if I just added the accents as a separate blade
It should be something like this

BladeConfig blades[] = {
 { 0, WS281XBladePtr<144, bladePin, Color8::GRB, PowerPINS<bladePowerPin2, bladePowerPin3> >(),
    WS281XBladePtr<16, blade2Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >(),
    WS281XBladePtr<10, blade3Pin, Color8::GRB, PowerPINS<bladePowerPin1> >()
     WS281XBladePtr<2, blade4Pin, Color8::GBR, PowerPINS<bladePowerpin6> >()
  , CONFIGARRAY(presets) },
};
#endif

Forgive me if this is a little confusing still trying to get the wiring and programming of accents down, it’s still a little confusing to me, and my first build and all, I feel slow lol but I appreciate the help!

THis would 0, 14, 2.

Thanks! I appreciate all the help!

Note that for the first example, You’ve several overlaps. blade3Pin is being used in your subblades and for another WS281XBlade. And bladePowerPin4 and bladePowerPin5 are being used for both the subblades and your second blade. Note that the latter is valid assuming you’ve defined SHARED_POWER_PINS, however it seems this might be a mistake? (The first bit definitely is)

wow did not catch that. The wierd thing is, that is what the config helper tool on profezzorn’s site gave me when I entererd the blade, Lit neopixel pcb, and the accent strips, the crysatal chamber I wrote in. I do have SHARED_POWER_PINS Defined
this is what part of the sub-blades that confuses me on the powerpins. So would I put Blade2pin since it is a sub-blade of the second blade?

I’m not totally sure why it made my second blade(the Lit PCB connector) a SubBlade as well but that is what came up in the helper tool. when I adjusted the last part of that blade config I think I type the wrong BladePin, my bad. But as far as the other stuff i’m still trying to figure that out.

Just adding another blade, non-subBlade seems less compliocated lol sorry forthis just want to make sure I understand this properly.

BTW I am sorry I forgot to mention that I am Doing this on a Proffieboard v2.2

EDIT:: So if I read and understood the Documentation correctly can I change the last to BladePins to Blade4pin and Blade5pin(RX) there would be no overlapping and should be fine with the SHARED_POWER_PINS Define, if I choose to use the Sub-Blades, correct?

Looks like the configurator does something weird if you select two illuminated PCBs. I’ll see if I can fix that.

2 Likes

I think I’m getting confused with what the ultimate setup is supposed to be, so let me type out everything it sounds to me like you plan on having:

  • A main blade on Data 1/ bladePin
  • A Shtok NPXL V3
  • A crystal chamber with 2(?) pixels/LEDs
  • An accent strip to shine through the board cover.

From there, I’m looking at your first BladeConfig array in this message.

  • The first entry for a WS281X Blade would be your main blade, on Data 1 using LED2 and LED3 pads.

But the second, third, and forth entries are confusing to me:

WS281XBladePtr<16, blade2Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >(),
SubBladeWithStride(0, 14, 2, WS281XBladePtr<16, blade3Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >()),
SubBladeWithStride(1, 15, 2, NULL),

There’s 16 LEDs/Pixels on a Shtok V3, so it at first glance to me seems like you’ve setup a Shtok V3 twice? You’ve created on instance which is a normal blade, and then another which uses SubBladeWithStride to properly maintain the shape/arrangement of the pixels for effects.

It seems to me that if you only have one Shtok V3 (and I assume you are in fact wiring the data in parallel, not in series–see the manual section about wiring configs if you’re unsure), you should only have the bottom two subblades:

SubBladeWithStride(0, 14, 2, WS281XBladePtr<16, blade3Pin, Color8::GRB, PowerPINS<bladePowerPin4, bladePowerPin5> >()),
SubBladeWithStride(1, 15, 2, NULL),

And perhaps you’d want to use Data 2 instead of Data 3?

As far as I can tell your 6th/Last entry with 2 pixels on Data 4 is for the crystal chamber, is that right? If so that seems fine.

Then finally the 5th blade with 10 pixels on LED1 and data 3 would be for the shine-through LED strip?

Just trying to go through this piece by piece to make sure I’m on the same page as you.

You are correct I’m sorry still getting confused here and there, yes it is in fact wire in Parallel.

1 Like

Just wanted to say Thanks to all who responded and helped out with my issue. I understand now and believe I have SubBlades down as well! You’ve been a huge help Thank You! I will find the right section and post the build when complete. You’re all awsome and welcoming to the new DIY’ers and installers coming into the community. This kind of attitude makes the experience so much more enjoyable than it already was !

2 Likes

I think this should be fixed now.

2 Likes