Did anybody try to mod their ErgoDox EZ with a custom LED array?

That would be very useful. Looking forward to those pictures!

I was hoping that the schematics for glow show up in the github repo but didn’t so far :confused:

Is it possible to use a arduino pro micro as the I2C bridge? I tried flashing the firmware from github but it is not working. I’m trying to troubleshoot it for few days now but haven’t had any luck yet. I made the necessary change to the Makefile to build for pro micro.

Thank you for the awesome information, I have the right side working.

1 Like

Welcome @d1v1d360!

In general a pro micro should work, as long as the chip can sustain i2c at 400khz.

Can you verify the following:

  • you are connecting to the correct pins, dedicated for i2c. This depends on your specific arduino model.
  • continuity between left hand PCB and your own PCB is fine (use multi meter to check)
  • you have pull-up resistors on both i2c lines.
    I’ve used 10k in my setup, but other values (eg 4k7 - 10k) should probably work too. Some arduinos have integrated pull-ups AFAIK, so avois having multiple pull-up resistors.
  • you adjusted the C code to account for eventual changes in the used pins.

Did you check all above points?

Thanks for the quick response.
– I’ve verified the connect. I’m using this - hxxps://www.sparkfun.com/products/12640. Connected 2 to SDA and 3 to SCL
– I uploaded a test program to see if the pro micro can drive the led string correctly and it is working as expected with the test program - Arduino sketch.
– Not sure if the pro micro has built in pull up resistor. Looking through the datasheet to figure out, not sure so far - hxxps://cdn.sparkfun.com/datasheets/Dev/Arduino/Boards/ATMega32U4.pdf
– I connected the led data to pin 6 on pro micor and adjusted the code accordingly.

Thank you!

Take a look at the pro micro schematic.

SDA and SCL are on pin PD1 and PD0, which are mapped to pin marked 2 and pin marked 3 on the micro. There doesn’t seem to be any I2C pull-up resistors.

Compared to my i2c bridge schematic you need two resistors (R1 and R2 in my schematic), connecting SDA and SCL to 5V.

41

Adding the pull-up resistors should make I2c work. Lastly, connecting the ws2812 to PB2 (marked 16) should make the led strip work. At least if I didn’t misread the schematic from sparkfun.

05

With those changes the firmware in my repository should work without changes, as I’m just using SDA & SCL for I2c, and PB2 for the WS2812 LEDs.

Let me know if those changes make it work :slight_smile:

EDIT 1 I updated the text to match the silkscreen on the pro micro
EDIT 2 You might need to change PB2 to another pin to avoid collisions with MOSI - that’d require a code change in the source code.
EDIT 3 Care to post some pictures of your setup?

Thank you for the information. I’ll add the pull-up resistor later today and give it a try. I’ll post the pictures as well.

SDA and SDC are connected to pin 2 and 3 respectively as you mentioned. I connected the LED to pin 6 which is PD7 and updated that in your code, main.c

No luck :slightly_frowning_face: I added pull-up resistor to SDA and SCL and connected the LED strip to pin 6 and update the source code to use pin 6.

just to exclude any i2c issues: do you have a raspberry pi at hand? You could connect your raspberry pi via i2c to your pro micro and use i2cdetect -y 1 to list which devices are active on the bus. This would help you verify that a) your i2c is working and b) your i2c slave has the right address.

Also, did you check that the pins on the left side of the ergodox are soldered in the right order? I used a multimeter to find VCC and GND, and then assigned the I2C pins as per the schematic on github.

Yes, I’ve a raspberry pi, I’ll give it a try now. And I checked I2C on left side is connected correctly as per the schematic since the pro micro is getting powered up when I plug in the keyboard.

P.S. Is there any other way to verify I2C is working and the address is correct. Setting up raspberry pi will take a while. Thank you

Unless you have a scope flying around the rpi is probably the easiest option. I have a pro micro flying around, too. I’ll try to find some time this weekend to do what you’re trying. Maybe I run into the same issues.

I see, I guess the I’ll try the raspberry pi option then. Thanks for your help. I’ll probably have to wait until Friday to test with raspberry pi.

Looks like Pro Micro i2c is not working. I’m getting no address on executing i2cdetect -y 1. Will keep trying.

Some light … I got this when I connected pro micro with your I2C bridge code to raspberry pi. Is this the expected output? Thanks

yes, 0x42 is expected. This looks good!

Thanks for confirming. I double checked all the connection but it still is not working. What would you recommend as the next step to troubleshoot. I’m trying to drive the led strip to verify the light_ws2812 library works with pro micro.

Please let me know you thoughts. Thank you

I’m trying to test the pro micro by itself to see if it can drive the led strip using the light_ws2812 library hXXps://github.com/cpldcpu/light_ws2812/tree/master/light_ws2812_AVR/Examples They Arduino example are working as expected but the AVR examples are not working. I don’t see anything on the led strip. Will continue to troubleshoot.

1 Like

Quick question, I’m connecting the led strip to pin 6 on pro micro so in sourcecode file main.c I updated ws2812_pin as follows. Is this correct, or am I missing anything. Thanks

#define ws2812_pin 6

according to the schematic the pin marked as 6 on the pro micro should be PD7 - so you need to a) #define ws2812_port D and b) #define ws2812_pin 7

I tried that and finally found the issue. The library light_ws2812.h overwrites whatever you define in main.c. Once I update it in the light_ws2812.h file everything started working. That was the root cause of the issue. Now I think I have power issue. When I turn up the brightness to full, the pro micro i2c bridge keeps restarting.

congratulations on a working shine-mod.

I’m not sure how much power the pro micro consumes by default; all I know is that the atmega168pa works reliably at full brightness :slight_smile:

If you want to do me a favor - post two pull-requests to the repo and a) fix the issue in ws2812.h, and b) add details about an alternative setup.

That way, if others want to follow your footsteps, it’s easier on them.

Also, post pics of your new Shine! :slight_smile: