Giter VIP home page Giter VIP logo

arduinomoonboardled's Introduction

ArduinoMoonBoardLED: A Simple Arduino MoonBoard Bluetooth Low Energy (BLE) LED System

Introduction

This project aims at providing an easy to use solution for building your own MoonBoard LED system using an Arduino. It is both compatible with a normal MoonBoard as well as with the MoonBoard Mini. You need an Arduino Nano 33 BLE (buy the original!), a WS2811 LED string with 25 cm wire length, and an appropriate power source.

This project is compatible with the "new" MoonBoard app. All features (show beta, show lights above holds) of the app can be used. Multiple users can connect at the same time (multi user support).

mini_benchmark

Please READ THIS FIRST

  • IMPORTANT: If you want a product that just works, please buy the one offered by Moon Climbing! This project is neither supported nor endorsed by Moon Climbing!
  • This is a project which requires some work and still might not work as well as the original.
  • To be absolutely clear: This project is provided as-is. I take absolutely no responsibility that it works as expected. In fact, it might break at any time. You have been warned!
  • Never power the Arduino only without powering the LEDs when the data wire is connected to the LED string! This may destroy the first LED! Just use the same power source for both of them and don't disconnect it.

Thanks

All the heavy lifting in this project is done by two awesome libraries: NeoPixelBus (for the LED string) and HardwareBLESerial (for BLE functionality). They make it possible to keep this project quite short, easy to understand, and easily maintainable.

Wiring

The LED strip has three wires: +5V, GND and data. Usually, blue is GND ("negative"), brown is +5V ("positive"), yellow/green is data. Please double-check! You can find a wiring diagram at the bottom of this page.

Connect the data line to pin D2 of the Arduino (unless you changed it in config.h). It might be a good idea to use a resistor (e.g. 330 ohms) in the data line!

Important: Make sure that both the Arduino and the LED string share GND! Simply power both the LED string and the Arduino by the same power source. Use the USB connection for flashing and debugging only! If GND is not connected, the LED string will not work.

Note: You can use different lengths than 25 cm. If you use shorter cables, you might need to adjust the pattern in order to skip some LEDs (see below).

How to use (Windows and Linux via a Package Manager)

  1. Download and install Visual Studio Code.
  2. Install PlatformIO in Visual Studio Code.
  3. Download and open this project. To do so, either download it as a zip file or git clone it.
  4. Adjust config.h settings to your needs (Moonboard type, brightness).
  5. Compile and flash to an Arduino Nano 33 BLE.
  6. Use the MoonBoard app to connect to the Arduino and show the problems on your board!

How to use (Linux, command line)

  1. Download and install platformio
curl -fsSL -o /tmp/get-platformio.py https://raw.githubusercontent.com/platformio/platformio-core-installer/master/get-platformio.py
python3 /tmp/get-platformio.py

  1. Download, install and configure arduino-cli
mkdir -p ~/apps/arduino-cli; cd ~/apps/arduino-cli
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh
~/apps/arduino-cli/bin/arduino-cli core install arduino:mbed_nano
  1. Clone the repository Press the green "Code" button on github and copy the HTTPS url. If you don't have git installed on your Linux distribution, please install it first.
mkdir -p ~/src; cd ~/src
git clone Put_HTTPS_URL_here
cd ArduinoMoonBoardLED/
  1. Adjust config.h

Follow the instructions in the file ~/src/ArduinoMoonBoardLED/src/config.h in order to adjust the configuration to your setup.

  1. Compile
~/.platformio/penv/bin/platformio run
  1. Attach the Arduino Nano BLE to your computer using a MicroUSB cable and upload the firmware
~/apps/arduino-cli/bin/arduino-cli upload -p /dev/ttyACM0 -i .pio/build/nano33ble/firmware.bin
  1. Optional: connect to the console output of the Arduino to see connections and problems
~/apps/arduino-cli/bin/arduino-cli monitor -p /dev/ttyACM0
  1. Use the MoonBoard app to connect to the Arduino and show the problems on your board!

Advanced: LED Mapping

