Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "suncan"]
path = suncan
url = git@github.com:UBC-Solar/suncan.git
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,13 @@ Welcome to UBC Solar's telemetry aggregation, storage, and visualization system,
### SETUP Commands
**Recommended Everytime you Open Sunlink**
```bash
git pull
sudo docker compose restart
git pull
git submodule update --init --recursive
cd .\suncan
git pull
cd ..
```
The submodule update is required everytime for **Suncan** submodule changes. Do it everytime to have up to date dbc file.
**MUST Run Once in Sunlink directory**
```bash
source environment/bin/activate
Expand Down
866 changes: 0 additions & 866 deletions dbc/brightside.dbc

This file was deleted.

2 changes: 1 addition & 1 deletion docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ services:
restart: unless-stopped
command: python -u /app/parser/cellular_parser.py
environment:
- DBC_FILE=/app/dbc/brightside.dbc
- DBC_FILE=/app/suncan/dbc/cascadia.dbc
- INFLUX_URL=${INFLUX_URL}
- INFLUX_ORG=${INFLUX_ORG}
- INFLUX_BUCKET=CAN_test
Expand Down
4 changes: 2 additions & 2 deletions link_telemetry.py
Original file line number Diff line number Diff line change
Expand Up @@ -650,8 +650,8 @@ def main():
help=("allows randomization with production bucket. Please user carefully and locally "))

source_group.add_argument("--dbc", action="store",
help="Specifies the dbc file to use. For example: ./dbc/brightside.dbc"
"Default: ./dbc/brightside.dbc")
help="Specifies the dbc file to use. For example: ./suncan/dbc/cascadia.dbc"
"Default: ./suncan/dbc/cascadia.dbc")

source_group.add_argument("-f", "--frequency-hz", action="store", default=DEFAULT_RANDOM_FREQUENCY_HZ, type=int,
help=((f"Specifies the frequency (in Hz) for random message generation. \
Expand Down
4 changes: 2 additions & 2 deletions parser/cellular_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
- Logs undecodable/unknown frames to a rotating file

ENV (typical):
DBC_FILE=/app/dbc/brightside.dbc
DBC_FILE=/app/suncan/dbc/cascadia.dbc
INFLUX_URL=http://influxdb:8086
INFLUX_ORG=UBC Solar
INFLUX_BUCKET=CAN_test
Expand Down Expand Up @@ -41,7 +41,7 @@
# -----------------------------
# Config from environment
# -----------------------------
DBC_FILE = os.getenv("DBC_FILE", "/app/dbc/brightside.dbc")
DBC_FILE = os.getenv("DBC_FILE", "/app/suncan/dbc/cascadia.dbc")
INFLUX_URL = os.getenv("INFLUX_URL", "http://localhost:8086")
INFLUX_ORG = os.getenv("INFLUX_ORG", "UBC Solar")
INFLUX_BUCKET = os.getenv("INFLUX_BUCKET", "CAN_test")
Expand Down
2 changes: 1 addition & 1 deletion parser/parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def generate_exception(e: Exception, func_name: str) -> Exception:


# <----- DBC Variables (Can be changed by user arguement in Link Tel) ----->
DBC_FILE = Path("./dbc/brightside.dbc")
DBC_FILE = Path("./suncan/dbc/cascadia.dbc")
if not DBC_FILE.is_file():
print(f"Unable to find expected existing DBC file: \"{DBC_FILE.absolute()}\"")
sys.exit(1)
Expand Down
1 change: 1 addition & 0 deletions suncan
Submodule suncan added at cbc09e