XIAO and IR Remote

I have been using an Arduino to send IR signals using IrLirbrary.h (Left setup). I am using a typical IR Led and also an npn transistor (s8050) to drive the IR Led from the Arduino (since the current provided by the Arduino GPIO ist not enough for the Ir Led). Now, this works fine, the Ir-Led draws about 16mA from 5v supply and I am getting my TV commands send from a good distance.
here is the Code:

#include <IRremote.hpp>

#define DECODE_NEC
#define IR_SEND_PIN 10

const int repeats = 3;

void setup() {

void loop() {
    IrSender.sendNECRaw(0xE7187F00, repeats);

For the Seeeduino XIAO (Right setup), when I use the same Setup and same Code, my IR-Led is working but it’s too weak, it transmits the data only on very close distances. The current drawn from the 5v supply is 8mA max. I suppose that the issue is with the 3,3V logic level of the XIAO. I believe that the IrLibrary is using PWM to send signals to the Ir-Led (Through a transistor in my case) and in the case of XIAO this “Pulses” are too weak to trigger the Transistor to allow more current through.
Any idea what should I look for? Should I be looking into another transistor? PWM shifter from 3.3 to 5v?
And please forgive me if I have misdescribed some electrical concepts, I am just a newbie hobbyist :slight_smile:

I have found the followig issues:

  1. I had a bad IR Led unit
  2. Wiring the npn transistor
    I have attached a new IR Led and changed the wiring a little bit and now it works as expected! The Ir Led is drawing an expected 20mA of current