fig1 shows an exemplary system that tracks medication taken by a patient . in this system , a power source 10 such as a battery provides power for a pill box 44 ( as shown in fig3 ). a pill pouring detector is used to connect the power terminal of the power source 10 to a control electronic 20 when pills are poured from the pill box 44 so that the patient can take the medication . in one embodiment , the pill pouring detector is a tilt - sensor . the tilt - sensor can include a pendulum 12 that contacts an electrode 14 when the pills are poured from its respective compartment . a wire 11 connects the pendulum 12 to the power source 10 at terminal a , while a wire 13 connects the electrode 14 to the control electronic 20 at terminal b . the pendulum 12 can be connected to an optional spring ( not shown ) to enable the pendulum 12 to contact the electrode 14 quickly . in one embodiment , one end of the spring is attached to the pill box and the other end attached to the top of the pendulum 12 . the spring assists the pendulum to touch the electrode 14 , thereby forming a conductive circuit for powering the electronic 20 . the pendulum 12 can also be connected to an optional return spring ( not shown ) to enable the pendulum 12 to separate quickly . the electrode 14 can also have an optional magnet ( not shown ) to attract the pendulum 12 . in other embodiments , an accelerometer can be used to sense motion , or a magnet sensor can be used to detect the pill - pouring act by the patient . in yet other embodiments , a photo - detector or a camera can be positioned underneath the pill box to sense the presence or absence of pill ( s ) after the door is opened , for example . other approaches can be used to detect pill pouring as well . the control electronic 20 can be an integrated processor and radio system - on - a - chip . in one embodiment , the control electronic 20 can be a mesh network system such as zigbee system , for example . suitable control electronic 20 can include one chip solutions from freescale and texas instruments / chipcon , among others . the control electronic 20 has integrated mesh - network wireless transceivers , in this case zigbee transceivers whose network features are described in more details in fig2 . the processor can maintain clock data using interrupt handling , or alternatively a real - time clock chip can be used to provide time of day information with precision . in one implementation , the doors and corresponding door tabs that keep the door secured when closed are made of a conductive material such as silver or conductive plastics . when closed , the door and the door tab are electrically shorted together and thus form a circuit . when opened , the door and the door tab are electrically isolated , and the closing or opening of each door can be determined by sampling the current or voltage present on each door . the data input and output pins of the processor can be connected to door opening detection switches 16 using suitable pull - up resistors 18 . alternatively , pull - down resistors can be used to detect door openings / closings . the door opening / closing sensor is one type of pill dispensing sensor , and other sensors can include a motion sensor ( such as pir sensor ), a pendulum , an accelerometer , or a magnetic sensor . optionally , a power switch 19 can be provided to allow the control electronic 20 sufficient time to complete its operation before releasing power in case the pendulum 12 separates from the electrode 14 before the control electronic 20 is ready . when power is initially applied by the pendulum 12 , the control electronic 20 turns on the switch 19 to assure that power will be available as long as needed . when the control electronic 20 is done , it disables the power switch 19 to cut off power . the power switch 19 can be an electromechanical relay or a power transistor or any other suitable switches . the use of the pendulum 12 thus conserves battery energy and the use of the power switch 19 enables an orderly shut - down by the control electronic 20 . the control electronics 20 communicate wirelessly with a computer 20 which is connected to a wide area network 30 such as the internet . the computer 20 can be a home server which authorized persons can log - in to monitor drug usage by the patient . alternatively , the computer 21 can transfer data over the wan 30 to a remote server which centralizes data from the patient for one or more groups to review . fig2 shows an exemplary mesh network for medication compliance data transmission by the system of fig1 . in one embodiment , the mesh network is an ieee 802 . 15 . 4 ( zigbee ) network . ieee 802 . 15 . 4 defines two device types ; the reduced function device ( rfd ) and the full function device ( ffd ). in zigbee these are referred to as the zigbee physical device types . in a zigbee network a node can have three roles : zigbee coordinator , zigbee router , and zigbee end device . these are the zigbee logical device types . the main responsibility of a zigbee coordinator is to establish a network and to define its main parameters ( e . g . choosing a radio - frequency channel and defining a unique network identifier ). one can extend the communication range of a network by using zigbee routers . these can act as relays between devices that are too far apart to communicate directly . zigbee end devices do not participate in routing . an ffd can talk to rfds or other ffds , while an rfd can talk only to an ffd . an rfd is intended for applications that are extremely simple , such as a light switch or a passive infrared sensor ; they do not have the need to send large amounts of data and may only associate with a single ffd at a time . consequently , the rfd can be implemented using minimal resources and memory capacity and have lower cost than an ffd . an ffd can be used to implement all three zigbee logical device types , while an rfd can take the role as an end device . in other embodiments , bluetooth transmitters , cellular transmitters , wifi transmitters , or wimax transmitters can be used . fig3 shows an exemplary pill box . in this embodiment , the pill box has a seven - day planners with removable dividers that allow for 1 or 2 compartments for storing medicine . the pill box enables the patient to keep all of your medicines organized by day and time of day ( am / pm ). the top of each lid has the first letter of each day of the week imprinted on it in very large black letters . in addition each letter can be stamped out in braille . the pill box 44 has a compartment 50 with a door 40 with a conductive tab that acts as a switch 16 . upon door closure , the switch 16 is closed and upon door opening , the switch 16 is in an open state to indicate to the control electronic 20 that the door is in an open state or a closed state . the switch 16 can be made of a conductive elastomeric material or a silver ink or any other suitable conductor as long as the material can handle repetitive door openings and closings . fig4 a - 4b show an exemplary detector in the pill box of fig3 to detect the pouring of pills from a compartment of the pill box . fig4 a shows a compartment 50 having a door 40 at a rest ( not tilted ) position . the electrode 14 is connected to the wire 13 to terminal b , while the pendulum 12 is connected to the wire 11 to terminal a . the pendulum 12 is swivably mounted on a hinge 15 . fig4 b shows the pill box being tilted . as a result of the tilt , the pendulum 12 contacts the electrode 14 to complete the circuit and provide power to the control electronic 20 . this approach turns on power only when necessary , and thus saves battery life and provides for a carefree operation where the patient needs not worry about battery replacement as the pill box can last for years . the pill box can be designed so that the battery can be replaced . alternatively , the pill box can be disposable so that when the battery is depleted , a new pill box can be used to provide recurring revenue for the manufacturer . fig5 shows an exemplary method for dispensing one or more pills from the pill box . the method applies power to the control electronic 20 when the one or more pills are poured from the pill box ( 100 ). the control electronic 20 then identifies an opened compartment and an opening time ( 102 ). as discussed above , the switches 16 are used to determine the opening of one or more doors and a real - time clock chip can be used to determine the time of door opening . the control electronic 20 records the opened compartment and the opening time ( 104 ). the control electronic 20 also checks the opening time against one or more medication constraints and if so , generates an alarm if the medication constraint is violated ( 106 ). the medical constraints are typically set by the pharmaceutical company , by the fda , or by the doctor . the constraints can be , for example , taking medication on a non - empty stomach or alternatively can be taking medication on an empty stomach . the control electronic 20 also checks for multiple compartment openings during one medication dispensing event and if so , generates an alarm ( 108 ). the control electronic 20 wirelessly transmits the recorded opened compartment and opening time to a computer ( 110 ) that can be the patient &# 39 ; s home computer with a mesh network wireless communication device mounted therein to receive the data . the computer can store the data , or can upload the data to a central server over the internet 30 . the computer or the server can allow one or more authorized persons to review the medication dispensing ( 112 ) and can also request a medication refill ( 114 ). fig6 shows an exemplary method for dispensing pills / compliance monitoring and collecting patient data as well as providing educational information to the patient regarding the treatment using the pill box . the process optionally asks if the patient would like information about medication and if so display a summary of the medication , requirements prior to taking medication , and potential side effects or warnings ( 200 ). the information can be supplied by a pharmacist and downloaded or programmed into the pill box for display . alternatively , the pill box can access a search engine and provide the information to the patient . next , the system identifies an opened compartment and an opening time ( 202 ) and records the opened compartment and the opening time ( 204 ). the system checks the opening time against one or more medication constraints and if so , generates an alarm if the medication constraint is violated ( 206 ). the system can check for multiple compartment openings during one medication dispensing event and if so , generate an alarm ( 208 ). optionally , the pill box can query other devices to collect information on patient ( 210 ). for example , the pill box can prompt the patient to obtain ekg and / or blood pressure from a suitable device that communicates over the mesh network . the data is collected and saved by the pill box electronic . the pillbox can also optionally display one or more predesigned questions about the user &# 39 ; s health and collect answer ( s ) from the question ( s ) ( 212 ). such questionnaires can include questions on the patient &# 39 ; s general feeling and health assessment , questions on the patient &# 39 ; s sugar level and blood pressure , questions about the type of food , the type of exercise , or any other questions that a healthcare plan , medicare / medicaid , employer health plan , or other suitable payors or physicians , nursing home directors , or family members may want the system to collect . the system then wirelessly transmits the recorded opened compartment ( s ) indicative of medication compliance and other collected patient data to a computer ( 214 ). the data is sent to a server and one or more authorized persons can , upon authentication , review the medication compliance information and collected patient data ( 216 ). the system can also requests a medication refill if needed ( 218 ). in yet another embodiment , a pillbox is positioned on a scale or weight measurement device . the weight of each pill to be taken by a person is identified in advance , and the total weight of all pills to be taken in one batch , for example morning pills , is determined . when the pillbox is removed and placed back on the cradle , the new weight of the pillbox is determined . if the new weight is approximately equal to the old weight minus the total weight of pills to be taken in one patch , the system infers that the pills have been removed and ( presumably ) taken by the patient . if the new weight is not as expected , an error is indicated so that the patient , a caretaker , or the physician is notified of a potential drug non - compliance . while the system above monitors the dispensing one or more pills from a pill box by applying power when the one or more pills are poured from the pill box ; identifying an opened compartment and an opening time ; and recording the opened compartment and the opening time , the system can also monitors the pill dispensing by applying power when the compartment door is opened and then detecting which door has been opened . hence , the tilt detector ( such as the pendulum ) is not needed in all embodiments .
systems and methods are disclosed for operating electronic components in a device by separating the devices into a high power group and a low power group ; constantly powering the low power group ; providing a movable device coupled to power when the device is moved ; and providing power to the high power group when the device is moved .