During our pavilion research & fabrication, we found that IR positioning camera(a diversion of WII controller camera) can be very helpful for small-scale indoor localization due to its high-performance(270 HZ data) and easy-to-use property.
The IR cam can detected at most 4 IR beacons and output their positions in camera though 1023 x 1023 pixels. For instance if an IR beacon is in the center of camera view, the output info of camera is 512,512. Detailed information can be seen at IR Positioning Camera For Arduino and Positioning ir camera(WIKI)
However, in pavilion we just used the IR camera to track 2 IR beacons, which means the camera and IR beacons both have to be in XY plane, thus fixing the rotations, to calculate a correct translation information. This scenario of application is very limited and not applicable for where you need a rotation transformation.
Therefore, I put 4 IR beacons in a plane as corners of a square, which forms a plane with 6DoF info. Then use OpenCV to calculate a transformation matrix between camera and beacons, including Translation, Scale and Rotation.
A ROS package is developed for it, since I would later apply this localization solution to a drone, which helps the drone to locate objects that’s underneath.
The video above shows an IR camera connected to a Raspberry Pi 3, detecting 4 IR LEDs and return points to ROS for calculation.
Go to my github repository for further info.