Bit-banging Ethernet On An ATTiny85

Ethernet bit banging

[Cnlohr] just published an ingenious but dangerous way to send Ethernet packets using an ATTiny85. The ATtiny directly drives one pair of differential TX wires of a standard Ethernet cable. Doing so will force the TX signal ground to be the same as the ATTiny’s and in some cases may put 48V on your AVR if your cable is plugged into a Power Over Ethernet switch… which may be a problem.

In the video embedded below [cnlhor] explains that the microcontroller is clocked at 20Mhz to bit-bang the Manchester encoded electrical signals. Using a neat trick his home switch will detect his platform as a 10MBit Ethernet switch which can then send hard-coded packets to his computer. As you can guess, each of this packets takes quite a bit of space inside the ATTiny’s flash memory: 2+Kbytes. All of the code used may be downloaded on the creator’s GitHub repository, though he constantly warned us that it shouldn’t be used for real life applications.

Edit: One of our readers also let us know of a similar awesome project called the IgorPlug-UDP. Make sure to check it out!

Continue reading “Bit-banging Ethernet On An ATTiny85”

The Smallest ATtiny85 Based USB Board

Nanite 86

“Possibly the smallest ATtiny85 based ‘duino derivative”. Indeed! When Olimex announced the Olimexino 85s as the smallest Arduino ever, [Tim] took that as a challenge. His very small Arduino based USB devboard is quite a bit smaller than the Olimexino!

The Nanite 85 was carefully designed to be both small and functional. Not only is it 20% smaller than the Olimexino, but also sports a reset button! One of the coolest aspects of this design is that it has the same pinout and size as a DIP ATtiny85. This means that you can use the Nanite 85 for developing your code with the USB bootloader, and then you can directly replace it with a standard (pre-programmed) ATtiny85. The major downside to using this device over the aforementioned devices, is that it does not include a voltage regulator for powering the device via USB (or battery), the device is simply hooked directly to the 5V rail from the USB connector.

We can’t help but be impressed with this well-thought-out design. It is also easy to assemble since it uses larger surface mount components. If smaller components were used, even more features (such as a regulator) could be included. Do you have an even smaller USB Arduino? The race is on for the smallest Arduino ever!

ATtiny85 Data Acquisition

85

The folks at Ivmech recently had a need for some new hardware. They needed a small, cheap device able to sense some analog values, toggle a few digital pins, and log everything to a computer. What they came up with is the IViny, an extremely small data acquisition device built around the ATtiny85, capable of logging data to a computer.

The IViny features two digital channels and two 10 bit analog channels, just like you’d find in any ATtiny85 project. Power is supplied over USB, and a connection to a computer is provided by V-USB. There’s also a pretty cool Python app that goes along with the project able to plot the analog inputs and control the digital I/O on the device.

It’s not exactly a fast device – the firmware only supports 100 samples per second, but an upcoming firmware upgrade will improve that. Still, if you ever need to read some analog values or toggle a few pins on the cheap, it’s a nice little USB Swiss army knife to have.

Nrf24l01+ Using 3 ATtiny85 Pins

[Ralph] wasn’t satisfied with the required 5 control pins to drive his nrf24l01+ transceiver module, so he used this circuit needing just 3 pin using an ATtiny85.

One of the key components was to effectively drive the chip select (CSN) line from the clock (SCK) line. The nrf24l01+ needs the CSN line to transition from high to low on the beginning of a communication.  [Ralph] put the SCK line behind a diode, put a capacitor in parallel with the CSN line and altered the arduino-nrf24l01 library to encode extra delays for the clock line.  This allowed the CSN line to be driven by the SCK line. Subsequent line transitions during transmission happen too fast to charge the capacitor, leaving the CSN line in a low state.

After tying the chip enable line high and dropping the 5V power line to 1.9-3.6V across a red LED, [Ralph] had an ATtiny85 controlling a nrf24l01+ module.

Though deceptively simple, a very cool hack that opens up a couple more lines on the ATtiny85.

Bootloader Brings USB, Firmware Updating To The ATtiny85

[Jenna] sent in a very cool bootloader she thought people might like. It’s called Micronucleus and it turns the lowly ATtiny 85 into a chip with a USB interface capable of being upgraded via a ‘viral’ uploader program. Micronucleus weighs in at just over 2 kB, making it one of the smallest USB-compatible bootloaders currently available.

The USB support comes from V-USB, a project that puts a virtual USB port on a suite of AVR microcontrollers. With V-USB, it’s easy to turn a Tiny85 into a keyboard, custom joystick, data logger, or computer-attached LED display.

One very interesting feature of Micronucleus is the ‘viral updater’ feature. This feature takes a new piece of firmware, and writes it to a Tiny85, disabling the current bootloader. If you’re designing a project that should have a means of updating the firmware via USB instead of the usual AVR programmer, this might be the bootloader for you.

Not bad for a bootloader that emphasizes small code size. At just over 2 kB, it’s possible to use this bootloader on the similar, smaller, and somewhat cheaper ATtiny45.

Teensy Tiny Arduino Board With An ATtiny85

Planning another Arduino build? If you’re just doing something simple like switching a relay or powering a LED, you might want to think about the Digispark. It’s a very small ATtiny-based Arduino compatible board developed and Kickstarted by [Erik].

The Digispark is based on the very popular Atmel ATtiny85, an 8 pin microcontroller that provides a quarter of the Flash storage and RAM as the ‘official Arduino’ ATMega328p. The lower storage space and RAM doesn’t mean the ’85 is a slouch, though; it can run Arduino code without a hitch, providing six pins for whatever small project you have in mind.

Right now, [Erik]’s Kickstarter is offering three Digisparks for the price of a single Arduino. At that price, it’s cheap enough to leave in a project and not be repurposed after the build is over. [Erik] is also working on a few shields for the Digispark – only RGB LED shield for now, but hopefully he’ll get some more finished by the time the Kickstarter ends.

ATtiny85 Sketch Flashing Rig

We’re happy to see Arduino enthusiasts championing the use of smaller hardware when the need for a full-blown ATmega-based board just isn’t there. [Chris] has been doing just that, using ATtiny85 chips in his projects. But he’s tired of hooking jumper wires to flash the sketches. He finally got around to etching this ATtiny85 programming adapter.

If the project is not pin hungry, an ATtiny85 can run Arduino sketches without the need to port the code. The best news is that the Arduino board you used to prototype the project can be used as the programmer for the standalone chip. Here that’s a Boarduino, and [Chris] laid out a double row of female pin headers for quick plug-in. To the right you can see the DIP socket for the target chip. Although this works perfectly well, we would have liked to also see the inclusion of a 2×3 AVR ISP programming header which could be used with the full range of AT chips.