The most common LED wiring pattern goes like this (front view):

  • start bottom left (A1),
  • up the column (to A12),
  • one column to the right (to B12),
  • all the way down (to B1),
  • one column to the right (to C1),
  • and repeat.

The MoonBoard App encodes holds in the same way. Hold A1 is 0, hold A2 is 1, hold A3 is 2 and so on.

If you need to wire differently, you'll need to adjust the ledmapping[] array in config.h which maps hold numbers to LED numbers. The standard mapping is n-->n (e.g. hold #0 is LED #0, hold #1 is LED #1 and so on).

Pictures

led_test mini_back box arduino_wiring wiring

arduinomoonboardled's People

Contributors

denkbrettl avatar fabianrig avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arduinomoonboardled's Issues

wrong starting- and finishing holds light up, but problem holds work fine

Hi Fabian,
first of all: Thank you very much for publising your project and the perfect documentation of it!!!
I did everything exactly as you explained and I really had a lot of fun building and programming.
I have one strange mistake which reason I cannot find a all. All problem LEDs light up perfectly. But the starting- + end holds are lighted wrong. To be more exact, the number of the LED that is lighting up is one too low. The finishing hold that is lighted is always one coloum to far to the left (e.g. finishing hold is B18 but A18 lights up).
When I placed the LEDs I used the Moonboar App hold positioning function. I found out that to light A1 the second LED of the string went on, so I skipped the first LED of the string and now the function to show the individual holds works also fine.
Do you have an idea how I can solve this problem?
Thank you so much for your great work again!!!
Greetings from bavaria
Martin

Other System Boards

Hi Fabian,

First of all, wonderful project. I linked to this project from the raspi version by e-sr https://github.com/e-sr/moonboard

This seemed way less complex.

I did have a question about how difficult it would be to port this to any of the other system boards out there (Kilter, Decoy, Tension, etc). I'm very new to BLE so unsure the ins and outs, but know that I likely will need to setup a packet sniffer to get log the data and somehow decipher it. Hoping they use similar/same backend as the Moonboard.

Either way, I'll be building this as well... and if able to adapt the other system boards, it would be cool to have the arduino recognize which system board app is connecting and parse the incoming data. Not sure if I'm oversimplifying... but that's what I'm thinking.

thanks! looking forward to hearing back from you.

Trouble Flashing

Hi, this is my second github project, my first was a magicmirror. I'm working on a Rapsberry pi 4b. I downloaded and installed Visual Studio Code, I installed PlatformIO and git cloned the project. We have a standard Moon board so I didn't adjust any config.h settings.

When I plug in the arduino and open the project and click "upload" under project tasks I get the following error:
Tool Manager: Installing platformio/toolchain-gccarmnoneeabi @ ~1.80201.0
UnknownPackageError: Could not find the package with 'platformio/toolchain-gccarmnoneeabi @ ~1.80201.0' requirements for your system 'linux_aarch64'

All of this is new to me, I would love help figuring out this error. We have the powersupply and lights all ready to go. Thank you!

Logiclevel shifter for LED Dataline?

Hello,
great work!
I have a question... dont you need a Logiclevel shifter for the data line because operating voltage of the arduino is 3.3v and LED are 5V?

Source for LEDs

@FabianRig
looks awesome!
I got https://github.com/lidiapb/moonboard this running. And works also pretty well. But now some friends asked me to build the same system for them. I think your project is easier to build up, because i worked a lot of hours on the other one to get bt running. ^^
So could u tell me where have u bought the LED Stripes? Here in Germany I only find the 7,5cm version and not 25cm... I think i would be easier to build the new systems with the 25cm led stripes, because I dont have to custimize your system.

Thanks a lot for your work on this!

Originally posted by @smai86 in #1 (comment)

New moonboard app doesn't light up green blue lights

I finished building my mini moonboard last week, just about when the new moonboard app was released. The old app works great with this project. With the new app, only the start (green/violet) and finish (red) holds are lighted up. The holds in between remain dark.

Any clues as to what could be wrong?

PS: Thanks for this great project!

Are multiple user connects at the same time supported?

The official Moonboard LED system "Allows up to 7 users to connect at the same time" according to their product page: MoonBoard LED System

