ACK1 Makes Getting To Know The ATtiny1616 Easy

Many readers will be familiar with Microchip’s ATtiny85, which has been a popular choice for DIY projects in the past for its low price and (for the time) small size. But those looking for a more modern and capable 8-bit chip may find the ATtiny1616-MNR of interest. It offers expanded flash storage, more GPIO, and ditches SPI programming in favor of UPDI — a protocol that can be done using nothing more than an USB-UART converter and a resistor.

The contents of the ACK1 kit
What’s in the kit if you buy it.

But here’s the catch: the new chip is only available in SMD and there are far fewer tutorials for it! That’s why [Bradán Lane] has created ACK1, a cute little AVR Coding Kit for those of us who want to play with the ATtiny1616 and a companion for his free and open-source course.

The board contains an array of 6 by 7 LEDs in a charlieplexed configuration, a large piezo buzzer, two push buttons, an on/off switch, and a CR2032 battery holder to keep it on without the need for a cable. The kit looks gorgeous in its white-on-black theme with gold plated contacts and can be had for $20 on Tindie at the time of writing.

The ATtiny1616 itself runs at up to 20 MHz and has 17 GPIO pins, 16 KiB of flash storage, 2 KiB of RAM, and 256 bytes of EEPROM for configuration — making it roughly on par with the original Arduino Uno.

The course that goes hand-in-hand with the ACK1 is all about the features of the ATtiny1616, from the basics of using the programmer to reading the buttons, using timers, driving the charlieplexed LEDs, storing data in the EEPROM and much more. Though it does not cover the basics of C, the course is free, and even licensed MIT, so that anyone can share it and improve upon it.

If you enjoy seeing beautiful microcontrollers, you’ll definitely want to see the stylish Uno Plus+.

Bringing An ADM-3A Back To Life

[David] at Usagi Electric ended up with an old Lear Siegler ADM-3A terminal in a trade a couple of years ago. But the CRT face was plagued with so-called cataracts, and the condition of the insides was unknown. The video ( below the break ) shows the restoration process, which went quite smoothly. [David] was relieved that the CRT repair in particular was easy, a fact he attributes to the Texas weather —

ADM-3A Under the Hood

The temperature was 110 F / 43 C when he set the CRT outside to bake in the sun for a few hours. Afterwards, removing the “integral implosion protection” plastic screen went better than expected. Everything cleaned up nicely and the screen reinstalled. Introduced in 1976, the main electronics board is chock full of TTL chips with nary a microprocessor in sight. Fortunately the board was substantially intact, and a single missing chip was found hidden underneath the board. [David] gets the terminal up and running in short order, and is confronted with an annoyance familiar to gray-haired programmers who grew up in this era. Most terminals had different sets of commands to control features such as cursor control and clearing parts or all of the screen. Programs often assumed a certain type of terminal. Some terminals could be configured to behave in different ways, and some programs offered the user a choice of terminals. Today your terminal emulator probably still has a few choices of which kind of terminal to emulate, VT-100 being the most common. And eventually some operating systems provided a terminal abstraction, like Unix’s termcap for example.

If you were around in the era where terminals like the ADM-3A were scattered everywhere, what was your favorite terminal and/or terminal feature? And today, do you have any favorite terminal emulator to recommend? Let us know in the comments below.

Continue reading “Bringing An ADM-3A Back To Life”

The Orb Web Desktop

[Hugo Leisink] is a programmer who contributes to Open Source projects. In their spare time, they have been developing a web-browser-based operating system called Orb. It is available for the princely sum of zero cheeseburgers and doesn’t need a high-spec machine to run smoothly. The project is built using PHP and Javascript, which allows it to run efficiently on most desktop devices. There are a number of apps included, which are again written in a combination of PHP and js, together with a few written using webasm.

A few notable examples include a C64 emulator, minesweeper, and even a js port of Wolfenstein 3D so this isn’t just a toy, but actually useful. Ok, for real use cases, there are also the usual file browsers, and document readers as well as a writing application based on CKeditor. There is a kind of Windows 3.1 look and feel simplicity to the experience which is refreshing in the modern era of complex applications with their learning curves. Orb could be very useful in an educational setting, or just for jotting your own notes as you travel. Who knows, because the possibilities are endless if you’re willing to get your hands dirty with a bit of coding.

We’ve seen a few web desktops before, here’s a collection of them we saw last year. If you want to go in the other direction and turn a webpage into a desktop app, then look no further than Gluon.

