navi: Migration from Nextcloud
This commit is contained in:
parent
982a5b5659
commit
40d39d65b3
20
navi/compression.cheat
Normal file
20
navi/compression.cheat
Normal file
@ -0,0 +1,20 @@
|
||||
% compression
|
||||
|
||||
# Create a tar containing files
|
||||
tar cf <name>.tar <files>
|
||||
|
||||
# Extract the files from a tar
|
||||
tar xf <tar_file>
|
||||
|
||||
# Create a tar with Gzip compression
|
||||
tar czf <name>.tar.gz <files>
|
||||
|
||||
# Compress file and appends .gz to its name
|
||||
gzip <path>
|
||||
|
||||
# Decompress compressed file
|
||||
gzip -d <gz_file>
|
||||
|
||||
$ path: ls
|
||||
$ tar_file: ls *.{tar,tar.*} 2>/dev/null
|
||||
$ gz_file: ls *.gz
|
40
navi/make.cheat
Normal file
40
navi/make.cheat
Normal file
@ -0,0 +1,40 @@
|
||||
% make-stm
|
||||
# Log
|
||||
make <product><job> FIRMWARE_VERSION=<version> FORCE_TRACE=y MULTI_JOBS=y SECRET=<secret>
|
||||
# No log
|
||||
make <product><job> FIRMWARE_VERSION=<version> MULTI_JOBS=y SECRET=<secret>
|
||||
# Variables
|
||||
$ product: echo "nlg nlg-stm32 nmr nmr-stm32" | tr " " "\n"
|
||||
$ job: echo " .clean .reflash" | tr " " "\n"
|
||||
$ secret: echo "c702ca256060d168bb4fffa2ecacb0e4 f6676952ded14a3c5bed81c756d4eebc" | tr " " "\n"
|
||||
|
||||
|
||||
% make-samr
|
||||
# Log
|
||||
make <product><job> APP_VERSION=<version> APP_USE_CHANNEL=11 FACTORY_TEST=y ENABLE_TRACE_SUPPORT=y RTT=y MULTI_JOBS=y
|
||||
# No log
|
||||
make <product><job> APP_VERSION=<version> APP_USE_CHANNEL=11 FACTORY_TEST=y MULTI_JOBS=y
|
||||
# Variables
|
||||
$ product: make -qp | awk -F":" "/^n[a-zA-Z0-9][^$#\/\t=\.]*:([^=]|$)/ { split(\$1,A,/ /); for(i in A)print A[i] }"
|
||||
$ job: echo " .clean .reflash" | tr " " "\n"
|
||||
|
||||
|
||||
% get-line-stm
|
||||
# STM
|
||||
arm-none-eabi-addr2line -e $HOME/Netatmo/embedded/magellan/apps/user/nlg-stm32/app.elf
|
||||
# Variables
|
||||
$ product: echo "nlg nlg-stm32 nmr nmr-stm32" | tr " " "\n"
|
||||
|
||||
|
||||
% get-line-samr
|
||||
# SAMR
|
||||
arm-none-eabi-addr2line -e $HOME/Netatmo/embedded/magellan/apps/user/<product>/*.elf
|
||||
# Variables
|
||||
$ product: make -qp | awk -F":" "/^n[a-zA-Z0-9][^$#\/\t=\.]*:([^=]|$)/ { split(\$1,A,/ /); for(i in A)print A[i] }"
|
||||
% parser
|
||||
|
||||
|
||||
# NLG Model parser
|
||||
flasher -dumpflashatoffset <nlg_dumped_bin> 0x460000 0x40000 && <nlg_parser> <nlg_dumped_bin>
|
||||
# Variables
|
||||
$ nlg_parser: echo "$HOME/Netatmo/embedded/magellan/apps/user/nlg-stm32/model_parser/nlg_model_parser"
|
18
navi/netatmo.cheat
Normal file
18
navi/netatmo.cheat
Normal file
@ -0,0 +1,18 @@
|
||||
% flasher
|
||||
# Set server
|
||||
flasher -setserver nv2 <server>
|
||||
$ server: echo "netcomv2.inte.netatmo.net nv2-nlg.netatmo.net nv2-nmg.netatmo.net upp.netatmo.net" | tr " " "\n"
|
||||
|
||||
|
||||
% jlink
|
||||
# JLinkExe
|
||||
JLinkExe -if SWD -speed 1000 -device <target>
|
||||
# JLinkGDBServer
|
||||
JLinkGDBServer -if SWD -device <target>
|
||||
# Variables
|
||||
$ target: echo "ATSAMR21E19A nRF52" | tr " " "\n"
|
||||
|
||||
|
||||
# Sniffer Zigbee
|
||||
<pyet>/zigbee/python_zigbee_interface.py -c <channel>
|
||||
$ pyet: echo "$HOME/Netatmo/core/python-emb-tools/python/bin"
|
18
navi/syncapi.cheat
Normal file
18
navi/syncapi.cheat
Normal file
@ -0,0 +1,18 @@
|
||||
% syncapi
|
||||
|
||||
# SyncAPI Muller
|
||||
<syncapi_path>/syncapiadmin.py --project muller -s <server> --endpoint <endpoint> -c <syncapi_path>/muller_<server>.swp --mac <gateway_mac>
|
||||
|
||||
# SyncAPI Legrand
|
||||
<syncapi_path>/syncapiadmin.py --project legrand -s <server> --endpoint <endpoint> -c <syncapi_path>/legrand_<server>.swp --mac <gateway_mac>
|
||||
|
||||
# Debug parser Legrand
|
||||
<debug_path>/debug_parser.py --project legrand -s <server> -c <syncapi_path>/legrand_<server>.swp -r -pp -g <gateway_mac>
|
||||
|
||||
# Paths
|
||||
$ syncapi_path: echo "$HOME/Netatmo/core/python-emb-tools/python/bin/syncapiadmin"
|
||||
$ debug_path: echo "$HOME/Netatmo/core/python-emb-tools/python/bin/debug"
|
||||
|
||||
# Variables
|
||||
$ server: echo "prod inte" | tr " " "\n"
|
||||
$ endpoint: echo "getstatus getconfigs setstate setconfigs getdebuginfo getoeminfo" | tr " " "\n"
|
37
navi/systemctl.cheat
Normal file
37
navi/systemctl.cheat
Normal file
@ -0,0 +1,37 @@
|
||||
% systemctl
|
||||
|
||||
# Start service
|
||||
systemctl start <service_inactive>
|
||||
|
||||
# Stop service
|
||||
systemctl stop <service_active>
|
||||
|
||||
# Enable service
|
||||
systemctl enable <service_disabled>
|
||||
|
||||
# Disable service
|
||||
systemctl disable <service_enabled>
|
||||
|
||||
# Restart service
|
||||
systemctl restart <service>
|
||||
|
||||
# Reload service
|
||||
systemctl reload <service_active>
|
||||
|
||||
# Service status
|
||||
systemctl status <service>
|
||||
|
||||
# List running services
|
||||
systemctl list-units --type=service --state=running
|
||||
|
||||
# List enabled services
|
||||
systemctl list-unit-files --type=service --state=enabled
|
||||
|
||||
# List disabled services
|
||||
systemctl list-unit-files --type=service --state=disabled
|
||||
|
||||
$ service_inactive: systemctl list-units --type=service --state=inactive | awk '{print $1}' | grep .service | sed 's/.service$//'
|
||||
$ service_active: systemctl list-units --type=service --state=active | awk '{print $1}' | grep .service | sed 's/.service$//'
|
||||
$ service_enabled: systemctl list-unit-files --type=service --state=enabled | awk '{print $1}' | grep .service | sed 's/.service$//'
|
||||
$ service_disabled: systemctl list-unit-files --type=service --state=disabled | awk '{print $1}' | grep .service | sed 's/.service$//'
|
||||
$ service: systemctl list-units --type=service --all | awk '{print $1}' | grep .service | sed 's/.service$//'
|
Loading…
x
Reference in New Issue
Block a user