Compare commits

..

66 Commits

Author SHA1 Message Date
c2ac1228e8 git
Some checks are pending
build rgb-board / build (push) Waiting to run
2026-02-07 18:11:14 +00:00
acf04a32fb just testing passing the cred
Some checks are pending
build rgb-board / build (push) Waiting to run
2026-02-07 17:56:16 +00:00
bab2f64cac bad ai
All checks were successful
build rgb-board / build (push) Successful in 4m43s
2025-10-31 19:54:58 +00:00
10cafdc209 fix teleporting
All checks were successful
build rgb-board / build (push) Successful in 4m47s
2025-10-31 19:48:17 +00:00
c272fa403f attempt to fix collision
All checks were successful
build rgb-board / build (push) Successful in 5m0s
2025-10-31 19:41:09 +00:00
120303c51b new config.yaml for assistants
All checks were successful
build rgb-board / build (push) Successful in 4m6s
2025-06-17 03:11:39 +00:00
70bc20e621 slowing down mario
All checks were successful
build rgb-board / build (push) Successful in 4m11s
2025-06-16 19:15:11 +00:00
5af72cd59b Update 'Dockerfile'
All checks were successful
build rgb-board / build (push) Successful in 4m11s
2025-06-15 02:18:16 +00:00
94e1650fd8 Update '.gitea/workflows/build-push.yaml' 2025-06-15 02:17:59 +00:00
8501fffd8a Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 5m9s
2025-06-15 02:12:21 +00:00
78640e8833 Update '.gitea/workflows/build-push.yaml' 2025-06-15 02:12:04 +00:00
3ae0f38f40 Delete 'values.yaml'
Some checks failed
build rgb-board / build (push) Has been cancelled
2025-06-15 01:50:49 +00:00
4547f86403 Add 'values.yaml'
Some checks are pending
build rgb-board / build (push) Has started running
2025-06-15 01:50:33 +00:00
9f363b7633 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m3s
2025-06-14 02:28:32 +00:00
5bc68ca194 Update '.gitea/workflows/build-push.yaml' 2025-06-14 02:28:16 +00:00
5ed9cae197 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m5s
2025-06-13 23:52:08 +00:00
721e8fdd66 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m8s
2025-06-13 22:58:11 +00:00
44a40527b1 Update '.gitea/workflows/build-push.yaml' 2025-06-13 22:57:56 +00:00
9707f4df15 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m5s
2025-06-13 22:49:28 +00:00
ef82ee7317 Update '.gitea/workflows/build-push.yaml' 2025-06-13 22:49:12 +00:00
f7f25c598d Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m21s
2025-06-13 22:34:03 +00:00
22a6efc95b Update '.gitea/workflows/build-push.yaml' 2025-06-13 22:33:49 +00:00
d3f10482bb Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m3s
2025-06-13 22:14:29 +00:00
8637558f45 Update '.gitea/workflows/build-push.yaml' 2025-06-13 22:14:16 +00:00
9f6ca33133 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m4s
2025-06-13 22:02:12 +00:00
23b8247ca5 Update '.gitea/workflows/build-push.yaml' 2025-06-13 22:01:59 +00:00
9c95b907bf Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m6s
2025-06-13 21:56:53 +00:00
b62443f94f Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:56:40 +00:00
ab98eeca27 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m21s
2025-06-13 21:50:12 +00:00
99f068ab74 Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:49:59 +00:00
0587741a35 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m0s
2025-06-13 21:40:12 +00:00
a191109daf Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:39:51 +00:00
fb3c12fe01 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m1s
2025-06-13 21:35:05 +00:00
211d6e4dbd Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:34:50 +00:00
c6e7246c95 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4m31s
2025-06-13 21:25:42 +00:00
d222538aa4 Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:16:16 +00:00
6d88307ae1 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 4s
2025-06-13 21:14:11 +00:00
6ef49e7a50 Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:13:58 +00:00
8431cc4221 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 9s
2025-06-13 21:11:00 +00:00
867f41a2f5 Update '.gitea/workflows/build-push.yaml' 2025-06-13 21:10:40 +00:00
ba273f8cd6 Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 3m58s
2025-06-13 20:53:12 +00:00
3c454c5d35 Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:52:36 +00:00
3f5df73cfc Update 'Dockerfile' 2025-06-13 20:50:41 +00:00
8ed00c76d3 Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:50:00 +00:00
007e37e3ed Update 'Dockerfile'
Some checks failed
build rgb-board / build (push) Failing after 11s
2025-06-13 20:48:23 +00:00
5f08c54034 Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:48:04 +00:00
eae79a03e9 Update 'Dockerfile' 2025-06-13 20:47:01 +00:00
48fbf44507 Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:46:48 +00:00
8062302325 Update 'Dockerfile'
All checks were successful
build rgb-board / build (push) Successful in 4m0s
2025-06-13 20:42:33 +00:00
417cbb64bc Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:41:50 +00:00
4ab8667bd8 Update 'Dockerfile' 2025-06-13 20:41:22 +00:00
b72555ea74 Update '.gitea/workflows/build-push.yaml' 2025-06-13 20:37:47 +00:00
Nathan Wagner
1257457605 forcing a build 2025-06-12 20:14:27 +00:00
Nathan Wagner
7b6a6a0b98 sizing and job 2025-06-12 19:34:45 +00:00
Nathan Wagner
23736512a8 wider maybe
All checks were successful
build rgb-board / build (push) Successful in 4m3s
2025-06-12 19:04:37 +00:00
Nathan Wagner
e33a88106c deflect on edge hit
All checks were successful
build rgb-board / build (push) Successful in 3m59s
2025-06-12 18:40:45 +00:00
Nathan Wagner
e4a47f3b76 checking
All checks were successful
build rgb-board / build (push) Successful in 4m2s
2025-06-12 17:57:11 +00:00
Nathan Wagner
8b37ba450e trying
All checks were successful
build rgb-board / build (push) Successful in 3m59s
2025-06-12 17:22:27 +00:00
Nathan Wagner
00b7060912 back to smaller elpis
All checks were successful
build rgb-board / build (push) Successful in 4m3s
2025-06-12 14:57:30 +00:00
Nathan Wagner
f14a5b0db0 wider!
All checks were successful
build rgb-board / build (push) Successful in 4m0s
2025-06-12 14:50:32 +00:00
Nathan Wagner
9d0e2ab46e increasing horizontal elipse radius
All checks were successful
build rgb-board / build (push) Successful in 4m0s
2025-06-12 14:33:01 +00:00
Nathan Wagner
ded945e7b9 shallower ellipses
All checks were successful
build rgb-board / build (push) Successful in 3m58s
2025-06-12 14:11:44 +00:00
Nathan Wagner
6d1cd08949 pushing board change
All checks were successful
build rgb-board / build (push) Successful in 4m1s
2025-06-12 13:46:42 +00:00
Nathan Wagner
2f23271bf1 give this another shot
All checks were successful
build rgb-board / build (push) Successful in 4m5s
2025-06-12 13:34:31 +00:00
Nathan Wagner
794f8ce0d5 goofy
All checks were successful
build rgb-board / build (push) Successful in 4m1s
2025-06-10 20:26:59 +00:00
Nathan Wagner
31f3ecddd1 fixing types
Some checks failed
build rgb-board / build (push) Failing after 3m44s
2025-06-10 20:09:39 +00:00
8 changed files with 123 additions and 93 deletions

