Description: After acquiring an Arduino and several 8x8 LED matrices, a project was initiated to effectively utilize these components. Concurrently, there was an increasing interest in Twitter and its API, leading to the development of a Twitter popularity meter. This system employs a PHP script to search Twitter for a specified term, hashtag, or reply, displaying the results on a webpage that indicates the number of occurrences. The Arduino, equipped with an Ethernet shield, retrieves this page and presents the data in a bar graph format on the LED matrix. The core hardware consists of the Arduino with the Ethernet shield, two 74HC595 shift registers, and an 8x8 common anode LED matrix sourced from China via eBay. The Arduino requests the current popularity metric page, updates an array reflecting the lit LEDs, and sends this data to the shift registers to illuminate the appropriate LEDs. The schematic is available below. A custom PCB for this project is currently awaiting fabrication. The circuit has been assembled into a more durable form as an Arduino shield, facilitating its reuse for any application requiring an 8x8 LED display. The system relies on a PHP script to search Twitter and generate a numerical representation of the popularity of the search term, utilizing cURL to retrieve a JSON feed for counting results (source code is provided below). The Arduino software reads the number from the webpage, converts it to a binary format to control the number of lit LEDs, adds it to the array of previous popularity results, and updates the LED matrix. There is also a conversion process since the number is initially in ASCII format. Previously, this system operated with a client computer reading the PHP script from a web server and transmitting the results via serial to the Arduino, but it has now transitioned to direct communication between the Arduino and the server. Future enhancements will aim to refine the popularity metric by incorporating data from follows, replies, and hashtags, rather than relying solely on a simple search term.
The circuit design for the Twitter popularity meter includes several key components that facilitate its operation. The primary component is the Arduino microcontroller, which serves as the central processing unit for the system. The Ethernet shield connected to the Arduino enables network connectivity, allowing the microcontroller to send HTTP requests to the server hosting the PHP script. The PHP script is responsible for querying Twitter's API, using cURL to fetch data in JSON format. This data is parsed to extract the relevant popularity metrics.
The LED display consists of an 8x8 common anode matrix, which is controlled through two 74HC595 shift registers. These shift registers are crucial for expanding the number of output pins available from the Arduino, enabling control over all 64 LEDs in the matrix. Each shift register can control 8 outputs, thus two are used to manage the full LED matrix. The Arduino communicates with the shift registers via the SPI (Serial Peripheral Interface) protocol, sending the appropriate binary values that correspond to the number of LEDs that need to be illuminated based on the popularity metric retrieved from Twitter.
The software running on the Arduino includes a routine that fetches the popularity metric from the specified URL, processes the information to convert it into a binary representation, and updates the LED matrix accordingly. The conversion from ASCII to binary is a crucial step, ensuring that the correct number of LEDs lights up in response to the popularity metric.
This project not only exemplifies the integration of hardware and software but also highlights the potential for real-time data visualization using LED matrices. The future enhancements planned for this project aim to provide a more comprehensive view of Twitter engagement by including additional metrics such as the number of follows and replies, thereby enriching the data representation on the LED display.After buying an arduino and some 8x8 LED matrices I really needed a project to make good use of them. At a similar time I also had become a bit addicted to twitter and had been reading up on the API with the intention of doing something cool with it, somehow these ideas all got rolled into one to give a twitter popularity meter.
The system uses a P HP script to search twitter for a predefined term, #tag or @reply and then presents the result of this as a webpage with number of results. The page is then read by an arduino with associated Ethernet shield and displayed on a bar graph format on the LED matrix.
The central part of the hardware in this project is the arduino with ethernet shield then 2x 595 shift registers and one 8G—8 common anode LED Matrix from china via ebay. Basically the arduino requests the page containing the current popularity metric and then adds it to an array containing the states of the currently lit LEDs which is then pumped out to the shift registers to update the display.
The circuit lights the correct LEDs. The schematic can be viewed below. Currently I`m waiting for a custom pcb of this to be fabricated. I have now assembled the circuit into a more robust for as an arduino shield, this will allow it to be easily reused for any application which requires an 8x8 LED display. The system relies on a PHP script to search twitter and provide a number to represent the popularity of the search term.
This uses cURL to search twitter and receive a JSON feed from which it counts the results (source code available below). The software run by the arduino reads a number from the webpage then converts it to a binary representation of the number required to light that many LEDs, adds this to the array of previous popularity results and then updates the LED matrix.
There is also conversion as the number read is in asci. Previously this system was run using a client computer to read the PHP script from the webserver and then feeding the result via serial to the arduino, this has not been abandoned in favour of the arduino communicating directly with the server. The next stage for this project will be to improve the generation of the popularity metric by taking in the number of follows, @replies and #tags rather than just a simple seach term
It is possible to construct a basic Arduino setup independently. This project illustrates a breadboarded Arduino configuration that does not utilize an FTDI chip, which implies the absence of USB connectivity. However, USB connectivity can be achieved through the use...
The switch control system utilizes sensors to inform the microcontroller of the trains' positions on the layout. This ensures that only one train occupies the main line at any given time and that switches are correctly set for the train's...
An analog output for Arduino can be achieved using a Digital-to-Analog Converter (DAC), commonly implemented with an R-2R ladder circuit. However, this DAC lacks an output buffer, which would enhance reliability and compatibility with various loads. For optimal performance, incorporating...
An attempt at an Arduino guitar pedal. The guitar signal feeds through a PT2399 delay circuit, modified to include a JFET preamp phase. The delay circuit has Echo and Delay knobs. From there, it feeds into an optoisolated-Arduino-5V preamp, and...
The figures above illustrate the fundamental concept of a robot, which comprises input and output devices connected to a central processing unit, often referred to as the brain. In this case, the Arduino acts as the brain, controlling all robotic...
The initial step in constructing an RFID door lock using a basic Arduino involves breadboarding a fundamental working Arduino setup. Most Arduino boards equipped with pre-flashed ATMega 168 chips come with a default blink program installed. A LED should be...
When starting with Arduino, one often accumulates more Arduino boards than RS232 or USB ports available on the computer. Therefore, it is more practical to use an external signal level converter rather than placing it directly on the Arduino board....
Designing a controller PCB for a 10x10 white LED matrix clock based on an ATmega328 AVR IC and a Maxim DS3234 SPI RTC. The challenge lies in controlling a custom non-standard 10x10 LED matrix. Initially, a Maxim MAX7219/7221 IC was...
The control of the system is managed by a Microchip PIC18F46K20-I/PT microcontroller, which is programmed with firmware to oversee the activity of the GSM/GPRS module, monitor the logic conditions of two opto-isolated inputs, and send commands to two relays within...
We use cookies to enhance your experience, analyze traffic, and (if you allow) serve personalized ads.
By clicking Accept All, you agree to our use of cookies.
Learn more