Good vs. Evil

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

lenscas

Over-Achiever
Jul 31, 2013
2,015
1,801
248
52 Decided to try LLDB again. Last time I used it I was able to set breakpoints but despite those seeming to work it was unable to show the state at those points. This time that problems seems to be mostly gone. Some complicated types are a mess (but at least they show up) or don't make a lot of sense but most seem to work. Also, if you are simply stepping over your code you may suddenly find yourself staring at raw assembly. This however has a simple fix: Don't step into build in functions you dofus.
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
51 Dang, I can't use IC to measure the duty cycle of a PWM signal because the input is channel 3, and I can only slave the second timer/IC channel required to channels 1 or 2
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
52 It does, but in this case it meant input capture, a peripheral on the microcontroller being used.
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
52 It lets you easily capture timing information about an input signal, say, the time between rising edges.
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
52 In this case, there's data being sent in the pulse lengths, so getting their lengths would be quite helpful. Specifically, the available current to be provided is sent in the duty cycle of a square wave.
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
52 I can't use IC for it though, so I'm using EXTernal Interrupts to start and stop timers to get the data manually.
 

lenscas

Over-Achiever
Jul 31, 2013
2,015
1,801
248
53 I did a small thing for arena_keeper.

I made a way to compile it into "dev" mode. Which is basically the same except I can pause the game (only let draws call go through) and enter dev mode.

Right now that only lets me draw rectangles and have the game will spit out their size and location. This means that I can draw the UI elements and simply copy their location and size instead of having to make a guess, compile, check if my guess was correct and probably try again.

Some other things that I will probably implement to make this a bit easier:
Clicking on a square prints its information again
Drag mode (So I can reposition a square)
Delete mode (Click to remove a single square)
Clear all

Other stuff that I will probably add:
Slow mode: Instead of stopping every update just stop some.
Drawing other stuff than just squares
Maybe some way to fake events? That may be hard though....

Maybe planned:
Make it a separate crate, that allows you as a developer to call its run function and it automatically injects this dev mode into your game.
If I go that route I may even look if I can fake a window object, especially if it can create fake events then it may prove rather useful as a way to create automated tests
 

duckfan77

Popular Member
Mar 18, 2013
80
683
118
54 That's incredibly useful. The whole need to guess, compile, and check is part of why I don't like making UIs
 

lenscas

Over-Achiever
Jul 31, 2013
2,015
1,801
248
55 and the shop is slowly getting better :)
https://cdn.discordapp.com/attachments/536648569378045964/612758077661380651/unknown.png

unknown.png


I really need a way to turn buttons into a bit more than just text. the line will also be removed later on, that is just for me so I don't put stuff underneath it that shouldn't be there.
 

GamerwithnoGame

Over-Achiever
Jan 29, 2015
2,808
1,507
224
54. I'm exhausted. Woke up at 4:30am for no reason, didn't get back to sleep til gone 5:30, and then any sleep I had was punctuated with broken and chaotic dreams.