Although it is said that HM-10 "can replace HC-05, HC-06, HC-07 etc", it is not exactly like that.
- AT commands are different. For example, to change the password, you should send AT+PSWD to HC-05 and AT+PASS to HM-10.
- In HC-05, your AT commands are separated by \r\n. In HM-10, AT commands are separated by a delay (I have no idea how big that delay should be).
- Command format is different too. With HC-05 it is like AT+NAME=ProgArm, but in HM-10 it is AT+NAMEProgArm.
These are some minor issues, but it means that you cannot simply replace HC-05 with HM-10 or vice versa.
We have made a script that can configure both. It will detect whether it is HM-10 or HC-05 automatically.