Always take your CPAP machine on an airplane as carry-on baggage. This prevents damage or loss in the event your checked baggage is mishandled or misplaced. Your CPAP machine is a medical device, so the limit of one carry-on bag and one personal bag (e.g. purse or briefcase) per traveler may not include your CPAP machine. Make sure to check with your airline prior to your flight.
Most airlines allow the use of the in-flight power supply to operate your CPAP machine. However, be sure to contact your airline ahead of time for the rules and regulations regarding in-flight CPAP use.