24 09 2017
As I said in a previous post, I’ve contributed to some samples for the VITASDK.
This one is interesting to me as I’ve never used sockets before.
This sample is going to ping the Google DNS server 18.104.22.168.
I have to admit that I scratched my head for a while when trying to ping my laptop and not getting a response even though I saw the ping request in Wireshark.
An IRC (#henkaku & #vitasdk) user by the name of xyz told me to try to ping 22.214.171.124 and that the firewall in my laptop might be blocking the PSVita’s ping request.
He was right! I pinged 126.96.36.199 and I immediately got a reply… Stupid laptop…
27 03 2014
Someone on the matrix multimedia forum (French) needed to drive some WS2812 LEDs and wanted to use a 16F876A at 20MHz to do so.
The WS2812 LEDs are RGB LEDs with an integrated controller chip. There’s a data input and data output so you can cascade multiple LEDs by connecting DO to DI of the next LED. Each LED reads 3 bytes, being the value of the color green, red and blue.
Once you’ve sent a color to the LED, it will stay that color until you send another code.
Driving the LEDs would require timings in the 50ns/100ns range, but you can stretch it just a bit.
This is one of those things where timing is pretty much crucial and an AVR would be a better microcontroller for this as it executes one instruction per clock cycle where the PIC needs 4 clock cycles per instruction.
1 08 2013
I have here a sample code that uses the Winstar OLED display library, aka WS0010 driver.
It’s so easy to use, I’m just going to copy paste the code here.
15 07 2013
I was given the idea to make an equalizer, or to at least try making one.
The way you make an equalizer is by taking some audio samples, use the FFT transformation on those samples then modify the amplitude of the FFT output at the desired frequencies and use those modified amplitudes as an input for an inverse FFT.
The output of the inverse FFT will give you a new set of samples that you can use and send to a DAC or other digital to analog converter.
15 07 2013
For those who would like to have a sample code for the FFT library, I’m going to attach a zip file containing the source code and code::blocks project file for you to try out.
The sample file will test an 8 point FFT on a signal containing two sine waves.
A sine wave of 1kHz with amplitude 1, phase 0° and another sine wave of 2kHz with amplitude 0.5, phase -45°.