Use a test light, and check your under dash fuse for an open slot that would be controlled by the ignition key, in the "on" position. Then run a wire from that slot and use a relay to close a circuit to your accessory, powered directly by the battery.