Setup IAX2 trunks between the boxes HO to A, HO to B and A to B, use from-internal context on the trunks and change extension numbers so they are different on each box, perhaps box A 200-205 and box B 300-305, then use outbound route patterns to route calls to the correct box. You can limit the number of channels available on the IAX2 trunks. It will then behave like a single PBX or with such a small number of extensions you could locate one box at HO and run all the extensions from that one box.