Programming A Poker Game With GPT Help

Although ChatGPT generated a huge amount of hype around replacing white collar workers completely when it was first released to the public, the general consensus now is that it won’t outright replace anyone yet, but rather people who know how to use it as a tool will replace those who don’t. Getting started with it is not too hard, either, but you’ll of course need a project to work on to familiarize yourself with the tool. [Volos Projects] gave himself the challenge of writing a poker game using ChatGPT not as the opposing player, but as a co-designer in order to learn more about it as an assistant.

The poker game is being built on an ESP32 board with a built-in AMOLED screen. Five buttons are wired to the microcontroller to allow the player to select which cards to discard and which to keep. The bet for each hand can be raised or lowered much like the tabletop poker games often seen in bars and restaurants. To program it, though, ChatGPT was used to help design the code at each step of the way, first describing the overall goal and then building each function one-by-one like shuffling the deck, dealing the hand, and then replacing and dealing new cards.

For anyone who hasn’t yet explored using ChatGPT to help design their programming projects, this effort goes a long way to showing just how useful a tool it can be. For more complex tasks, though, it does take a little bit of knowledge on the part of the user because ChatGPT can often turn out nonsense or factually inaccurate information, but at least in a programming environment you’ll generally find out quickly when that happens. It’s not just a useful tool for writing programs, either. It can accomplish a lot of ancillary tasks related to programming as well, even if it’s not writing the code directly.

Thanks to [Peter] for the tip!

Continue reading “Programming A Poker Game With GPT Help”

Smart Reflow Oven Is Over-Engineered

reflow

[Linas] reverse engineered an AMOLED HTC 800×480 screen and interfaced it with an STM32 micro-controller, along with some other components, to make a gorgeously over engineered reflow oven.

Under the hood there is a PSoC5LP PID controller to control the 800W IR heating coil and two K-type thermocouples for sensing.

The real beauty is in the relatively small STM32 chip powering the HTC AMOLED screen. The AMOLED screen is high contrast and has a wide viewing angle, giving it a clear crisp view from all front facing viewpoints. Though pushing the limits of what the STM32F429i can do, [Linas] managed to make a very nice “home-grown” user interface, complete with user configurable settings and current temperature graphs.

The user interface looks very responsive and using some clever programming, [Linas] was able to make use of the potential of the screen to provide beautiful plots and interface widgets.

[Linas] goes into quite a bit of detail about the programming involved with rendering to the screen, so be sure to check out the video after the jump.

Continue reading “Smart Reflow Oven Is Over-Engineered”