Ardupilot and modems on serial port

I’m currently designing and prototyping a light weight quad and want to connect my superlight 3g modem directly to my ardupilots UART. I got a few AT commands to connect to internet, but is there any way to enter them in ardupilot ? I could of course use a companion computer, but i want to save as much weight as possible.