View File

@@ -1,27 +1,11 @@
name: Local Assistant
name: Wagner Home Assistant
version: 1.0.0
schema: v1
models:
- name: qwen2.5
provider: ollama
model: qwen2.5:14b
apiBase: http://192.168.0.53
roles:
- chat
- edit
- apply
- agent
- name: qwen3
provider: ollama
model: qwen3:14b
apiBase: http://192.168.0.53
roles:
- chat
- edit
- apply
- agent
models:
- name: Autodetect
provider: ollama
model: AUTODETECT
apiBase: http://192.168.0.53
context:
- provider: code
- provider: docs

View File

@@ -3,10 +3,11 @@
# [Choice] Go version (use -bullseye variants on local arm64/Apple Silicon): 1, 1.18, 1.17, 1-bullseye, 1.18-bullseye, 1.17-bullseye, 1-buster, 1.18-buster, 1.17-buster
ARG VARIANT="1.18-bullseye"
FROM mcr.microsoft.com/vscode/devcontainers/go:${VARIANT}
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo gpg --dearmor -o /usr/share/keyrings/yarn-keyring.gpg
RUN echo "deb [signed-by=/usr/share/keyrings/yarn-keyring.gpg] https://dl.yarnpkg.com/debian stable main" | sudo tee /etc/apt/sources.list.d/yarn.list > /dev/null
# [Choice] Node.js version: none, lts/*, 16, 14, 12, 10
ARG NODE_VERSION="none"
RUN if [ "${NODE_VERSION}" != "none" ]; then su vscode -c "umask 0002 && . /usr/local/share/nvm/nvm.sh && nvm install ${NODE_VERSION} 2>&1"; fi
#RUN if [ "${NODE_VERSION}" != "none" ]; then su vscode -c "umask 0002 && . /usr/local/share/nvm/nvm.sh && nvm install ${NODE_VERSION} 2>&1"; fi
# [Optional] Uncomment this section to install additional OS packages.
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \

View File

@@ -28,8 +28,7 @@
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"golang.Go",
"Continue.continue"
"golang.Go"
]
}
},
@@ -43,9 +42,7 @@
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "vscode",
"features": {
"docker-in-docker": "latest",
"kubectl-helm-minikube": "latest",
"git": "latest",
// "docker-in-docker": "latest",
"ghcr.io/devcontainers/features/docker-in-docker:2": {}
}
}

View File

@@ -1,37 +0,0 @@
name: build only rgb-board
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
on:
push:
branches:
- "animate-separate"
paths-ignore:
- ".gitea/workflows/**"
jobs:
build:
runs-on: ubuntu-latest
container:
image: registry.local/catthehacker-home:act-latest
volumes:
- /var/run/user/1000/docker.sock:/var/run/docker.sock
steps:
- uses: actions/checkout@v3
- name: short-sha
id: short-sha
run: echo "short-sha=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
driver-opts: |
image=registry.local/buildkit-wagnerca:stable-3-rootless
seccomp=unconfined
apparmor=unconfined
systempaths=unconfined
privileged=false
- run: docker buildx ls
- name: push rgbboard
uses: docker/build-push-action@master
with:
push: false
tags: registry.local/rgbboard:${{ steps.short-sha.outputs.short-sha }}
platforms: linux/arm64,linux/amd64

View File

@@ -6,7 +6,7 @@ on:
- main
paths-ignore:
- ".gitea/workflows/**"
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
@@ -29,9 +29,35 @@ jobs:
systempaths=unconfined
privileged=false
- run: docker buildx ls
- name: push rgbboard
- name: build push rgbboard
uses: docker/build-push-action@master
#id: build_push_rgbboard
with:
push: true
tags: registry.local/rgbboard:${{ steps.short-sha.outputs.short-sha }}
platforms: linux/arm64
platforms: linux/arm64
- name: Checkout repository
uses: actions/checkout@v4
with:
repository: wagshome/rgbboard
token: ${{ secrets.runner_deploy }}
path: rgbboard
- name: Set up Git
run: |
git config --global user.name "Gitea Actions"
git config --global user.email "actions@nope.com"
- name: Install yq
uses: https://github.com/chrisdickinson/setup-yq@v1.0.0
with:
yq-version: v4.45.4
- name: Update values.yaml
run: |
yq -i '.image.tag = env(SHORT_SHA)' rgbboard/rgbboard/values.yaml
env:
SHORT_SHA: ${{ steps.short-sha.outputs.short-sha }}
- name: Commit and Push changes
run: |
cd rgbboard
git add .
git commit -m "Update image to ${{ steps.short_sha.outputs.short_sha }}"
git push

View File