Your readme says all features are supported in the latest app as of Nov 2023. I wanted to ask whether this specific feature of supporting multiple users is possible, however, since your readme just mentioned "show beta" and "LEDs above and below" features.

If it's not supported currently, would a feature request of this kind be considered?

Thanks for the great work put into this project!

LED Mapping

Awesome! This looks really super promising for me. I was searching for an arduino solution before, now here it is! :)

But will it work also if I use a string of LEDs that skip every second LED (because of spacing?)

So: ledmapping[] = {0, 2, 4, 6, 8, 10, ... ?

Thanks!

Fun...

Hi Fabian,

Board it working perfectly! Love the setup.

This is not an issue with any of the functionality for the moonboard but could not message directly.

I am wondering if there are some simple commands I can use via LightBlue or BlueFruit (or another app) that can be used to control the LEDs e.g. turn on all the LEDs to xxx colour, have them rotate like a rainbow. I have two kids and thought doing some things like this will get them super excited about spending more time out there with me climbing.

Thanks, I know this is a left field question.

Compiling issue

Hi.
i am following the Linux install ReadMe and everything works fine, except for the compile step, which gives me this error:
sh: 1: arm-none-eabi-g++: not found

image

please help. Great project, would love to get itworking!

How many leds?

Hi, reading the readme file you specified 150 LEDs for moon board mini and 200 for moon board.
Moon board mini should be 132(11x12) and 198(18*11) moon board.
Am I doing something wrong?
Thanks

Lorenzo

Powering LED

Great stuff here. I plan to play around and try to get it working on my home wall. For powering the LED do they get powered right through the Arduino. And can I just power the Arduino through the USB that connects it the laptop by plugging it into the wall? A bit of a newbie with some experience but very little.

Circuit Diagram

Thanks for this awesome project. I'm in the process of putting it together and I was wondering if you would mind sharing a circuit diagram? I'm interested in seeing exactly how you wired the power to the LED strings. Cheers!

Is the name changeable?

Hi! Great project.
It’s working, and I love it.
Only question - in the app it shows up as ‘MoonBoard A’.
I have searched the code and found that, changed it to a different string and saved and reflashed it.
It still says MoonBoard A.
Can we change the name somehow?

Power supply

    @FabianRig First of all, thank you for this project! Due to the unavailability of the Pi Zero, I will be using this project to light my Moonboard.

Expanding on power supplies for the project, I'd like to hear about your experience using the LPV-60-5. Most other projects use the MDR-60-5 but at 5V, neither of which produce 60W (LPV-60-5 @ 40W, MDR-60-5 @ 50W). Did you choose this power supply because you are only driving 150 LEDs (Moonboard Mini)? Also, are you only noticing any discoloration due to voltage drop or are you using power injection?

Originally posted by @davidstyers in #3 (comment)

Bluetooth issues

Hi Fabian,

Thank you for pulling together. I am new to alot of this so apologies if this is an ignorant question. I have got the board, connected it up. compiled and uploaded the content to it but the Bluetooth is not visible on the moonboard app.

I have been playing around for a while looking at different options. When I go to 'build' there are 47 error messages mostly with the bluetooth setup (below is the output). I assume that this is what is driving it. Wondering if it is me or there were some changes in the reference libs that this uses.

Any advice and guidance on what I need to do to address is appreciated.

Cheers,

Processing nano33ble (platform: nordicnrf52; board: nano33ble; framework: arduino)

Library Manager: Installing SPI
Verbose mode can be enabled via -v, --verbose option
CONFIGURATION: https://docs.platformio.org/page/boards/nordicnrf52/nano33ble.html
PLATFORM: Nordic nRF52 (9.6.0) > Arduino Nano 33 BLE
HARDWARE: NRF52840 64MHz, 256KB RAM, 960KB Flash
DEBUG: Current (blackmagic) External (blackmagic, cmsis-dap, jlink)
PACKAGES:

  • framework-arduino-mbed @ 4.0.2
  • tool-sreccat @ 1.164.0 (1.64)
  • toolchain-gccarmnoneeabi @ 1.80201.181220 (8.2.1)
    LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 46 compatible libraries
    Scanning dependencies...
    Dependency Graph
    |-- HardwareBLESerial @ 1.0.0
    |-- ArduinoBLE @ 1.3.4
    |-- NeoPixelBus @ 2.7.5
    Building in release mode
    Compiling .pio\build\nano33ble\src\main.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLEAdvertisingData.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLECharacteristic.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLEDescriptor.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLEDevice.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLEService.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLEStringCharacteristic.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\BLETypedCharacteristics.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\local\BLELocalAttribute.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\local\BLELocalCharacteristic.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\local\BLELocalDescriptor.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\local\BLELocalDevice.cpp.o
    In file included from .pio\libdeps\nano33ble\ArduinoBLE\src/utility/GATT.h:26,
    from .pio\libdeps\nano33ble\ArduinoBLE\src\local\BLELocalCharacteristic.cpp:25:
    .pio\libdeps\nano33ble\ArduinoBLE\src/local/BLELocalCharacteristic.h: In constructor 'BLELocalCharacteristic::BLELocalCharacteristic(const char*, uint16_t, int, bool)':
    .pio\libdeps\nano33ble\ArduinoBLE\src/local/BLELocalCharacteristic.h:90:12: warning: 'BLELocalCharacteristic::_cccdValue' will be initialized after [-Wreorder]
    uint16_t _cccdValue;
    ^~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src/local/BLELocalCharacteristic.h:79:12: warning: 'uint8_t BLELocalCharacteristic::_permissions' [-Wreorder]
    uint8_t _permissions;
    ^~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\local\BLELocalCharacteristic.cpp:32:1: warning: when initialized here [-Wreorder]
    BLELocalCharacteristic::BLELocalCharacteristic(const char* uuid, uint16_t permissions, int valueSize, bool fixedLength) :
    ^~~~~~~~~~~~~~~~~~~~~~
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\local\BLELocalService.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\remote\BLERemoteAttribute.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\remote\BLERemoteCharacteristic.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\remote\BLERemoteDescriptor.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\remote\BLERemoteDevice.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\remote\BLERemoteService.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\ATT.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\BLEUuid.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\GAP.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\GATT.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\HCI.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\HCICordioTransport.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\HCIUartTransport.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\HCIVirtualTransport.cpp.o
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\L2CAPSignaling.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::handleNotify(uint16_t, const uint8_t*, int)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:592:39: warning: variable length array 'notification' is used [-Wvla]
    uint8_t notification[_peers[i].mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::handleInd(uint16_t, const uint8_t*, int)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:623:37: warning: variable length array 'indication' is used [-Wvla]
    uint8_t indication[_peers[i].mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::findInfoReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:746:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::findByTypeReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:838:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::readByGroupReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:896:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::readOrReadBlobReq(uint16_t, uint16_t, uint8_t, uint8_t, uint8_t*)':
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\bitDescriptions.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1003:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::readByTypeReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1118:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\btct.cpp.o
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::writeReqOrCmd(uint16_t, uint16_t, uint8_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1343:25: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    Compiling .pio\build\nano33ble\lib6ac\ArduinoBLE\utility\keyDistribution.cpp.o
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::prepWriteReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1457:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual void ATTClass::execWriteReq(uint16_t, uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1490:23: warning: variable length array 'response' is used [-Wvla]
    uint8_t response[mtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::exchangeMtu(uint16_t)':
    Compiling .pio\build\nano33ble\libbbe\HardwareBLESerial\HardwareBLESerial.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1572:33: warning: variable length array 'responseBuffer' is used [-Wvla]
    uint8_t responseBuffer[_maxMtu];
    Compiling .pio\build\nano33ble\lib876\SPI\SPI.cpp.o
    ^
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\animations\NeoPixelAnimator.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::discoverServices(uint16_t, BLERemoteDevice*, const char*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1586:33: warning: variable length array 'responseBuffer' is used [-Wvla]
    uint8_t responseBuffer[_maxMtu];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::discoverCharacteristics(uint16_t, BLERemoteDevice*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1642:33: warning: variable length array 'responseBuffer' is used [-Wvla]
    uint8_t responseBuffer[_maxMtu];
    ^
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HsbColor.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp: In member function 'virtual bool ATTClass::discoverDescriptors(uint16_t, BLERemoteDevice*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\ATT.cpp:1699:33: warning: variable length array 'responseBuffer' is used [-Wvla]
    uint8_t responseBuffer[_maxMtu];
    ^
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HslColor.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp: In member function 'virtual void HCIClass::poll(long unsigned int)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:141:20: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
    if (_recvIndex >= sizeof(_recvBuffer)) {
    ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp: In member function 'virtual int HCIClass::tryResolveAddress(uint8_t*, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:565:14: warning: unused variable 'memcheck' [-Wunused-variable]
    uint8_t* memcheck;
    ^~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:557:11: warning: variable 'irk' set but not used [-Wunused-but-set-variable]
    uint8_t irk[16];
    ^~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp: In member function 'virtual int HCIClass::sendAclPkt(uint16_t, uint8_t, uint8_t, void*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:633:41: warning: variable length array 'txBuffer' is used [-Wvla]
    uint8_t txBuffer[sizeof(aclHdr) + plen];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp: In member function 'virtual int HCIClass::sendCommand(uint16_t, uint8_t, void*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:683:41: warning: variable length array 'txBuffer' is used [-Wvla]
    uint8_t txBuffer[sizeof(pktHdr) + plen];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp: In member function 'virtual void HCIClass::handleEventPkt(uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:979:33: warning: variable length array 'BD_ADDRs' is used [-Wvla]
    uint8_t BD_ADDRs[num_keys][6];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:980:29: warning: variable length array 'LKs' is used [-Wvla]
    uint8_t LKs[num_keys][16];
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:979:13: warning: unused variable 'BD_ADDRs' [-Wunused-variable]
    uint8_t BD_ADDRs[num_keys][6];
    ^~~~~~Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HtmlColor.cpp.o
    ~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:980:13: warning: unused variable 'LKs' [-Wunused-variable]
    uint8_t LKs[num_keys][16];
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HtmlColorNameStrings.cpp.o
    ^~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:981:10: warning: variable 'nAddresss' set but not used [-Wunused-but-set-variable]
    auto nAddresss = [pdata](uint8_t nAddr)->uint8_t*{
    ^~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:984:10: warning: variable 'nLK' set but not used [-Wunused-but-set-variable]
    auto nLK = [pdata](uint8_t nLK)->uint8_t*{
    ^~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:999:8: warning: unused variable 'cmdHardwareError' [-Wunused-variable]
    } cmdHardwareError = (CmdHardwareError)&pdata[sizeof(HCIEventHdr)];
    ^~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1099:17: warning: unused variable 'address' [-Wunused-variable]
    uint8_t address[6];
    ^~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1100:17: warning: variable 'BDAddr' set but not used [-Wunused-but-set-variable]
    uint8_t BDAddr[6];
    ^~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1320:25: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
    for(int i=0; i<sizeof(pairingConfirm.cb);i++){
    ~^~~~~~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1330:25: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
    for(int i=0; i<sizeof(HCI.remotePublicKeyBuffer); i++){
    ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1329:19: warning: variable 'remotePublicKeyReversed' set but not used [-Wunused-but-set-variable]
    uint8_t remotePublicKeyReversed[sizeof(HCI.remotePublicKeyBuffer)];
    ^~~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCI.cpp:1016:7: warning: case value '10' not in enumerated type 'LE_META_EVENT' [-Wswitch]
    case 0x0A:{
    ^~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp: In function 'void bleLoop()':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:123:68: warning: 'us_timestamp_t mbed::TimerBase::read_high_resolution_us() const' is deprecated: Use the Chrono-based elapsed_time method. If integer microseconds are needed, you can use elapsed_time().count() [since mbed-os-6.0.0] [-Wdeprecated-declarations]
    last_update_us += (uint64_t) timer.read_high_resolution_us();
    ^
    In file included from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/mbed.h:83,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed.h:8,
    from .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:23:
    C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/drivers/include/drivers/Timer.h:104:20: note: declared here
    us_timestamp_t read_high_resolution_us() const;
    ^~~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:145:72: warning: 'us_timestamp_t mbed::TimerBase::read_high_resolution_us() const' is deprecated: Use the Chrono-based elapsed_time method. If integer microseconds are needed, you can use elapsed_time().count() [since mbed-os-6.0.0] [-Wdeprecated-declarations]
    uint64_t time_spent = (uint64_t) timer.read_high_resolution_us();
    ^
    In file included from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/mbed.h:83,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed.h:8,
    from .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:23:
    C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/drivers/include/drivers/Timer.h:104:20: note: declared here
    us_timestamp_t read_high_resolution_us() const;
    ^~~~~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:156:55: warning: 'void rtos::ThisThread::sleep_for(uint32_t)' is deprecated: Pass a chrono duration, not an integer millisecond count. For example use 5s rather than 5000. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
    rtos::ThisThread::sleep_for(wait_time_ms);
    ^
    In file included from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/rtos/include/rtos/rtos.h:30,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/mbed.h:24,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed.h:8,
    from .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:23:
    C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/rtos/include/rtos/ThisThread.h:216:6: note: declared here
    void sleep_for(uint32_t millisec);
    ^~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:156:55: warning: 'void rtos::ThisThread::sleep_for(uint32_t)' is deprecated: Pass a chrono duration, not an integer millisecond count. For example use 5s rather than 5000. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
    rtos::ThisThread::sleep_for(wait_time_ms);
    ^
    In file included from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/rtos/include/rtos/rtos.h:30,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/mbed.h:24,
    from C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed.h:8,
    from .pio\libdeps\nano33ble\ArduinoBLE\src\utility\HCICordioTransport.cpp:23:
    C:\Users\rahnl.platformio\packages\framework-arduino-mbed\cores\arduino/mbed/rtos/include/rtos/ThisThread.h:216:6: note: declared here
    void sleep_for(uint32_t millisec);
    ^~~~~~~~~
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HtmlColorNames.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\HtmlColorShortNames.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp: In member function 'virtual void L2CAPSignalingClass::handleSecurityData(uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp:271:8: warning: unused variable 'pairingFailed' [-Wunused-variable]
    } pairingFailed = (PairingFailed)data;
    ^~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp:320:7: warning: unused variable 'readPublicKeyCommand' [-Wunused-variable]
    } readPublicKeyCommand = {
    ^~~~~~~~~~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp: In member function 'virtual void L2CAPSignalingClass::smCalculateLTKandConfirm(uint16_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp:421:19: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
    for(int i=0; i<sizeof(Eb); i++){
    ~^~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp: In member function 'virtual void L2CAPSignalingClass::handleSecurityData(uint16_t, uint8_t, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\L2CAPSignaling.cpp:296:13: warning: 'i' may be used uninitialized in this function [-Wmaybe-uninitialized]
    for(int i; i<6; i++) peerAddress[5-i] = identityAddress->address[i];
    ^
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\NeoGammaDynamicTableMethod.cpp.o
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp: In member function 'int BluetoothCryptoToolbox::f5(uint8_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*)':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp:63:13: warning: variable 'ADD_M' set but not used [-Wunused-but-set-variable]
    uint8_t ADD_M[7];
    ^~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp:64:13: warning: variable 'ADD_S' set but not used [-Wunused-but-set-variable]
    uint8_t ADD_S[7];
    ^~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp: In member function 'void BluetoothCryptoToolbox::testAh()':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp:138:13: warning: variable 'r' set but not used [-Wunused-but-set-variable]
    uint8_t r[3] = {0x70,0x81,0x94};
    ^
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp:139:13: warning: unused variable 'expected_AES' [-Wunused-variable]
    uint8_t expected_AES[16] = {0x15,0x9d,0x5f,0xb7,0x2e,0xbe,0x23,0x11,0xa4,0x8c,0x1b,0xdc,0xc4,0x0d,0xfb,0xaa};
    ^~~~~~~~~~~~
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp: In member function 'void BluetoothCryptoToolbox::testg2()':
    .pio\libdeps\nano33ble\ArduinoBLE\src\utility\btct.cpp:173:13: warning: unused variable 'AES' [-Wunused-variable]
    uint8_t AES[16] = {0x15,0x36,0xd1,0x8d,0xe3,0xd2,0x0d,0xf9,0x9b,0x70,0x44,0xc1,0x2f,0x9e,0xd5,0xba};
    ^~~
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\NeoGammaTableMethod.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\Rgb48Color.cpp.o
    Archiving .pio\build\nano33ble\lib6ac\libArduinoBLE.a
    Archiving .pio\build\nano33ble\lib876\libSPI.a
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\RgbColor.cpp.o
    Archiving .pio\build\nano33ble\libbbe\libHardwareBLESerial.a
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\RgbColorBase.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\Rgbw64Color.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\RgbwColor.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\colors\SegmentDigit.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\Esp32_i2s.c.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\NeoEsp32RmtMethod.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\NeoEsp8266I2sMethodCore.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\NeoEsp8266UartMethod.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\NeoEspBitBangMethod.cpp.o
    Compiling .pio\build\nano33ble\libdb7\NeoPixelBus\internal\methods\NeoPixelAvr.c.o
    Compiling .pio\build\nano33ble\FrameworkArduinoVariant\variant.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\Interrupts.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\Serial.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\Tone.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\USB\PluggableUSBDevice.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\USB\USBCDC.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\USB\USBSerial.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\WMath.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\abi.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\api\Common.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\api\IPAddress.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\api\PluggableUSB.cpp.o
    Archiving .pio\build\nano33ble\libdb7\libNeoPixelBus.a
    Compiling .pio\build\nano33ble\FrameworkArduino\api\Print.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\api\Stream.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\api\String.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\arm_hal_random.c.o
    Compiling .pio\build\nano33ble\FrameworkArduino\as_mbed_library\variant.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\itoa.c.o
    Compiling .pio\build\nano33ble\FrameworkArduino\main.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\mbed\platform\cxxsupport\mstd_mutex.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\pinToIndex.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\random_seed.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\timer.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\wiring.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\wiring_analog.cpp.o
    Archiving .pio\build\nano33ble\libFrameworkArduinoVariant.a
    Compiling .pio\build\nano33ble\FrameworkArduino\wiring_digital.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\wiring_pulse.cpp.o
    Compiling .pio\build\nano33ble\FrameworkArduino\wiring_shift.cpp.o
    Archiving .pio\build\nano33ble\libFrameworkArduino.a
    Linking .pio\build\nano33ble\firmware.elf
    Checking size .pio\build\nano33ble\firmware.elf
    Building .pio\build\nano33ble\firmware.bin
    Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
    RAM: [=== ] 26.7% (used 69920 bytes from 262144 bytes)
    Flash: [=== ] 33.3% (used 327476 bytes from 983040 bytes)
    ======================================================= [SUCCESS] Took 45.36 seconds =======================================================
  • Terminal will be reused by tasks, press any key to close it.

Only the first light is lighting up

Hi, first of all really appreciate you hard work for such a product so many of us with some time on our hands can save some really good money here.

However I seem to be having issues getting my setup to work. I have followed the instructions to a T and I am able to successfully connect to the board. The issue is only the first light seem to come on no others. I have tested everything in isolation the lights and power supply function by using another data source from another led controller. Tested the Arduino board by flashing a neopixel light cycle sketch in Arduino ide and all lights cycled through the colours. Just this project I am pulling my hair out here. Compile and uploads complete with no errors or problems reported.

I have the moonboard mini and have adjusted the config file as explained.

Wiring diagram

          @FabianRig 

I'm an electrical newb, so would you mind checking this diagram since you offered above? I just called the power lines positive and negative for simplicity since it seems like they can have different labels depending on the product. Hope it's clear enough.

Another question, you mentioned putting the resistor between the Arduino and LED data -- does the wattage rating matter for the resistor, or what do you recommend / use in your system?

image

Originally posted by @scott-lin in #7 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.