-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #24 from UCSD-E4E/cellular
Cellular and Data storage
- Loading branch information
Showing
57 changed files
with
3,730 additions
and
333 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,66 +1,90 @@ | ||
' Green for modules that are complete | ||
' Yellow for modules that are WIP | ||
' Red for modules that are not implemented | ||
@startuml Service Diagram | ||
top to bottom direction | ||
|
||
skinparam nodesep 50 | ||
skinparam ranksep 150 | ||
|
||
package "Device OS" { | ||
[Cellular] as cellular | ||
[I2C] as i2c | ||
[Serial] as serial | ||
[Filesystem] as fs | ||
[SPI] as spi | ||
[NVRAM] as nvram | ||
[Cellular] as cellular #Yellow | ||
[I2C] as i2c #Green | ||
[Serial] as serial #Green | ||
[Filesystem] as fs #Green | ||
[SPI] as spi #Green | ||
[GPIO] as gpio #Green | ||
[EEPROM] as eeprom #Green | ||
} | ||
|
||
|
||
package "Application" { | ||
[CLI] as cli | ||
[Ride] as ride | ||
[Charge Task] as charge_task | ||
[Sleep Task] as sleep_task | ||
[Location Service] as loc_service | ||
[CLI] as cli #Green | ||
[Ride] as ride #Red | ||
[Charge Task] as charge_task #Green | ||
[Sleep Task] as sleep_task #Green | ||
[Data Upload] as upload #Red | ||
} | ||
|
||
package "Board Support Package" { | ||
[Temp Sensor] as temp_sensor | ||
[Water Sensor] as water_sensor | ||
[GPS] as gps | ||
[LED] as led | ||
[ICM] as icm | ||
[Temp Sensor] as temp_sensor #Green | ||
[Water Sensor] as water_sensor #Green | ||
[Location Service] as loc_service #Green | ||
[GPS] as gps #Green | ||
[LED] as led #Green | ||
[ICM] as icm #Green | ||
} | ||
[ConIO] as conio | ||
[Recorder] as recorder | ||
[FLOG] as flog | ||
|
||
ride --> temp_sensor | ||
ride --> gps | ||
ride --> icm | ||
package "Application Support Package" { | ||
[ConIO] as conio #Green | ||
[Recorder] as recorder #Green | ||
[FLOG] as flog #Green | ||
[NVRAM] as nvram #Green | ||
} | ||
|
||
ride <-- temp_sensor | ||
ride <-- gps | ||
ride <-- icm | ||
ride --> recorder | ||
ride --> flog | ||
ride --> water_sensor | ||
loc_service --> gps | ||
' ride -r-> flog | ||
ride <-- water_sensor | ||
loc_service -r-> gps | ||
charge_task --> led | ||
charge_task --> flog | ||
' charge_task -r-> flog | ||
sleep_task --> led | ||
sleep_task --> nvram | ||
sleep_task --> flog | ||
' sleep_task -r-> flog | ||
|
||
cli --> gps | ||
cli --> temp_sensor | ||
cli --> conio | ||
cli --> flog | ||
cli --> icm | ||
cli --> nvram | ||
cli --> water_sensor | ||
cli <-- gps | ||
cli <-- temp_sensor | ||
cli <--> conio | ||
' cli -r-> flog | ||
cli <-- icm | ||
cli <--> nvram | ||
cli <-- water_sensor | ||
|
||
gps --> spi | ||
icm --> i2c | ||
water_sensor --> i2c | ||
temp_sensor --> i2c | ||
conio --> serial | ||
recorder --> fs | ||
recorder --> cellular | ||
recorder --> nvram | ||
recorder --> flog | ||
conio --> flog | ||
gps --> flog | ||
icm --> flog | ||
water_sensor --> flog | ||
temp_sensor --> flog | ||
recorder <--> fs | ||
|
||
water_sensor --> gpio | ||
led --> gpio | ||
ride --> led | ||
nvram --> eeprom | ||
eeprom -> fs | ||
upload <-- recorder | ||
upload --> cellular | ||
upload <-- water_sensor | ||
upload --> led | ||
charge_task --> gpio | ||
upload --> gpio | ||
sleep_task <-- water_sensor | ||
' recorder -u-> flog | ||
' conio -u-> flog | ||
' gps -u-> flog | ||
' icm -u-> flog | ||
' water_sensor -u-> flog | ||
' temp_sensor -u-> flog | ||
@enduml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,75 +1,83 @@ | ||
@startuml Firmware Flowchart | ||
hide empty description | ||
|
||
Sleep: D1 OFF | ||
Sleep: DS1 Charging Status | ||
Sleep: DS2 Water Detect Status | ||
Sleep: Cell Modem OFF | ||
|
||
Connect: D1 Solid Blue | ||
Connect: DS1 Charging Status | ||
Connect: DS2 Water Detect Status | ||
Connect: Cell Modem ON | ||
state DataUpload { | ||
Connect: D1 Solid Blue | ||
Connect: DS1 Charging Status | ||
Connect: DS2 Water Detect Status | ||
Connect: Cell Modem ON | ||
|
||
Transmit: D1 Blink Blue | ||
Transmit: DS1 Charging Status | ||
Transmit: DS2 Water Detect Status | ||
Transmit: Cell Modem ON | ||
} | ||
|
||
state Ride { | ||
state "Deployed/No GPS" as deployed_nogps | ||
deployed_nogps: D1 Solid White | ||
deployed_nogps: DS1 Charging Status | ||
deployed_nogps: DS2 Water Detect Status | ||
deployed_nogps: Cell Modem OFF | ||
|
||
state "Charged Complete" as charge_complete | ||
charge_complete: D1 OFF | ||
charge_complete: DS1 Solid Green | ||
charge_complete: DS2 Water Detect Status | ||
charge_complete: Cell Modem OFF | ||
state "Deployed/GPS" as deployed_gps | ||
deployed_gps: D1 Blink White | ||
deployed_gps: DS1 Charging Status | ||
deployed_gps: DS2 Water Detect Status | ||
deployed_gps: Cell Modem OFF | ||
|
||
state "Deployed/No GPS" as deployed_nogps | ||
deployed_nogps: D1 Solid White | ||
deployed_nogps: DS1 Charging Status | ||
deployed_nogps: DS2 Water Detect Status | ||
deployed_nogps: Cell Modem OFF | ||
} | ||
|
||
Transmit: D1 Blink Blue | ||
Transmit: DS1 Charging Status | ||
Transmit: DS2 Water Detect Status | ||
Transmit: Cell Modem ON | ||
|
||
Charging: D1 OFF | ||
Charging: DS1 Blink Green | ||
Charging: DS2 Water Detect Status | ||
Charging: Cell Modem OFF | ||
state ChargeTask { | ||
state "Charged Complete" as charge_complete | ||
charge_complete: D1 OFF | ||
charge_complete: DS1 Solid Green | ||
charge_complete: DS2 Water Detect Status | ||
charge_complete: Cell Modem OFF | ||
|
||
Charging: D1 OFF | ||
Charging: DS1 Blink Green | ||
Charging: DS2 Water Detect Status | ||
Charging: Cell Modem OFF | ||
} | ||
|
||
state "CLI" as CLI | ||
CLI: D1 Solid Yellow | ||
CLI: DS1 Charging Status | ||
CLI: DS2 Water Detect Status | ||
CLI: Cell Modem OFF | ||
|
||
state "Deployed/GPS" as deployed_gps | ||
deployed_gps: D1 Blink White | ||
deployed_gps: DS1 Charging Status | ||
deployed_gps: DS2 Water Detect Status | ||
deployed_gps: Cell Modem OFF | ||
|
||
state choice1 <<choice>> | ||
state choice2 <<choice>> | ||
[*] --> Setup | ||
Setup --> Sleep | ||
Sleep --> choice1 : USB Connect | ||
Sleep --> deployed_nogps : Water Detected | ||
choice1 --> Connect : Data to transmit: Yes | ||
choice1 --> Charging : Data to transmit: No | ||
deployed_nogps --> Sleep : Low Battery | ||
deployed_nogps --> choice2 : Out of water | ||
deployed_nogps --> deployed_gps : GPS Lock | ||
Connect --> Transmit : Connected | ||
Connect --> Sleep : Low Battery or No Connection | ||
Charging --> charge_complete : Charge Complete | ||
Charging --> Sleep : USB Disconnect | ||
Charging --> CLI : "#CLI" | ||
choice2 --> Connect : Data to transmit: Yes | ||
choice2 --> Sleep : Data to transmit: No | ||
deployed_gps --> choice2 : Out of water | ||
deployed_gps --> Sleep : Low Battery | ||
deployed_gps --> deployed_nogps : Lost GPS Lock | ||
charge_complete --> Sleep : USB Disconnect or ~40 days elapsed | ||
CLI --> Connect : Upload Data Command | ||
CLI --> deployed_nogps : Deploy Command | ||
CLI --> Sleep : Sleep Command or CLI timeout | ||
Transmit --> deployed_nogps : Water Detected | ||
Transmit --> Sleep : Transmit Complete or Low Battery | ||
Transmit --> Connect : Lost Connection | ||
[*] -d-> Setup | ||
Setup -d-> Sleep | ||
Sleep -d-> Ride : Water Detected | ||
deployed_nogps -u-> deployed_gps : GPS Lock | ||
deployed_gps -d-> deployed_nogps : Lost GPS Lock | ||
Ride -d-> choice2 : Out of water | ||
choice2 -d-> Connect : Data to transmit | ||
Connect -u-> Transmit : Connected | ||
Transmit -u-> Sleep : Transmit Complete | ||
|
||
Sleep -l-> choice1 : USB Connect | ||
choice1 -d-> Connect : Data to transmit | ||
choice1 -l-> ChargeTask : No data to transmit | ||
Charging -d-> charge_complete : Charge Complete | ||
ChargeTask --r--> CLI : "#CLI" | ||
CLI -d--> Connect : Upload Data Command | ||
CLI -d--> Ride : Deploy Command | ||
CLI -l--> Sleep : Sleep Command/CLI timeout | ||
choice2 -u-> Sleep : No data to transmit | ||
DataUpload -u-> Sleep : Low Battery/No Connection | ||
Ride -l-> Sleep : Low Battery | ||
ChargeTask -r-> Sleep : USB Disconnect/~40 days elapsed | ||
DataUpload -r-> Ride : Water Detected | ||
Transmit -d-> Connect : Lost Connection | ||
|
||
@enduml |
Oops, something went wrong.