summaryrefslogtreecommitdiff
path: root/notes
diff options
context:
space:
mode:
Diffstat (limited to 'notes')
-rw-r--r--notes/si_building5
-rw-r--r--notes/time_calculations.txt19
-rw-r--r--notes/time_testing.c20
-rw-r--r--notes/what_i_want_time_to_look_like.txt40
4 files changed, 84 insertions, 0 deletions
diff --git a/notes/si_building b/notes/si_building
new file mode 100644
index 0000000..fc572f2
--- /dev/null
+++ b/notes/si_building
@@ -0,0 +1,5 @@
+//TODO: need to get wrap around times from one day until the next day such as this one
+
+Student Innovation Center
+Monday 7 AM - 1 AM Tuesday 7 AM - 1 AM Wednesday 7 AM - 1 AM Thursday 7 AM - 1 AM Friday 7 AM - 8 PM Saturday 9 AM - 8 PM Sunday 9 AM - 1 AM
+
diff --git a/notes/time_calculations.txt b/notes/time_calculations.txt
new file mode 100644
index 0000000..d623026
--- /dev/null
+++ b/notes/time_calculations.txt
@@ -0,0 +1,19 @@
+time is always 4 digits longs with a colon seperating hour and minutes:
+minutes are directly correlated in both times, no conversion needed (right two digits)
+remove colon from number
+add any leading 0s as necessary to fit 4 spaces: XXXX (04:43 AM -> 0443) (done in a later printf) (for now, 443)
+
+
+12 AM - 12:59 AM = just add the minutes
+
+
+1:00 AM - 12:59 PM = add the minutes and add (100 * number left of colon) (Example 3:42 AM -> (42 + (3 * 100)) => 342)
+(another example: 12:16 PM -> (16 + (12 * 100) => 1216)
+
+
+1 PM - 11:59 PM = add the minutes and add ((12 + number left of colon) * 100)
+example: 3:33 PM -> 33 + (3 + 12) * 100 => 1533
+
+
+longest string = 12:12 PM - 12:12 AM (19 characters)
+shortest string = 1 AM - 2 PM (11 characters)
diff --git a/notes/time_testing.c b/notes/time_testing.c
new file mode 100644
index 0000000..014ecca
--- /dev/null
+++ b/notes/time_testing.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <time.h>
+
+
+int main(void)
+{
+ time_t cur_time_sec;
+ struct tm* time_values;
+ char buffer[100];
+
+ time(&cur_time_sec);
+
+ time_values = localtime( &cur_time_sec);
+
+ strftime(buffer, 100, "%A, %H:%M", time_values);
+
+
+ printf("Time is: %s\n", buffer);
+ return 0;
+}
diff --git a/notes/what_i_want_time_to_look_like.txt b/notes/what_i_want_time_to_look_like.txt
new file mode 100644
index 0000000..fc71b14
--- /dev/null
+++ b/notes/what_i_want_time_to_look_like.txt
@@ -0,0 +1,40 @@
+where the first place after the letter of the day of the week is lit up if the building is open right at or before the time 0000 AND is open at least one minute past 0000, if the building opens up from 0001 - 0029 it will not show up until the second spot after the day of the week for the 0030 spot
+
+COOVER HALL
+M-------------@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@----
+T-------------@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@----
+W-------------@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@----
+R-------------@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@----
+F-------------@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@----
+s------------------------------------------------
+S------------------------------------------------
+0 1 2 3 4 5 6 7 8 9 1 2 3 4 5 6 7 8 9 24
+
+
+HOOVER HALL
+M___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+T___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+W___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+R___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+F___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+s___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+S___________@@@@@@@@@@@@@@@@@@@@@@@@@@@@@________
+0 1 2 3 4 5 6 7 8 9 1 2 3 4 5 6 7 8 9 24
+
+start = 700, end = 2200
+start = 700, end = 2200
+start = 700, end = 2200
+start = 700, end = 2200
+start = -1, end = -1
+start = 1230, end = 1800
+start = 1230, end = 1800
+
+is converted to:
+if end time is lower than start time, go to the next day and modify its string as necessary
+might be best to find the first and last places to print a @ then use a loop to print a @ in between
+
+monday: start at 7 am, go to 10PM if 10 pm (2200) is greater than 7 am (0700) (it is) then find the
+for every hour, multiply it by two example: 10PM (2200) is 44 places into the array
+so take 2200 / 100 = 22, now take that 22 and multiply it by 2 = 44
+take the 22 and multiply it by one hundred and store in another variable, this way it loses all minutes associated with it, now subtract it from the original number, if the number is greater than 0, then add 1, if it is greater than 30, add another 1
+add one for a number in the minutes column between 01 and 29 and add two for a number between 30 and 59