Arduino Uno Tournament

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Is an arduino Uno Chess engine tournament an interesting idea

Poll ended at Sat Aug 30, 2014 1:49 am

yes?
13
59%
no?
9
41%
not sure?
0
No votes
 
Total votes: 22

User avatar
stegemma
Posts: 859
Joined: Mon Aug 10, 2009 10:05 pm
Location: Italy
Full name: Stefano Gemma

Re: Arduino Uno Tournament

Post by stegemma »

DavidEather wrote:executable in ROM = about 32k, working memory for variables, heap, stack etc 2k.

One reason to exclude machine language is it is an impediment to programmers coming from a different platform. Although if there is enough interest such a category could be added.
I think that if one starts a competition based on a well defined uniform platform, as Arduino could be, then any programmer could choose the language who he/she best knows. Programming in assembly can gives better performance but debugging will take longer time (in my personal experience) so it is not clearly always an advantage.

32 Kb are a lot of space, for the executable of an assembly chess engine. Not the same for the work memory but here's the challenge!

I've seen the post about BlackBox vs Arduino vs anything else. They are interesting, if someone wants to choose the "best platform for something" but i think that they should move in different thread, because this one is focused on a well defined idea: a match between Arduino based chess engines.

I'd never programmed for Arduino, this another point to love this challenge!
DavidEather
Posts: 15
Joined: Fri Aug 15, 2014 3:24 am

Re: Uno vs BB Black

Post by DavidEather »

For G-d's sake, what is wrong with you?

I know who you are, but you are behaving like a child who didn't get their way. Step by step these are the problems with a tournament using the BBB (and similar).

I point out that I actually like the BBB. I evaluated it for a project that is still on-going. In the end it got piped by the PCDuino lite (not related to Arduino in any way - the name is... 'unfortunate') but only because enough of them became available at a seriously reduced price.

1 Stability
BeagleBone is 16 months old and has already had 2 or 3 revisions. (Similar story with RPi)

You have no clue as to if it will exist in 12 months or in what form it will take - maybe another upgrade? 1G of memory or a faster 1.2G core, or upgrade to a higher performance core A20 perhaps, DDR3 memory maybe?

Using BB will mean everyone will have to change to the latest and greatest hardware at the whim of TI, increasing their costs or else complain that the tournament is unfair since they were all supposed to start with the same hardware. They will have a point.

An alternative is to run the tournament on predefined hardware. But if there is an update to BBB and some people programed expecting features of the 'current' board to be there but they are not? Unfair! the current board supports XYZ, the compiler supports XYZ by default, but the tournament wants us to use a board that is no longer available. They will have a point too.

And there is no chance that anyone thinks that examining everyones flashed code looking for use of 'illegal features' is a good idea.

Now, no bullshit or hand waving, do you KNOW if it is going to be available in 12 months or 24 months?

You don't. A competition specifying hardware can't be run if that hardware design isn't stable.

If I wanted to put people in that mess I would have said a PCDuino 2 and that has TWICE! the ram as a BBB and still costs less!

BBB? no.

An Arduino Uno or the earlier versions based on ATmega 328 have been around and stable to the extent required possibly since 2005 and definitely by 2008. You can make a compatible one at home from common parts on ebay or retail electronic component suppliers.

Arduino has the necessary stability.


2 Availability
Over 300 thousand official Arduino's have been shipped plus about 400 thousand officially recognized compatibles. Add to that the number of pirate copies and 'unofficial clones'and the number must be over 1 million.

Despite being "open source" there is only one manufacturer of the BBB. If TI change the spec or switches to something else then it is game over. This is even likely as BBB exits only to sell TI's Sitara AM335x range of chips. When there is a new flavor-of-the-month BBB is gone, or at least 'upgraded' which will cause almost the same amount of trouble.

Tell me - that is true isn't it? TI don't make 'maker' boards or single board computers in preference to chips do they? They sell chips. BBB is nothing but an aid to that.

BBB? no.

If the Arduino consortium goes belly-up, there is over 100 manufactures making fully compatible products and if you don't like any of them you can make your own.

Arduino has the necessary availability.

