Beomote as sender
Ion3 opened this issue · comments
Hej,
is it possible to use your library for Arduino to control B&O devices via IR? I understand your example to receive commands from the BEO4, but do you also have an example where the Arduino controls B&O devices via IR? (e.g. turning on TV by pressing a button on the Arduino)
Mange tak,
Timo
Hey
At the moment the library only supports receiving b&o commands but it should not be that hard to implement a transmitter as well.
I have no plans of implementing a transmitter though, but feel free to use my code for guidance and information of the b&o ir protocol.
Med venlig hilsen
Christian Lykke
On 30/01/2014, at 17.40, Ion3 notifications@github.com wrote:
Hej,
is it possible to use your library for Arduino to control B&O devices via IR? I understand your example to receive commands from the BEO4, but do you also have an example where the Arduino controls B&O devices via IR? (e.g. turning on TV by pressing a button on the Arduino)
Mange tak,
Timo—
Reply to this email directly or view it on GitHub.
Hej Christian,
kunne du hjælpe mig lidt? I am looking for the following four commands:
typedef enum beo_command
{
STANDBY = 0x0C,
TV = 0x80,
VOLUME_UP = 0x60,
VOLUME_DOWN = 0x64,
}
But I cannot understand how the modulation of the IR signal has to be done.
Med venlig hilsen,
Timo
The Interrupt is fast enough for this may it's hard to set it to 455kHz
Dear Christian
I am still struggling with the modulation and started the following topic:
http://forum.arduino.cc/index.php?topic=228399.0
Is my understanding of the protocol so far correct?
Hilsen,
Timo
Hey Timo
Bang & Olufsen uses manchester biphase code which you can learn about on e.g. Wikipedia.
Your understanding of the protocol looks okay but there is a 8 bit address and 8 bit command instead of a 16 bit command.
Instead of using digital write I would start a timer pulsing on one of the pwm pins.
Where are you from?
On 25/03/2014, at 10.40, Ion3 notifications@github.com wrote:
Dear Christian
I am still struggling with the modulation and started the following topic:
http://forum.arduino.cc/index.php?topic=228399.0Is my understanding of the protocol so far correct?
Hilsen,
Timo—
Reply to this email directly or view it on GitHub.
Hej Christian,
here is, where you are starting your timer, correct?
Beomote.cpp:
void Beomote::initialize(int pin) {
irPin = pin;
// Setting the pinmode of the IR pin and resetting the listener
pinMode(irPin, INPUT);
reset();
// Clearing Control Register A
TCCR1A = 0;
// Setting the phase and frequency correct pwm, and stopping the timer
TCCR1B = _BV(WGM13);
long cycles = (F_CPU / 2000000) * TICK;
ICR1 = cycles;
TCCR1B &= ~(_BV(CS10) | _BV(CS11) | _BV(CS12));
// Setting the timer overflow interrupt enable bit
TIMSK1 = _BV(TOIE1);
// Resetting clock select register, and starts the clock with no prescale
TCCR1B |= _BV(CS10);
}
This is really something I still not understand! Is the PWM pulsing with 455 kHz here? TICK has been defined as 625 in Beomote.h.
I still need to learn a lot...
I am actually from Flensburg - near to the Danish border. :-)
Hi Timo
Yes that is where I start the timer. But I only listen every 625microsecond so you cannot use that.
I have been working a little on implementing the transmitter but I found out that the fastest arduino timer ticks every 62.5microsecond. So we need some kind of hardware modulation to send data modulated at 455kHz.
Hi Christian,
hardware modulation might work with a NE555. Besides that, the PWM library (http://forum.arduino.cc/index.php?topic=117425.0) seems to work with up to 2 MHz. What do you think?
Shouldn’t it be possible to send out a frequency of 455 kHz out of one pin and then send it to the IR-LED using a transistor connected to a second pin?
Hi all,
I had the same problem and was searching for a B&O IR transmitter library.
After studying the timer functions of the Arduino and the IR protocol (Christians collection of HEX codes helped a lot!) I was able to create a working library.
I am using Timer1 to create the modulation frequency. It is not possible to set it exactly to 455KHz but to 444KHz instead. Frequency is tested with oscilloscope. Works quite well for me.
Gives you a range of about one meter if you connect the IR LED without a transistor directly to the Arduino PIN 9 and GND.
See my repository here: https://github.com/PolyVection/PolyIR
Best regards,
Philip.
Hey Philip
Thank you so much! Your repository was the solution for my challenge. You've made my day!
Greetings,
Timo
Hi,
Does anybody still have the SendRepository for BEO4 accessible? It seems to be deleted from PolyVection github.
Thanks.
Daniel
Hi Philip, i have the same problem as Daniel,can you please share your work with us? , the polyvection folder is not available to us anymore. For my part, i try to interface alexa (amazon echo dot) and an arduino to pilot a beosound device...
Dear @cdf1982,
dear @frank-trampe,
I hope the attached helps. I haven't progressed in this project. Do you think there might be a solution to implement the Bang & Olufsen IR Codes in one of this projects?
Greetings,
Timo