The 2nd one obviously has a contact switch connected to a wireless transmitter. It could be just a test-bed. Open the lid to open the contact, close the lid to close the contact. You could use it all around the house to check the range of your wireless network, I suppose. Or you could attach it the door on a dog or cat flap so that the contact is closed when the door is up, thus alerting your home automation system to the departure or entrance of a dog or cat. Or maybe you could use it as some sort of break-sensor hidden under something, like may be a rug? If the lid breaks, your security system could be alerted. Hmmm...