3 Cost
First to pick a bone. In your previous posts you said you owned 2 Arduino's one of them a Mega. Yes?

In another post you said a person would have to buy a power supply and USB lead for the Arduino's, increasing their price to something more comparable with a BBB - a paraphrase but correct in meaning, yes?

How then is it you didn't know that Arduino's come with a USB lead and run perfectly from the USB 5volt power supply?

I find that curious. FWIW many Chinese clones also come with leads supplied. But further...

TI say the BBB has a recommended retail price of $55USD but Newark, their authorized distributor says $86USD. In fact I didn't find any one selling a BBB for $55 except TI. I deal with TI on occasion as do many engineers and designers, but they don't want to deal directly with the public. The low price point for the BBB is because they want to get developers using their chip. As soon as that market slows or they have a better chip to push, BBB in the form you know it is gone.

An official Arduino Uno from Newark or Italy is $27USD - less than a third of BBB. A made in USA, authorized clone is $20USD less than a quarter of a BBB. An unauthorized clone $9USD or about 10% of the BBB and a DIY can be done for less than $4USD or 5% of the cost of BBB.

Many people are going to figure they need two or more boards so we are really comparing $30USD (a combination of official clone and unofficial) compared to $172USD. $140 is a lot to some people and I want as many people as want to participate, be able to participate.

I don't care if $200 or $100 or $50 seems like a lot to you. I care what a kid who would like to try it thinks.

BBB? no.
Arduino? Cost range is acceptable.

processing power
No matter the size of the microcontroller chip or the power of the single board computer, it will not match even a fairly modest modern PC. There aren't going to be any major new tricks or programing breakthroughs made when people are figuring out what it is that they can leave out. So enabling 'new' methods is not a reason for selecting the base platform.

BBB clearly does not have adequate processing power to be the top performing platform in today's world. If performance is the issue neither BBB or any Arduino could qualify. If the base system performance was relevant the tournament would require something expensive like an eye-wateringly expensive Intel I7 or custom hardware. That is not going to happen and no one is ever going to use such a board to do analysis or serious chess training with.

So the question is not 'best performance' but rather 'adequate performance'.

BBB clearly passes. I can probably port Stockfish to it, and claim to be a genius.

Arduino Uno is a different matter. Possible and possibly interesting too. A quick check of the Internet turns up a description for a Radio Shack 1850 with an ELO of about 1440. At that level it can beat 75% of all registered chess players (80% at blitz) and way more than 90% of everyone who play chess.

