It's not clear to me why you're wanting to credit the miles to a BAEC account which I assume you also hold...however...
There's no problem with flying on BA, crediting miles to BAEC but using your AA card to get into the BA lounge. Where it risks going wrong is if you get your AA f/f number into the booking for the purposes of (e.g.) seat selection, that the flights will also post to the AA f/f account. What you need to do is prior to getting on the plane, ensure your BP shows your BAEC number and not the AA one - otherwise you'll have to sort out the mess afterwards (which could be tricky). You should ensure that your BP shows the f/f details of the program you want the flights credited to; you should be able to get this changed at the airport (i.e. at check-in, or at the lounge).