Kaimana RGB LED Board thread, RGB animations and more! SRK Tech Talk 2013 Product of the Year!

Where are you assigning colors?

I have been both using Jasen’s site and also assigning it manually in kaimana_custom.h

problem fixed thanks

Another Kaimana Tutorial Video for Paradise Arcade Shop! Hope it comes in handy for some of you :slight_smile:

I recently used the hitbox code on page 12, i am having an issue with my 2k not fully lighting up one led will stay on while the button is being pressed but the other will flash the color and return to its base color. I saw jansen had mentioned a fix but i dont see if it was provided. Also is the hitbox code generator still an idea? or has that idea passed?

another issue is can someone show me how to get the animations and tournament mode to work on a hitbox? i have compared the two codes and i try experimenting placing things here and there but nothing seems to work for me, im sure its not the way to go about it but i am still new to this.

i have my hitbox set up to where my buttons are red until pressed then they are purple, i still would like to use the hadoken and ultra animations also, along with tournament mode.

Hey all, I followed the video above for setting up my kaimana setup.

I’ve linked all the J’s up, which apparently you can’t do “wrong” because of their design. I’ve done a coding via the brightcade site thing and installed that, including turning off unwanted buttons, and having everything in the right “order” (which for me is K4, K3, K2, K1, P1, P2, P3, P4)

And it seems it has loaded ok, as when i plug in the stick I get the purple I assigned which then moves onto the “screen saver” after a while - I haven’t checked if it changes on button presses, as my buttons aren’t hooked up yet - trying to get the LEDs working before I put them in place.

Problem is only the K4 Kaimana J-2 lights up. Not a single other LED lights up. But not being overly techy I’m not really sure how to trouble shoot it.

Also I don’t seem to be able to unplug any of the harness wires from the kaimana J2’s, at first I thought it was just my gorrilla fingers being too big to grip anything to pull them apart, but my wife can’t do it with her dainty little fingers either - is there a secret knack to unplugging them that I’m missing?

My idea was to swap some of the LEDs around, I figured if other LEDs light up in the K4 position that at least would prove that they’re not faulty, and also that it could be the K3 LED that was the problem - but seeing as I can’t easily get them apart and don’t want to just brute force it and break them lol.

Edit - Saw a post above that suggested checking the correct buttons were set to off with “0xFF” - all but the kicks and punches are set to this, and to set the number of LEDs above 16 - tried both of these and made no difference.

@Kuniku I would definitely try moving things around in the chain to see if you get any different results.

As far as unplugging cables from the J2: They are very snug. Hold the connector on the J2 in place and wiggle the cable out as you hold it as close to the j2 connector as you can.

Try moving your K4 LED to the end of the series. Maybe you have a bad outgoing connector

Edit - Saw a post above that suggested checking the correct buttons were set to off with “0xFF” - all but the kicks and punches are set to this, and to set the number of LEDs above 16 - tried both of these and made no difference.
[/quote]

the lights you are using you do not want to have 0xff assigned too

you want your k4 to be labeled as 0 or 1 whatever the lowest amount would be and then you would want to follow your chain of lights and assign the proper number to the buttons so if k4 is 0,1 p4 might be 2,3 p3 4,5 ect

also you might want to make sure that you are not hooked into a bad led, i am dealing with an led that is broken and it would cause issues for the other leds later down the line slow and steady gets the connectors out

Cheers will try that

the lights you are using you do not want to have 0xff assigned too

you want your k4 to be labeled as 0 or 1 whatever the lowest amount would be and then you would want to follow your chain of lights and assign the proper number to the buttons so if k4 is 0,1 p4 might be 2,3 p3 4,5 ect

also you might want to make sure that you are not hooked into a bad led, i am dealing with an led that is broken and it would cause issues for the other leds later down the line slow and steady gets the connectors out

[/quote]

Sorry for any confusion, by correct buttons I meant buttons that didn’t have LEDs attached - the buttons with LEDs are correctly tagged =)

I’m a bit closer, turns out the second J-2 was faulty, but luckily I brought 2 spare J-2’s with my order.

