I want to create a command to simplify using the command `lstinputlisting` from the package listings, which can accept a single parameter as the file path and pass it to both the caption and path parameter of lstinputlisting. In one word, use the file path as the caption. 

Consider the following LaTeX source:

```
\documentclass[UTF8]{ctexart}
\usepackage{listings}

\newcommand{\myincludecode}[1]{\lstinputlisting[caption=#1, language=matlab]{#1}}
\newcommand{\mysecondincludecode}[2]{\lstinputlisting[caption={#2}, language=matlab]{#1}}

\begin{document}

\myincludecode{main.m}                        % line 10
\myincludecode{gen_data.m}                    % line 11

\mysecondincludecode{main.m}{main.m}          % line 13
\mysecondincludecode{gen_data.m}{gen\_data.m} % line 14

\end{document}

```

Clearly, the commands in line 13 & 14 work well, which both correctly include the corresponding file and print the corresponding captions.

The line 10 also works well. However, the line 11 includes the corresponding file but outputs no caption. The log file says:

```
Try.tex|11 error| Missing $ inserted.
Try.tex|11 error| Extra }, or forgotten $.
Try.tex|11 error| Missing $ inserted.
Try.tex|11 error| Missing } inserted.

```

It's obvious that the underscore breaks down my command. So, I wonder how to modify `myincludecode` to make it work - even when meeting some special characters, such as the underscore here.