mholub
mholub
Mmarimo
Created by mholub on 9/23/2024 in #help-support
How do I refresh marimo notebook when modified externally?
and I found solution which works for me good enough so if I put my code into separate python file (module) - it's actually being tracked - so any code modifications of that file are updated automatically so only main notebook file is not being updated
4 replies
Mmarimo
Created by mholub on 9/23/2024 in #help-support
How do I refresh marimo notebook when modified externally?
I see it's already discussed here, so I guess wip https://github.com/marimo-team/marimo/issues/1511
4 replies
Day 1 Tables and Badges
I implemented this defensive mode and assigned dedicated button to it. Better to be safe
570 replies
Day 1 Tables and Badges
ok, feels like it's actually something like from 0 to 10 does change brightness
570 replies
Day 1 Tables and Badges
yeah, same for me... I guess if I will be mugged in some dark street, I'll use the badge as defensive flashlight
570 replies
Day 1 Tables and Badges
I suspect 1, 1, 1 will be as well, so it's not really about linearity
570 replies
Day 1 Tables and Badges
but even 10, 10, 10 is full brightness for me
570 replies
Day 1 Tables and Badges
it feels it's binary - it is either 255 or 0
570 replies
Day 1 Tables and Badges
does anyone have problem that neopixels behave strangely? i.e. even with small values they are on full brightness all the time?
for (0..cart.neopixels.len) |i| {
const diff = @abs(@as(i32, @intCast(i)) - @as(i32, @intCast(pixel_pos)));
cart.neopixels[i] = switch (diff) {
0 => .{ .r = 50, .g = 50, .b = 0 },
1 => .{ .r = 40, .g = 40, .b = 0 },
2 => .{ .r = 30, .g = 30, .b = 0 },
3 => .{ .r = 20, .g = 20, .b = 0 },
else => .{ .r = 10, .g = 10, .b = 0 },
};
}
for (0..cart.neopixels.len) |i| {
const diff = @abs(@as(i32, @intCast(i)) - @as(i32, @intCast(pixel_pos)));
cart.neopixels[i] = switch (diff) {
0 => .{ .r = 50, .g = 50, .b = 0 },
1 => .{ .r = 40, .g = 40, .b = 0 },
2 => .{ .r = 30, .g = 30, .b = 0 },
3 => .{ .r = 20, .g = 20, .b = 0 },
else => .{ .r = 10, .g = 10, .b = 0 },
};
}
570 replies
Day 1 Tables and Badges
Thanks. I didn’t know this thing exists
570 replies
Day 1 Tables and Badges
No description
570 replies
Day 1 Tables and Badges
No description
570 replies
Day 1 Tables and Badges
Mine were containing zig function names but I don’t remember how they looked. I can take a look in the break. I did nothing special. Could be specific to browser? I am using chrome
570 replies
Day 1 Tables and Badges
Definitely learning point for me is to have everything in i32/f32 for now and not try to optimize stuff. I might regret this decision a little bit later but it’s much easier to write math this way and not have these overflows
570 replies
Day 1 Tables and Badges
Wasm traces but better than nothing
570 replies
Day 1 Tables and Badges
Debug console in chrome did show panics with stack traces
570 replies
Day 1 Tables and Badges
I did compile simulator in debug and catched quite a few places where I had integer underflow
570 replies
Day 1 Tables and Badges
interesting that Debug and ReleaseSmall builds work but ReleaseSafe gives strange error
install
└─ install generated to hello.uf2
└─ run elf2uf2 (hello.uf2)
└─ zig build-exe hello ReleaseSafe thumb-freestanding-eabi failure
error: error: <inline asm>:3:1: symbol 'initial_pause' is already defined
initial_pause:
install
└─ install generated to hello.uf2
└─ run elf2uf2 (hello.uf2)
└─ zig build-exe hello ReleaseSafe thumb-freestanding-eabi failure
error: error: <inline asm>:3:1: symbol 'initial_pause' is already defined
initial_pause:
570 replies
Day 1 Tables and Badges
does it mean lcd works if we pull or not yet?
570 replies
Day 1 Tables and Badges
have you tried running it on hardware already?
570 replies