Now all LEDs are lit. But another problem has popped up. The “screensaver” works perfectly, but when the buttons are “not activated” 1 of the 16 LEDs is red instead of purple. If I’m starting with the first J-2 defined as 0 and 1, it is LED#7 that is red (on K1).

This is in turn seemingly affecting the button press LEDs in the series before it. So the red LED stays red when I press the button, the LED paired with it on the J-2 (LED#6) turns yellow, but so does LED#5 on the previous J-2 (K2). Similarly when I press K2, LED#4 lights up, but LED#3 on K3 also does. When I press K3 LED#2 lights up along with LED#1 on K4 and when I press K4 only LED#0 lights up.

P1 doesn’t change at all - but that might be a signal issue as the controller tester doesn’t recognise a button being pressed either. P2, P3 and P4 all work as they should.

if it’s red and not purple, blue probably doesn’t work on that LED

Can safely assume that the blue works fine seeing as the LED works perfectly for all of the colours in the screen saver just fine

UPDATE:

Rewired stick (turns out I’m a numpty and wired my kicks into my punches) and updated the code.

all buttons light up and are correct colours when unpressed and when doing the idle animation. However a very slight issue, the LED that was red before now is purple as it should be when nothing is pressed, but when I press the button that LED flashes yellow and but doesn’t stay yellow, the other LED on that kaimana J does stay yellow while I press & hold the button. But thats not a huge issue. At this stage I’m glad its working 99% as it should do tbh.

Used a 12 LED NeoPixel Ring to try and light up the joystick hole on my Atrox but it was too large for the LEDs to peek though. A NephRing would have fixed that but I don’t think the guy who made them is making any more. No worries, since a matte trading card sleeve with a 0.65 inch wide circular hole serves the same function.

Spoiler

http://i67.tinypic.com/141i9ti.jpg

I still have to program it but but that can wait till the Jasen code generator gets a HitBox version. That way, different parts of the LED ring can light up depending on the direction inputted.

The one thing that is bugging me currently is how to program the two extra buttons on top of the usual eight. They aren’t hooked up to any of the pins my kaimana mini can detect but I’d like to have them light up Cyan when out of demonstration mode. I’ve set them in kaimana_custom.h to the following:

Spoiler


//LED INDEX
#define  LED_R3    12
#define  LED_R3_B  13
#define  LED_L3    14
#define  LED_L4_B  15

//OFF BUTTON STATE 
#define LED_R3_COLOR_OFF 0,200,200
#define LED_L3_COLOR_OFF 0,200,200


And think I have to add something similar to the following already existent code in panzer2kaimana.ino.

Spoiler


// test switch and set LED based on result
  if(!digitalRead(PIN_P1))
  {
    switchActivity |= ATTACK_P1;
    
    // switch is active
    if(iLED[LED_P1] == true)
    {
      //maintain color while switch is active
      iLED[LED_P1] = true;
    }
    else
    {
      // select new color when switch is first activated
      #ifdef RANDOM_COLOR_P1_ON
        setLEDRandomColor(LED_P1);
      #else
         kaimana.setLED(LED_P1, LED_P1_COLOR_ON);
      #endif
      iLED[LED_P1] = true;
    }
  }
  else
  {
      // switch is inactive
      #ifdef RANDOM_COLOR_P1_OFF
        setLEDRandomColor(LED_P1);
      #else
        kaimana.setLED(LED_P1, LED_P1_COLOR_OFF);
      #endif     
      iLED[LED_P1] = false;
  }


However, having zero coding ability, I have no idea where to start. Like, I don’t even know what If clause to use since there is no pin to check.

@teleute
I still have to program it but but that can wait till the Jasen code generator gets a HitBox version. That way, different parts of the LED ring can light up depending on the direction inputted.

do you need a code that works for a hitbox? i have one right now that is working

Google can usually find your answer if you type the codes in:

Lots of issues with many Arduino board types and this error. Above is one possible option.

Sure! Especially if it is made for the new J2s. I found a code from a while ago but it was for the J1s, which is unfortunate since I don’t know how to change the number of LEDs per button. Though, I am going to have to learn how to do that eventually.

Here is my J2 coding: https://www.dropbox.com/s/o5t7y4m0u9jvl85/panzer2kaimana.zip?dl=0