some modules require only an \r or an \n to validate the AT command but may be not both. Some ignore the \r but not always. Some would actually work without entering CR/LF
I'd be tempted to say \n is your command line validator and the \r was kept as part of the name
try just mySerial.print("AT+NAMEDemo\n");
The name on the board is just the name of the board and not relevant. They could be the other way round, There seems to be little variations in the AT commands. I don't think they cause any grief. It doesn't in your case does it?
Yes, you're right, I'm having issues connecting to the module since our app connects to a specific module name say 'Demo', and won't be able to connect to it if its 'Demo '
Will try flashing the original HM10 firmware on the Module B to see if that helps.
Thanks