The 1850 and it has 16k of ROM, 256 Bytes of RAM and runs 2 or 4 million instructions per second (I couldn't find data on clock / instruction phases 2 million is much more likely).

A Uno has twice the ROM, at least 8 times the speed and 8 times the RAM of something that could beat more than 90% of players and it is 25 years old!

To which I would add that Rybka's rapid rise to dominance was due to micro optimization of the code and evaluation function in a way not done before and that has never been applied to a microcontroller. So there is room to innovate.

A Uno will make something interesting, even if that silly 16-bit math thing applied to every byte (it doesn't) it is still more than 4 times faster than an 1850. Its not going make a Uno into a 'rabbit killing' machine and take master level players and make them also "ran's" but it is not unrealistic to expect something that will beat better than 90% of people.

Fortunately performance is adequate and not an issue.


End of story. BBB, no, and that is not a question, a RFC, or seeking advice. BBB is is not suitable. If you want it start your own tournament.


I want a tournament that is inclusive, and I mean that inexperienced programmers and people clueless on hardware should have a chance to enter and that means kids. I don't expect them to win, but I want them to be able to enter. That means cost is an issue, and learning curve is an issue. I don't want to add any more hurdles than are necessary. If you don't know 'C' then Arduino is a big step. If hardware scares you, Arduino is a big step. There is no need to make it harder for them.

On the other hand, if you are professional, how good are you? What extra can you squeeze out of what you have got. The story used to go around NASA that one programmer was watching a listing in assembly code being printed out and he spotted an error. He then fixed it, added new code in the room available and that code spotted an extra moon orbiting the satellite's target. Are you that kind of good?

A Uno can have some appeal to everyone.


Having seen your other stuff contributed to chess I am at a loss to explain your current attitude.

You have a BBB, are familiar with the IDE and a chess engine that will fit in. Regardless of other reasons, which you kept dismissing, because you wanted the BBB. You even exaggerated (at least) the relative costs to make your desired position more desirable.

You could have made a case for an ATmega - the 8k of RAM and 256K of ROM would be useful, and it is available, cheapish etc but no, you had to have a BBB. I had thought of the Mega as a possible, but thought the Uno would be more interesting to the majority, mainly on the basis of hack-ability and cost - make your own into something rather than dedicate a $50 board.

If there was enough interest than either a separate category or tournament would be possible. I also considered the Due and Pi but both lost out on stability and supply. The object was and is to make a tournament for as many people as possible, not to tailor one to you.

Frankly you have behaved selfishly.
User avatar
sje
Posts: 4675
Joined: Mon Mar 13, 2006 7:43 pm

Devilishly disingenuous

Post by sje »

If I wanted to be devilishly disingenuous and I also wanted to discourage newcomers to chess programming, then I'd tell them to get an Arduino and start coding. They would find that the platform, the IDE, and the difficulty of debugging such that an extraordinary amount of effort would be required to make a decent chess program. And if those who took the bait were neophytes, as are most attracted to the Arduino, then they wouldn't understand the futility of their efforts until many, many hours were lost.

If afterward they were to find out about the BB Black or the Pi and the relative ease of development with either, then their spirits might truly be crushed.

This is my last post in this topic.
IanO
Posts: 496
Joined: Wed Mar 08, 2006 9:45 pm
Location: Portland, OR

Re: Arduino Uno Tournament

Post by IanO »

I would love to see a uniform-platform small hardware tournament, with specs similar to those you describe.

My interest is historical: the last strong dedicated computers capture an era of chess programming frozen in amber in the early 1990s, at a point just prior to the discovery of techniques like null-move pruning, much less automated eval tuning and LMR. I would be fascinated to see the effects of modern chess programming discoveries and development on 90s era hardware (32-bit, ~32MHz, 256k programs, a few MB of RAM for endgame hash). Having such a tournament would give us new opponents we could match against the greats of yesteryear like Lang's final Mephistos and de Koning's and Schroeder's ARM beasts, to show just how far new techniques have taken us compared to raw hardware improvements.
DavidEather
Posts: 15
Joined: Fri Aug 15, 2014 3:24 am

Re: Devilishly disingenuous

Post by DavidEather »

Wonderful! Did someone tell you what "NO" means or did you work it out for yourself?

You had already been told "no" unequivocally twice and I was getting sick of saying it.
DavidEather
Posts: 15
Joined: Fri Aug 15, 2014 3:24 am

Re: Arduino Uno Tournament

Post by DavidEather »

Just heard back from one of the major possible sponsors - they described the idea as "awesome"
User avatar
stegemma
Posts: 859
Joined: Mon Aug 10, 2009 10:05 pm
Location: Italy
Full name: Stefano Gemma

Re: Arduino Uno Tournament

Post by stegemma »

DavidEather wrote:Just heard back from one of the major possible sponsors - they described the idea as "awesome"
That's great!

I agree with you about the choice of Arduino as Platform for this tourney. It seems to be sufficient to make a good program and it costs almost nothing. For those like me who have limited money resources, it is more attractive to spend less than 30USD just for fun.

How many months do you think that you need to start this tournament?
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Arduino Uno Tournament

Post by hgm »

So is this still in the pipe line?
DavidEather
Posts: 15
Joined: Fri Aug 15, 2014 3:24 am

Re: Arduino Uno Tournament

Post by DavidEather »

It's not looking like there is enough interest :cry:
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Arduino Uno Tournament

Post by hgm »

Too bad. Yet 13 people expressed interest in the poll. Isn't that enough, or are most of those voters people that want to watch the tournament, rather than participate?

It sounded like a real fun challenge to design something that would only need 2KB of RAM. Parhaps I am going to do it anyway.