Kalman Filters Without The Math

If you program using values that represent anything in the real world, you have probably at least heard of the Kalman filter. The filter allows you to take multiple value estimates and process them into a better estimate. For example, if you have a robot that has an idea of where it is via GPS, dead reckoning, and an optical system, Kalman filter can help you better estimate your true position even though all of those sources have some error or noise. As you might expect, a lot of math is involved, but [Pravesh] has an excellent intuitive treatment based around code that even has a collaborative Jupyter notebook for you to follow along.

We have always had an easier time following code than math, so we applaud these kinds of posts. Even if you want to dig into the math, having basic intuition about what the math means first makes it so much more approachable.

Continue reading “Kalman Filters Without The Math”

Retrotechtacular: The Computer Center Of 1973

You might expect Bell Labs would have state-of-the-art computers, and they did. But it is jarring to realize just how little that was in 1973, fifty years ago. If you started work at Bell’s Holmdel Computing Center back then, you might have watched one of the orientation videos below. Your first clue about how far things have come might be the reference to the IBM 370/165, which had “3 million bytes of core, 2 million of which are available for programmer use.” Even our laptops today have at least 8 gigabytes of RAM. There were at least two other smaller IBM 370s, too. Plenty of 029 card punches are visible.

If you were trying to run something between 8:00 AM and 5:30 PM, you had to limit your job run time to three minutes, 4,000 lines of output, and no more than 1,000 cards in and 5,000 cards out. Oh, and don’t use more than 384 kB of that core memory, either. If you fell within those limits, you could hand your card deck over at the express counter and get your results in only five or ten minutes. If you were not in the express line but still rated “premium” service, you could expect to wait a half hour.

Continue reading “Retrotechtacular: The Computer Center Of 1973”

Finding Undocumented 8086 Instructions Via Microcode

Video gamers know about cheat codes, but assembly language programmers are often in search of undocumented instructions. One way to find them is to map out all of a CPU’s opcodes and where there are holes, try those values, and see what happens. Not good enough for [Ken Shirriff]. He prefers examining the CPU’s microcode and deducing what each part of it does.

Microcode is a feature of many modern CPUs. The CPU runs several “microcode” instructions to process a single opcode. For the Intel 8086, there are 512 micro instructions, each with 21 bits. Each instruction has two parts: a part that moves a source to a destination and another that performs some other operation, such as an ALU operation. [Ken] explains it all in the post, including several hidden registers you can’t see, but the microcode can.

Searching for holes in the opcode table.

Some of the undocumented instructions are probably not useful. They are either impractical or duplicate a function you can already do another way. Not all of the instructions are there for technical reasons. For example, opcode D6, commonly known as SALC for “Set AL to Carry”, seems to exist only as a trap for anyone making a carbon copy of Intel’s microcode. When other companies like NEC made 8086 clones, having an undocumented instruction would strongly suggest they just copied Intel’s intellectual property (in NECs case, they didn’t).

Other cases happen where an instruction just doesn’t make sense. For example, you can pop all segment registers, and though it is not documented, you can deduce that POP CS should be opcode 0F. The problem is there is no sane reason to pop CS off the stack. The instruction works; it just isn’t useful. The opcodes from 60-6F are conditional jumps that are no different from the instructions at 70-7F because of decoding. There is no reason to document both identical instruction ranges.

The plot thickens when you go to two-byte instructions. You’ll find plenty of instructions of dubious value. You don’t hear much about undocumented instructions anymore. Why? Because modern CPUs have enough circuitry to dedicate some to detecting illegal instructions and halting the CPU. But the 8086 was squeezed too tight to allow for such a luxury. Good thing for people like us who enjoy solving puzzles.

You can still get a modern CPU to tell you more about instructions even if it won’t run them. Even the 80286 had some secret opcodes.

Ask Hackaday: Learn Assembly First, Last, Or Never?

A few days ago, I ran into an online post where someone pointed out the book “Learn to Program with Assembly” and asked if anyone had ever learned assembly language as a first programming language. I had to smile because, if you are a certain age, your first language may well have been assembly, even if it was assembly for machines that never existed.

Of course, that was a long time ago. It is more likely, these days, if you are over 40, you might have learned BASIC first. Go younger, and you start skewing towards Java, Javascript, or even C. It got me thinking, though: should people learn assembly, and if so, when?

Continue reading “Ask Hackaday: Learn Assembly First, Last, Or Never?”