Sriram Iyer

while(!broken) { fix(); }

Theorycrafting - PRNG on the Arduino

This is a theorycrafting post. I’ve been looking at ways to generate (pseudo) random numbers on the microcontroller. I’ve read some papers which state that over long enough time periods even diode shot noise is prone to bias and drift. I could use debiasing techniques but over time, it’d end up producing bits at a slower rate which isn’t something that I’d want.

Observations: OBD2 on My Car

I plan to make the OBD2 adapter a more permanent installation in my car, but seeing that I have the Bluetooth version of the adapter I was not too happy about the security. Before keeping it plugged in permanently I want to make sure it’s safe. If you see enough Defcon and C3 talks, anything wireless will make you paranoid.

Using Notepad++ Instead of the Arduino IDE

Let’s face it, the Arduino IDE is terrible. I’d rather use Notepad++ to do the writing and then merely use the Arduino IDE as a dumb pipe to compile and upload the code. There’s a couple of things that need to be done for the transition to be as seamless as possible.

Logic Analyzer in a Pinch

A logic analyzer is a great tool to have in your box for when you need to sniff protocols and communication between devices. Too bad I don’t have a dedicated unit (yet) but what I do have are three arduino boards. Surely ther’s got to be a way to detect edges and record them right?

Nvidia Drivers Preventing Computer From Idling

For quite a while I’ve been having a very particular problem – my laptop’s screen would not turn off automatically after the set time. Initially I thought it was an issue with Windows 8.1 which is when I started having the problems. But I soon noticed that it was affecting only this specific computer, and not the others. I was postponing fixing this for a long time. But now I finally decided to get on top of this.

Arduino Mega as an ISP for the Atmega 328

There are a thousand tutorials on the internet on how to use the Arduino board to program an bare atmega chip. But as they say, when Murphy strikes, he strikes hard. It took me almost an entire evening to get my Mega2560 to even get reoognized as an ISP much less program the bare Atmel chip. But, after relentlessly persisting and badgering the poor folks over at #arduino I finally got my Blinky to work on the bare chip. As an aside, I tried this with the Nano 3.0 but I was unsuccessful with it.

High Powered LED Test

Recently I bought 3 pairs of what was supposed to be 3W LEDs. They are meant for installation in a car. I thought to myself, “Well two and a half odd dollars isn’t bad for a pair of 3W LEDs” and thought to try them out. Obviously they are purchased from ebay which basically meant that I needed to wait a month before I can get my hands on anything. For reference they’re called “Eagle Eye 3W LED White” and are sold by many sellers.

Pulling the Arduino Nano Out of a Lock

I was experimenting with the sleep modes on the Nano and suddenly it locked up. Fortunately, I had put a sketch that used the LCD so I had a passing idea of what could possibly be happening. One thing was certain, it was executing the setup() and loop() before all hell was breaking loose. I wasn’t able to upload sketches on the Nano even though it was detected by both, the computer and the Arduino IDE.

Arduino: Extra Output Pins on the 328

I have an Arduino Nano v3.0 that I got for cheap from deal extreme. That’s my 328p board. Connecting the Nano to the standard issue HD44870 LCD revealed to me a pretty big flaw. Once I connect the LCD (which requires 6 pins minimum, 7 if you want to control the LED backlight via software) I end up having only 6 output pins at hand if I don’t count the Serial RX/TX pins 0 and 1. This is obviously a very bad thing because it makes me uncomfortable. What if I need no inputs but a few more outputs? What am I going to do?