Coder Social home page Coder Social logo

Comments (11)

ArminJo avatar ArminJo commented on May 25, 2024

Thanks for reporting 👍. Bug is now fixed 😀

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

Now, the timer selection its ok, but the sent data is random, i`m trying to send IrSender.Samsung(0x707, 0x7F, 0) and receiving

`Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[2]:
-65535
+1461
Sum: 1461
Raw result in microseconds - with leading gap
rawData[2]:
-3276750
+73050
Sum: 73050

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[1] = {255}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[1] = {73030}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0001 0000 0AFA 06C3 ";

Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[2]:
-284
+88
Sum: 88
Raw result in microseconds - with leading gap
rawData[2]:
-14200
+4400
Sum: 4400

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[1] = {88}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[1] = {4380}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0001 0000 00AA 06C3 ";

Protocol=UNKNOWN Hash=0x0 2 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[4]:
-283
+93,-94
+89
Sum: 276
Raw result in microseconds - with leading gap
rawData[4]:
-14150
+4650,-4700
+4450
Sum: 13800

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[3] = {93,94, 89}; // Protocol=UNKNOWN Hash=0x0 2 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[3] = {4630,4720, 4430}; // Protocol=UNKNOWN Hash=0x0 2 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0002 0000 00B4 00B4 00AC 06C3 ";

Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[2]:
-108
+80
Sum: 80
Raw result in microseconds - with leading gap
rawData[2]:
-5400
+4000
Sum: 4000

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[1] = {80}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[1] = {3980}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0001 0000 009B 06C3 ";

Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[2]:
-304
+68
Sum: 68
Raw result in microseconds - with leading gap
rawData[2]:
-15200
+3400
Sum: 3400

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[1] = {68}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[1] = {3380}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0001 0000 0084 06C3 ";

Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Raw result in internal ticks (50 us) - with leading gap
rawData[2]:
-103
+84
Sum: 84
Raw result in microseconds - with leading gap
rawData[2]:
-5150
+4200
Sum: 4200

Result as internal ticks (50 us) array - compensated with MARK_EXCESS_MICROS=20
uint8_t rawTicks[1] = {84}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Result as microseconds array - compensated with MARK_EXCESS_MICROS=20
uint16_t rawData[1] = {4180}; // Protocol=UNKNOWN Hash=0x0 1 bits (incl. gap and start) received

Pronto Hex as string
char prontoData[] = "0000 006D 0001 0000 00A2 06C3 ";`

the arduino code is:

`
#include <Arduino.h>

#define SEND_PWM_BY_TIMER // Disable carrier PWM generation in software and use (restricted) hardware PWM.
#define IR_USE_AVR_TIMER1 // Tested #define USE_TIMER_CHANNEL_B too... and commented line.
#define NO_LED_FEEDBACK_CODE

#include <IRremote.hpp>

uint16_t sAddress = 0x707;
uint8_t sCommand = 0x7F;
uint8_t sRepeats = 0;

void setup() {
IrSender.begin(); // Start with IR_SEND_PIN as send pin and if NO_LED_FEEDBACK_CODE is NOT defined, enable feedback LED at default feedback LED pin
}

void loop() {
IrSender.sendNEC(sAddress, sCommand, sRepeats);
delay(500); // delay must be greater than 5 ms (RECORD_GAP_MICROS), otherwise the receiver sees it as one long signal
}`

Environment:
bareboard attiny167
commented lines 297 and 315 of file IRTimers.hpp
uncommented lines 299 and 317 of file IRTimers.hpp

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

Environment:
bareboard attiny167
commented lines 297 and 315 of file IRTimers.hpp
uncommented lines 299 and 317 of file IRTimers.hpp

from arduino-irremote.

ArminJo avatar ArminJo commented on May 25, 2024

It works for me with Digispark Pro and SendDemo!

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

i will test tomorrow flashing the attiny167 with Digispark Pro and will comment to you. thank you very much!

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

my attiny167 is running at 8MHz, Digispark Pro Run at 16MHz could be this the problem?

from arduino-irremote.

ArminJo avatar ArminJo commented on May 25, 2024

we have : const uint16_t tPWMWrapValue = (F_CPU / 2000) / (aFrequencyKHz); // 210,52 for 38 kHz @16 MHz clock, 2000 instead of 1000 because of Phase Correct PWM so 8 MHZ is not a problem!
The Digispark has no PB5 available!

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

ok, i will change the esp8266 Receiver by an arduino nano and will make another tests. i will check the bareboard and connections to discard hardware issues.

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

It works for me with Digispark Pro and SendDemo!

are you using the PinDefinitionsAndMore.h file to test the Digispark Pro? can you test with another pin like PB1?

from arduino-irremote.

ArminJo avatar ArminJo commented on May 25, 2024

I tested it with PB1 and PB3

from arduino-irremote.

freskpe avatar freskpe commented on May 25, 2024

The problem was the attiny167 fuses... i compare Digispark Pro Fuses with attiny167 and default fuses divide the bus clock by 8...

in another order... if i comment the line #define DISABLE_CODE_FOR_RECEIVER the device stop workin, i will continue working and notice you anything... i dont know how to close a issue in github. sorry and thank you

from arduino-irremote.

Related Issues (20)

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.