Dear all,
I bought ‘beams’ from http://www.hoverlabs.co/guide/beam-basics and hooked up like described.
After flashing example code my photon breathing green and no text appears on the led.
After ca. 5 minutes the green breathing changes to blue - 30 seconds after blue its green again.
First I changed the arduino code the pins to D2 and D3 and
second I copied the libaries (beam.h, beam.cpp, frames.h and charactermap.h) into the webide.
#include "Particle.h"
#include "beam.h"
/* pin definitions for Beam */
#define RSTPIN D2 //use any digital pin
#define IRQPIN D3 //currently not used
#define BEAMCOUNT 1 //number of beams daisy chained together
/* Iniitialize an instance of Beam */
Beam b = Beam(RSTPIN, IRQPIN, BEAMCOUNT);
/* Timer used by the demo loop */
unsigned long updateTimer = 0;
int demo = 0;
void setup()
{
Serial.begin(9600);
Wire.begin();
Particle.function("scroll", beamScroll);
b.begin();
}
void loop()
{
}
int beamScroll(String command)
{
b.begin();
b.print("This is my text.");
b.setSpeed(3);
b.setLoops(3);
b.play();
return 0;
}
Before flashing I got this message from webide:
You are not including
charactermap.h
frames.h
even though they are a part of this app.
Are you sure you want to continue?
To include these files, please hit cancel and add include lines to the top of the to the top of the main app file.
If I add these missing 2 files with #include I got code errors in beam.cpp.
Now I´m confused to setup my first example.
Best regards,
Since you are not stating a SYSTEM_MODE and are also not using SYSTEM_THREAD, breathing green will indicate that your code is stalled (probably inside the Beam
library - there are several places in the lib where this can happen if the I2C communication does not work - e.g. due to wrong wiring or missing pull-up resistors)
You said
Are you using the beam_arduino
or the beam_particle
library?
My jumper setting:
Beam <> Photon
HOST V+ / 3V3
3.3V / 3V3
GND / GND
SYNC / not in use but set to D3
RESET / D2 for Beginner Example
IRQ / not in use
SCL / D1 (found in particle doc)
SDA / D0 (found in particle doc)
Using (4) beam_particle files.
I’m not sure if the beams have I2C pull-up resistors.
Either you can check if they have or just add your own.
My hoverlab beams works with arduino uno r3 and with raspberry pi, but I cant wire it correctly with my photon. Any ideas from the makers here? Best regards from Germany!
Have you considered my proposal at all?
@Postler, I’ve had a beam working with a Photon just fine for months now. The board does not need pull-ups but your code and wiring are important. I’ll check your wiring against mine when I get home tonight.
1 Like
Still in standby - waiting for your check!
@Postler, looking at your wiring, the only difference for me is that I do NOT have SYNC on the beam connected to anything. I don’t have I2C pull-ups since the beam has them already. I created an app on the web IDE with beamdemo1 example and tabs for the library files including charactermap.h and frames.h. I compiled using the newest v0.6.2-rc.1 firmware and flashed it to my photon. Everything works as expected.
Have had an hardware problem with my photon device. Changed it and it works. Thx all.
1 Like