JL1N PLC re-purposing for home automation
Thees are my findings:

CPU STM32F103RCT6

Input voltage seems to work without problems from 12v-24v. Has onboard 5v and 3.2v regulators.

BOOT0 default LOW, set jumper for HIGH
BOOT1 (PA2) is set to LOW

RS232 PA9 PA10 (USART1) for programming when BOOT0=HIGH
Onboar serial port TX PC10 and RX PC11 (USART3)

RESET is the common point between R24 and C14 active on LOW

Run LED PB6

Switch RUN when PC1 to GND ?

AIN PA4
AOUT ?

Outputs (8 rellays active on HIGH):
Y0 PD2
Y1 PA12
Y2 PB10
Y3 PB11
Y4 PB12
Y5 PB13
Y6 PB14
Y7 PB15

Inputs (12 active when pulled to ground):
X0 PA0
X1 PA1
X2 PC5
X3 PC6
X4 PC7
X5 PC4
X6 PA6
X7 PA7
X8 PB0
X9 PB1
X10 PA3
X11 PC12


I was able to program the board with stm32loader. I was able to build working firmware using STM32Cube but sadly had 0 success with PlatformIO.