@@ -11,4 +11,3 @@ FROM scratch
COPY --from=builder /usr/src/app/rgb/rgb /usr/src/app/work/
COPY --from=builder /usr/src/app/rgb/mari* /usr/src/app/work/
WORKDIR /usr/src/app/work

View File

@@ -56,38 +56,96 @@ func (a *Animation) animateMario() {
}
}
// what mario does every frame
func (a *Animation) updateMarioPosition() {
// Ellipse parameters (centered on canvas)
centerX := a.ctx.Width() / 2
centerY := a.ctx.Height() / 2
// Calculate new position using parametric ellipse equations
// Determine sprite size (use current updown image if available)
var sprite image.Image
if img, ok := a.mario.images[a.mario.updown]; ok && img != nil {
sprite = img
} else {
for _, im := range a.mario.images {
sprite = im
break
}
}
// default half sizes if sprite missing
halfW, halfH := 8, 8
if sprite != nil {
halfW = sprite.Bounds().Dx() / 2
halfH = sprite.Bounds().Dy() / 2
}
// allowable center range so the sprite stays fully on the panel
minCenterX := halfW
maxCenterX := a.ctx.Width() - 1 - halfW
minCenterY := halfH
maxCenterY := a.ctx.Height() - 1 - halfH
// If the sprite is larger than the panel in a dimension, collapse
// the allowed center range to the panel center so we don't get
// immediate collisions every frame which makes Mario flash.
if maxCenterX < minCenterX {
minCenterX = centerX
maxCenterX = centerX
}
if maxCenterY < minCenterY {
minCenterY = centerY
maxCenterY = centerY
}
// advance angle for this frame
delta := 0.05
t := a.mario.angle
marioX := centerX + a.mario.a*math.Cos(t)
marioY := centerY + a.mario.b*math.Sin(t)
// Update angle to move along the ellipse
a.mario.angle += 0.1 // Adjust speed as needed
if a.mario.angle >= 2*math.Pi {
a.mario.angle -= 2 * math.Pi
tNext := t + delta
if tNext >= 2*math.Pi {
tNext -= 2 * math.Pi
}
// Determine horizontal direction (left/right) for image flipping
if math.Sin(t) > 0 {
a.mario.dir.X = -1 // Moving left
} else {
a.mario.dir.X = 1 // Moving right
// compute next candidate center from the next parametric position
marioX := int(math.Round(a.mario.a*math.Cos(tNext))) + centerX
marioY := int(math.Round(a.mario.b*math.Sin(tNext))) + centerY
// clamp into allowed center ranges so sprite stays fully on panel
if marioX < minCenterX {
marioX = minCenterX
}
if marioX > maxCenterX {
marioX = maxCenterX
}
if marioY < minCenterY {
marioY = minCenterY
}
if marioY > maxCenterY {
marioY = maxCenterY
}
// Determine vertical direction (up/down) for image selection
if math.Cos(t) > 0 {
a.mario.updown = "marioUp" // Moving downward
} else {
a.mario.updown = "marioDown" // Moving upward
}
// Update Mario's position
// commit position and advance angle
a.mario.position.X = marioX
a.mario.position.Y = marioY
a.mario.angle = tNext
// Direction logic (based on the motion between t and tNext)
// approximate direction by comparing positions (preferable to trig sign when clamped)
prevX := int(math.Round(a.mario.a*math.Cos(t))) + centerX
if prevX == marioX {
// if we didn't move horizontally, keep previous direction
// (this prevents flicker when clamped)
} else if marioX < prevX {
a.mario.dir.X = -1
} else {
a.mario.dir.X = 1
}
// up/down based on vertical movement
prevY := int(math.Round(a.mario.b*math.Sin(t))) + centerY
if prevY == marioY {
// keep previous up/down state
} else if marioY < prevY {
a.mario.updown = "marioUp"
} else {
a.mario.updown = "marioDown"
}
}

View File

@@ -40,6 +40,8 @@ func animate(sz image.Point, mqMessages chan mqtt.Message) *Animation {
images: initialMap(),
updown: "marioUp",
dir: image.Point{1, 1},
a: 62,
b: 31,
},
}
}