Data logging in caves. The problem divides into several parts:
(a) the sensor
(b) the logger
(c) the protective container to make it waterproof
(d) stopping people stealing or meddling with it ? security or concealment.
The sensor might be for light (to count cavers or groups of cavers); water pressure (to log flood pulses); shock (to count drips); temperature; humidity; and so on. The output might be logic level ? implying light or no light. The output might be analog (on a scale of say 0-5 volts or 4-20mA current across a resistor to convert that to a voltage) to represent water depth from a submersible sensor in a cave river: some loggers will simply record a voltage every hour, every minute, or whatever gap you set it for, and you convert that to real world units using Excel or etc later on. The output might be digital on a scale of 0-4095 (or some other encoding system) to represent temperature: this is typical of half-degree C or sixteenth of a degree ?I2C? digital temperature sensor chips like this: https://datasheets.maximintegrated.com/en/ds/DS1631-DS1731.pdf
The sensor might use a lot of power when turned on, e.g. to measure hydrocarbongas like methane or diesel fumes in the air or some types of water depth sensor. In which case, to be economical with power and long lasting with batteries, the logger must be smart enough to turn on the sensor only when it wants a reading, then wait for the correct sensor warm up period, then get several concordant readings and average them, and then turn the sensor off, go to sleep and wake up when a new reading is wanted if it is to do a good job. Such a micropower logger is not available commercially, to my knowledge, so you are then in a DIY world.
The logger will have flash memory to store data. This has to be downloaded before it gets full (implies using two loggers that are alternated between each cave visit as you won?t want to take a PC underground) or you must change the flash memory card/module for a spare during your cave visit then restart the same logger with a new memory for a run of another few days/weeks/months.
CO2 sensors ? the hot topic of the moment, see posts above.
Temperature sensors ? build your own with DS1631 type of I2C chips, or Tinytag sell a line of inexpensive humidity and temperature loggers, the sort of thing put inside display cabinets in museums or in chilled food lorries.
Humidity ? forget it if the cave is very humid, these sensors don?t work too well above 90%RH.
Caplamp lights ? its DIY again, use a photodiode and an opamp circuit, possibly fed through a microprocessor that checks for several instances of light within the same second to check it really is a caver as photodiodes (in total darkness) will trigger spontaneously about once a month or quarter ? you have been warned ? perhaps due to radioactive decay.
Drips ? build a piezo sensor using a buzzer disc and a comparator to process the signal ? its DIY again but pretty simple.
Water depth ? Honeywell has a line of ?20 sensors with analog output that needs an opamp circuit to raise the voltage up to a sensible level for logging. General Electric sell ?200 sensors which are the ones logging hourly in the OFD streamway for some years and these are 4-20mA output and these have a warm up time of a second or so to get a stable reading.
Power consumption is a big issue if custom gear is left running for months between cave visits, logging at least hourly and run off alkaline cells like AA or C size. To overcome the difficulties competently implies significant electronics know-how plus ability to write custom firmware.
http://bcra.org.uk/creg/ is the right place to head for ideas or to network with more experienced people. The CREG runs a weekend field meeting once or twice a year, so you can combine electronics including radio/comms/logging with caving trips and social activities ? highly recommended.