LIRC Send BPI using GPIO

Hi, has any of you manage to make LIRC work on BPI (particulary BPI-M2?) I want to use BPI as and infrared trasnmitter (rather than use the onboard receiver) using GPIO. I’ve managed to make it working under RPI following (, but lirc_rpi is not available for BPI. Can you help me please? Regards Martin