serial.available OK with IDE and KO with C language

I think you can't use the pin 0,1 with software serial (besides there is no point of doing that)