Put 2018-06-27-raspbian-stretch-lite.img on the SD card
Enable ssh:
sudo systemctl enable ssh
Update and install dependencies:
sudo apt-get update
sudo apt-get install \
| <html> | |
| <head></head> | |
| <body> | |
| <section id="app"> | |
| <p>{{message}}</p> | |
| <input v-model="message"> | |
| </section> | |
| <script src="https://unpkg.com/vue"></script> | |
| <script> | |
| new Vue({ |
| package main | |
| import ( | |
| "fmt" | |
| "time" | |
| ) | |
| func main() { | |
| const layout = "2006-01-02T15:04:05" | |
| time1 := time.Now() |
| get data: | |
| http://10.0.0.5/json.htm?type=graph&sensor=counter&method=1&idx=611&range=day | |
| delete data: | |
| http://10.0.0.5/json.htm?type=command¶m=deletedatapoint&idx=611&date=2018-06-03%2019:55:00 | |
| data.result.forEach(point => delete(611, point.d)); | |
| function delete(idx, date) { | |
| sudo ln -sf /usr/share/zoneinfo/Europe/Oslo /etc/localtime # found in | |
| sudo apt-get purge ntp* | |
| sudo apt-get install chrony | |
| sudo reboot |
Put 2018-06-27-raspbian-stretch-lite.img on the SD card
Enable ssh:
sudo systemctl enable ssh
Update and install dependencies:
sudo apt-get update
sudo apt-get install \
| li { | |
| list-style-type: none | |
| background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"><circle style="fill:#A7A7A7;" cx="10" cy="10" r="5"/></svg>') | |
| background-repeat: no-repeat | |
| background-position-y: center | |
| padding-left: 2rem | |
| } |
| function centerCoordinates(coordinates) { | |
| if (coordinates.length === 0) { | |
| return coordinates; | |
| } | |
| let x, y, z; | |
| x = y = z = 0; | |
| coordinates.forEach(coordinate => { | |
| const latitude = (coordinate[0] * Math.PI) / 180; |
| Find encoding of a file: file -i *.fdf |
| { | |
| "name": "some-name", | |
| "version": "0.0.1", | |
| "dependencies": { | |
| } | |
| } |
| function get(obj, ...args) { | |
| let walker = obj; | |
| for (const arg of args) { | |
| if (walker && walker[arg]) { | |
| walker = walker[arg]; | |
| } else { | |
| return; | |
| } | |
| } | |
| return walker; |