@@ -7,7 +7,7 @@ Most of the program is platform-independent, but there's a bit of extra convenie
77The program runs on Python 3, and requires the Requests and Beautiful Soup 4 libraries.
88
99####################################################################################################
10- Python & Libraries installation
10+ Python & Libraries installation:
1111####################################################################################################
1212Download and install Python 3 from the official website: https://www.python.org/downloads/
1313Make sure to check the option to add Python to PATH during the installation process.
@@ -24,18 +24,64 @@ Skip first line of HomeBrew is already installed.
2424brew install python
2525pip install requests beautifulsoup4
2626
27+ #################################################################################################
28+ Data Location:
29+ #################################################################################################
30+
31+ The default code (os.path.join etc) will place the file in the path below.
32+ Windows: C:\Users\MY_USERNAME\Documents\CPAP_Data
33+ MacOS: /home/MY_USERNAME/Documents/CPAP_Data
34+ Linux et al: /home/MY_USERNAME/Documents/CPAP_Data
35+
36+ You may need to create a directory named CPAP_Data in your Documents folder.
37+
38+ You can store it wherever you want to, as long as OSCAR can read from it. Just modify the configuration block with the location you prefer.
39+
40+
41+ #################################################################################################
42+ Configuration options & defaults
43+ #################################################################################################
44+
45+ START_FROM -- This has three options:
46+ 1) an integer indicating the number of days of history to download
47+ 2) a YYYYMMDD date indicating which date to start from
48+ 3) A string, 'ALL', removing date restrictions and downloading all available data
49+
50+ OVERWRITE -- This has two options:
51+ False - Don't overwrite any of the date-specific files. (other files must always be overwritten)
52+ True - delete and replace. This is mostly useful if you either accidentally deleted a partial date in OSCAR, or if you ran this and then went back to sleep before noon and wanted to ensure that the full day was captured
53+
54+ SHOW_PROGRESS -- This has three options:
55+ False - Shows fairly minimal output
56+ True - Shows date folder output
57+ Verbose - Shows what happens to every file
58+
59+
2760####################################################################################################
28- EZCard Setup & Usage
61+ EZCard Setup
2962####################################################################################################
3063By default, EzCard creates a wifi network named "Ez Card" with a password of 88888888 (that's eight eights)
31- To change the network name and password, create or edit a file named ezshare.cfg on the card.
32- You can also do it via the card's web interface: http://ezshare.card/config?vtype=0 (default card admin password is "admin").
64+ You can change the network name and password via the card's web interface:
65+ http://ezshare.card/config?vtype=0 (default card admin password is "admin").
66+
3367If necessary, deleting the ezshare.cfg file will change the network information back to the default.
3468
35- Create a directory named CPAP_Data in your Documents folder. (You can choose a different name, just edit it in the configuration.)
69+ EZSHARE_NETWORK = "Ez Card"
70+ EZSHARE_PASSWORD = "88888888"
3671
37- Edit the configuration section of the .sh file as needed.
3872
39- run the program from the command line:
40- python3 transferCardData.py
73+ #################################################################################################
74+ Retrieving files from the card
75+ #################################################################################################
76+ This may be called from its folder directly, with or without arguments to overwrite the defaults:
77+ python ezshare_resmed.py
78+ python ezshare_resmed.py --start_from 20230101 --show_progress Verbose --overwrite
79+ It may also be called from a shell script, so you can put that on your desktop
80+ while keeping the python code in a less accessible location:
81+ ./run_foo.sh
82+ ./run_foo.sh --start_from 20230101 --show_progress Verbose --overwrite
4183
84+ #################################################################################################
85+ Use with OSCAR
86+ #################################################################################################
87+ It's very easy to use this with OSCAR. On the Welcome tab, simply click on the CPAP importer icon (looks like an SD card) and navigate to the folder specified in the data location configuration. It will likely save that location and use it going forward.
0 commit comments