#Balatro the electronic board game
1 messages · Page 1 of 1 (latest)
Here is some of the progress I have made.
The game uses ntag215 nfc stickers to read and write to cards.
fire
I will be posting updates and everything on this as things go on. And feel free to ping me and ask questions. It only helps with the process
NFC tag playing card architecture
Keen to see how this progresses
What's the lil purple dev board in the video?
It’s an i2c multiplexer. Lets me used all three of those screens at the same time.
They are identical parts so they have the same address to communicate to them. So you have to have a chip to break them into separate lines.
It’s like trying to talk to 3 different people named Dave. You have to start calling them by their last names
Or else all three will thing you are talking to them
You mentioned a moving dolly here #💻・modding-dev message, have you got that assembly to a functional point already? I've found a lot of frustration trying to do fine motor control on STM boards, is the ESP32 friendly with that sort of thing?
I am using a stepper motor and a stepper motor controller that can do quarter stepping. So I can get extremely fine motor control out of it.
That part is actually over built rn
I need to find a cheaper stepper motor for the project.
The one I am using was ripped out of an old 3d printer
I was going to say "no such thing as over built", but yes perhaps using a 2A motor to move a plastic tray is somewhat overkill
Yeah, i am using a hand made wooden cart rn, but I am working on a 3d printable trolly
3d printer will be much lighter and much faster
I need to refine down how many ball bearings I have to use for it though
I have also been trying to track down a decent supplier for nfc tags from china
The small amount I have I had to play close to .50$ a pice for them
60 for 30$ is crazy
The price I have found for nfc tags from china is .06$ a piece
Even Paying for 20 dollar shipping it’s still significantly cheaper
Chinese goods secured
The concept behind NFC tags is so far into the realm of technology-as-magic. It's mind-blowing that it's even possible at all, let alone possible for 5c per chip
I got tipped well at work yesterday. So I can afford things
Yeah bulk pricing is great.
Minimum order of 1000 pieces
Free shipping from china too
Wirelessly powering a chip with a magnetic field from a phone 20cm away, and then communicating to and from it at a speed 10x higher than my dial-up internet of 20 years ago? Wizardry and black magic
It really is black magic tbh
The tags i am using can store 577 bytes of data
The ones I bought store 144 bytes
So I have to reformat my read program to adjust for it
That still sounds like a lot of headroom compared to what you'd need for this, right? #1342904656124182618 message
So much more room for... Activities?
No clue. I could make the whole stake markers really easily
Show what stakes you have won with a card
Not too much to do with the extra room
It's not anywhere near enough to store it all as plaintext, but you won't have to worry about future additions if LocalThunk wants to add more suits / editions / seals / jokers
I was being efficient to make read/writes fast and to keep processing as low as possible
Yeah that will need to be stored internally.
Plain text is not easy
It is just cheaper for me to use a spi based flash module to store the joker descriptions
What's the Seed byte here for? Not the game seed, right?
It is. It’s meant make sure that cards changed in the last game does not stay changed for the next game
If the seed does not match the machine defaults to the card’s base version
And then it rewrites the seed to be the correct one
This reduces the amount of resetting you have to do between games
Ah, ok. Not identical to Balatros 8-character seed, just your own rng seed
You've got enough overhead that you could use 42 bits and aim for parity with Balatros rand implementation, but it's almost certainly not worth the effort
Yeah, that would be hell to do in the C programming language
That’s what I am coding in
I might expand it to 16 bits for the seed though
Just because I don’t want to risk 1/256 for the game not to reset right
255 different game possibilities is very small. Even 65535 might be overly limited
Just forcing your game controller to reroll if the seed is the same would fix that possibility, but i understand the need for encoding the seed onto each card now
True, that would reduce it. I will have to see if connecting rng to a seed would be worth doing
Ah, although if you use a card that hasn't been used in a few games that won't be true. Hmm
How about a timestamp?
No risk of collisions that way
It would be unreliable as a time stamp just no easy way to do it with the cheap processor I am using
I think just a larger seed will work
A simple counter would also do the same job. Increment by 1 for each game, overflow back to 0. Even 16 bits gives you 65000 games with 0% chance of a collision, which is more than anyone would ever play.
The nature of probability is that relying on chance will mean it would fail eventually for somebody, and it would be a very confusing problem to stumble onto
Say someone played 10 games, and used a different subset of the ~300 cards each time. Now you have dozens of cards with a different seed, and your chance of collisions increases with each new game
Yeah, I could do that if I did not want to tie rn to a seed
Well the data is reset after every game so it’s always 1/the max
I just mean for the validation bytes. You might as well store the RNG seed separately too, with so much headroom
Would the data be reset on every single card there player used that game? How would you do that?
(Original card) (seed) (current card)
If seed does not match the seed is writen to be the new one
And the current card is erased and a copy of the original card is written to it
But in the case of a collision where the seed of a previous game is the same as the current game, the controller won't know to reset the card state
Yup
That’s why I would need a bigger seed
Or a double check to make sure no repeats happen
And the simplest way to make sure no repeats happen is to just increase the number by 1 each game
bleep bloop lo-fi balatro
Like I could do Basic mp3 stuff but those transitions between songs in the shop will be really hard
Today's effort is going towards hand logic
Ok I have it recognizing the groups of a kind now.
Including 2 pair and full house
Taking a small break on this project to figure out some stuff with college.
Turns out my campus is shutting down in 2 years
Got to love it
I am a freshman with 3 years needed
So I need to get a plan around to speedrun college
christ what is this.
you poor soul
So we chilling
Finally got my screen in
Ignore the gaping hole in my phone
I was not the one to do it
how're you gonna make the jokers work? with a scanner?
Yup nfc stickers
On the back of printed jokers
The machine does all of the math for you
Very easily. The entire thing is written in C
I have yet to add a joker system into the scoring yet. But when I do it should just be a matter of defining a few things
Like scoring priority and other things
Telling the machine where to put the effect in the calculation
Update, basic UI
I’ve just kinda been lurking and stalking here but this is actually such a cool project lol
good shit
Wait what the fuck first of all hello and second of all this insane
I enjoy giving myself crazy challenges. 
I gen thought this was like ssome silly lil project till I looked at the top lmao its got so many wires
I am trying to build it on a budget too. Hoping to make a video on the project and maybe work with the right people to make it a product.
lmao
Making the best use of my freshman year of college. Got a lot of freetime.
this looks great
Good to see that the project is picking up traction
I need to work more on the ui. The little chip I am using is made by hand using draw functions. I think I can make it better by using bitmaps
Get it closer to the in game sprites.
The sprite has perspective.
I can't do warped circles with the lib I am doing so bitmaps might be my only option
I would love to figure out the shifting green effect for the backround color aswell
one set le me send a photo of the updated ui color scheme
I just love the project (and because I know you from a different discor server lmao)
Yeah maxc0rd be wild
truly
3 years of my life I will never get back spent on maxc0rd
Upside, I was able to convince a mod to create a yugioh thread that survived the great thread purge
Here is a little something I have been working on
A super basic prototype for the moving nfc read/write modules
Gives you the ability to play any amount of jokers without needing more then 2 nfc readers
Yeah college student budget. That fram is built from an old 3d printer my Highschool gave to me.
real
Here is a break down of the project so far:
(1): Displays Mult and chips while scoring
(2): Buttons for Play, Discard, Inspect and Skip.
(3): Main display, Give general info about everything from the shop to what every card does.
(4): Displays the Ante
(5): Displays money
(6): LEDs are lit for how many discards are left.
(7): LEDs are lit for how many hands are left.
(8): NFC reader/writer that is on a moving part underneath the play area. reads all cards in the Joker card row.
(9): NFC reader/writer that reads played playing cards in the Playing card row.
(10): Displays scoring information, like joker activations, how much a card is worth scoring wise and many others. The LEDs display if the effect is a Mult, Chip or Money related effect.
(11): NFC reader near deck, reads cards drawn to allow for the existance of in hand card effects.
Hopefully this puts the project in a bit of a clearer scope
(Wish I could pin the message but no perms)
I haven’t even messed with audio yet
@wanton ice Sorry for the ping. I was told that you where the one to ping to get some help pinning a message. Would you be able to pin this message for me?
I do a little something something. Hoping to reach out to thunk once I have a fully functioning prototype to see if he would be interested in making it an actual product.
Working on some proof boards
I also sat down to work through the logistics of audio output
I need to sit down and watch a video on the i2s protocol used by the board I am working with
I also have a hell of a lot of optimization to do with the code as well
I also kinda want to rewrite what I have to use freertos. Because multithreading
I needed more memory… so I figured something out
I feel like I committed a crime
you did, expect the jimbo police to show up at your door by tomorrow
Less cursed adapter has been made
By the power of the counter force I have stopped the Jimbo police
Yippie
Got parts for audio coming in the mail soon.
Without audio it will just sound like a 3d printer
nice
does this constitute as modding balatro on a different platform 😡😡😡😡
not on my watch
smh can't people just play the real game fr
-# (this project is so cool i wanted to do hardware stuff but I'm too stupid)
ahh is this the budget option for people who cant afford the basse games
makes sense
Depending on costs of bulk products it would be cheaper than buying a console or pc. But still even at the cheapest this is going to be close to 60-80$. I am looking at getting the price down though.
The screen I am using is pricy
close to 30$ a piece
I would like to find one closer to 10$ or less per unit
I just don't know enough about the proticol used for driving lcds yet
I cna make a write-up of the costs when I make a video about it
But I can easly say that I have spent around 150$ on parts already
Because I needed nfc tags
and you could only buy them in bulk
so 60$ of my budget went to 1000 nfc tags
It’s 2:30 Am but I woke up from a dream and had a revelation on how to reduce the part count of this board
I can use 2 74n595s if I use a form if software multiplexing.
By using the first shift register to select what I am displaying and the 2nd to output the information needed for each part I can cut a 5 shift registers out of the board
This will make wiring much easier and will make the end product cheaper
I am writing this down so I don’t forget
At .75$ a piece that reduces my price by 4.50$ just by implementing that
I also think I figured out software i2c multiplexing but it that needs to be tested
If that works I might be able to reduce the price further by 1.25$
I will keep cooking more price reductions and simplifications for the project
1000 nfc stickers have arrived
holy shit lol
also out of curiosity, how are you going to deal with enhancements, editions, and seals?
mainly in terms of converting/recognizing playing cards as being non-standard, and making that clear to the player
Every card is in a sleeve. The enhancements/editions and stamps will be on clear pieces a plastic you slide in front of the card in the sleeve
There is also a clear layer to write on with a dry erase marker for rank and suit changes
Internally I have a system for everything in my nfc tag bit architecture
This
ah ok, cool
and yea I figured the game would keep track of it itself
Yeah, trying to get the player to keep track of them is the hard part
My original idea was using e-ink displays for the cards but that was too pricy and the displays are very slow to refresh
BIG UPDATE
I just got access to a pick and place machine along with everything else to do custom pcb work.
ok did some work
set up the multiplexing circuit but also included a microprocessor that I can use to take over the entire process of multiplexing everything
This was built with what I have but I could easly use a much cheaper one
or even better, just cut out the shift registers
I am in a weird trigangle here. Price, size and processing power.
If i want a low price and a low size then it takes a lot fo processing power
If I have a small size and lower processing power it is going to be more expensive.
I would say to prioritize cost without sacrificing gameplay if possible, since you want to try and turn this into a real product
I won’t be able to make much progress on this for the next few days due to being out of town.
Also I can feel a new hyper fixation on 4th dimension physics and special relativity coming on
So i am going to try to get that out of my system before getting back to the project
real
4th dimensional balatro
Balatro with multidimensional time travel is going to be great
Balatro with multidimensional time travel the electronic board game too
Alrighty, done with my trip and ready to get back to work on this
I think next up on my chopping block is the scoring system or game rng
I think I am going to lay out the scoring process and work on that.
Here is a more in depth view of the scoring system
OK so I have been working on a few things
I have been laying out a custom pcb for the project.
And I have been working on a 3d printable shell for it all to be in
I do need a tiny bit of feedback.
I am thinking of making the playing surface have a green felt layer over it.
Almost like an old card table
Something like this for the playing surface.
that would be fun
I would at least try it and see how it comes out in terms of price and practicality
because it would add a lot to the aesthetic imo
I want to print it in red, I feel like the green would be a good accent
All of the physical lettering will be in white plastic
I don’t exactly know how to mix blue into the theming
Working in the shell
I'm obsessed. That looks awesome
It’s the display, the card reader is under the board
That little thing has a little screen that tells you what is happening
Like +mult
Or chip+30
Then There are 3 leds on there to show how what kind of thing is being added
Red, Blue and yellow
ohhh, okay
It will also have a little arrow that points up and down to tell you which joker\card is doing the thing
Yup
how will stuff like death and things that change the cards be implemented?
believe he mentioned before that the game can detect changes in cards with the NFC tags, and visually there’s gonna be clear card sleeves and a marker you can use to draw on the cards to tell if they’re different
