David Estes' Lab Notebook

Week 01

August 26, 2009 (1 hour):
Met as a team after class to discuss preliminary project proposal.

August 27, 2009 (3 hours):
Began designing preliminary block diagram of project. Including parts research to determine diagram approach

WEEK 01 SUMMARY
Accomplishments: Submitted preliminary project proposal. Began work on project block diagram.
Weekly Work Total: 4 hours
Project Work Total: 4 hours

Week 02

August 30, 2009 (4.5 hours):
Gave a course on embedded linux systems including installing the ubuntu operating system on everyones machine. Also gave a brief discussion on the operations of an audio mixer for those slightly confused and briefly explained the key elements of one.

September 1, 2009 (1 hours):
Setup web-site and created presentation powerpoint for class. Nothing pretty, will make pretty later.

September 2, 2009 (5 hours):
Met as a team to try and hunt down faders and refine some possible block diagram issues with our design. After which I went home and worked on getting buildroot to compile for the ARM9 processor. Newer version of ubuntu broke compatibility, as a result had to get my hands dirty and resolve the errors. Successfully tested buildroot by compiling ARM kernel and flashing arm9 successfully.

September 3, 2009 (.5 hours):
Met as a team to finish the final project proposal.

WEEK 02 SUMMARY
Accomplishments: PSSC and project proposal finalized.
Weekly Work Total: 11 hours
Project Work Total: 15 hours

Week 03

September 7, 2009 (2 hours):
Team meeting. We discussed our design constraint analyses and changes to project's block diagram. This includes the decision to use a DSP processor for audio processing and Adam ordered the Atmega30A's in DIP package for prototyping.

September 9, 2009 (3 hours):
Met up with Chuck in the Lab and checked out the Analog Devices DSP kit as well as the tablet. Built a basic H-bridge on a breadboard to test the motorized fader sent to us from Soundcraft. Looks good and can operate pretty well at 10V.

September 10, 2009 (2 hours):
Started Designing JFET based Audio Preamplifier with Balanced inputs.

September 12, 2009 (4 hours):
Started working on Project Design Constraints Report. It is turning out to be quite a bit longer than expected considering the use of 3 different micro-controllers in the design of our project.

WEEK 03 SUMMARY
Accomplishments: In Progress, refined design approach for project
Weekly Work Total: 11 hours
Project Work Total: 26 hours

Week 04

September 13, 2009 (3.5 hours):
Team meeting in Lab. I worked on building and testing the JFET Preamplifier design I created. After analyzing the circuit and testing we get a clean gain all the way through the frequency spectrum at +54dB and 94dB signal to noise ratio. This meats our goal of +40dB gain with 80dB signal noise ratio. Click here for the schematic.

September 14, 2009 (1 hours):
Started Migrating Block Diagram over to Orcad.

September 14, 2009 (3 hours):
Worked on Design Constraints report with group and started reading introductions to DSP Programming.

September 15, 2009 (4 hours):
Continued work on Design Constraints Presentation. Integrated Framebuffer Display support into ARM9 linux kernel to be flashed onto the Hammer Board. Gave a general overview to group of how DSP programming is structured with circular loops and the steps necessary to tackle our design goals.

September 16, 2009 (4 hours):
Took a look at the DSP kit to try and figure it out so I could teach rest of the group. Read assembler book as reference and made it my first goal to convert their talk through assembly example into C. Once this was successful I had gotten a much greater understanding of the code and started manipulating. Succeeded in gain control / panning, and even delay.

WEEK 04 SUMMARY
Accomplishments: Got DSP Functioning and worked on Design Constraint Analysis
Weekly Work Total: 15.5 hours
Project Work Total: 41.5 hours

Week 05

September 20, 2009 (3 hours):
Team meeting in Lab. Worked on creating footprints in PADs as well as took a look at Levi's progress on Packaging Design. Also discusssed preliminary PCB footprint

September 21, 2009 (3 hours):
Sourced and Ordered LED Bar graphs, and MOSFET H-bridges for motor-driven fader control. Updated ARM9 kernel code with drivers for received Panasonic 7.8" display.

September 23, 2009 (1 hours):
Helped Levi track down and order parts for LED pushbuttons.

September 24, 2009 (3 hours):
Worked with Adam to create the footprint for the ATMEL and also began schematic for atmel interface. Talked to Chuck about potential power supply solutions as well as PCB ordering issues we might have with the number of PCBs we plan to have.

September 25, 2009 (7 hours):
Spent most of the day in Lab designing the Audio schematic with embedded sheets in PADS. Took a while to isolate all footprints and layout correctly. Also created footprints for A/D Converter AD1871 and necessary schematic components for correct operation.

WEEK 05 SUMMARY
Accomplishments: Packaging Preliminary complete, and significant progress made on Schematic Design.
Weekly Work Total: 17 hours
Project Work Total: 58.5 hours

Week 06

September 28, 2009 (3 hours):
Ordered parts for display such as ZIF connectors as well as XLR Connectors for the project.

September 29, 2009 (3 hours):
Created Presentation for preliminary schematic. And built out more of the schematic files.

September 30, 2009 (7 hours):
Worked on Audio Schematic and helped other team members build out the other schematics.

October 1, 2009 (1 hour):
Finished going over preliminary schematic and submitted.

WEEK 06 SUMMARY
Accomplishments: Packaging Preliminary complete, and significant progress made on Schematic Design.
Weekly Work Total: 14 hours
Project Work Total: 72.5 hours

Week 07

October 4, 2009 (8 hours):
Soldered ZIF connectors and tested. Began hooking up LCD display to hammer dev board and started enabling framebuffer support in kernel.

October 5, 2009 (7 hours):
Discovered that in order to get the display to work with the Hammer a driver will have to be written. This includes bpp settings as well as margin and sync settings. Started this and got backlight functional as well as flickering on the screen. Will try to progress farther tomorrow.

October 6, 2009 (4.5 hour):
Got a message from a guy in the open source chat room for the s3cxxxx chip model. Later discovered he is actually the creator of the hammer developer board. He has been very helpful in debugging my code and we have gotten much closer. He is going to try to duplicate my setup this evening and get back to me tomorrow.

October 7, 2009 (4 hours):
Received an e-mail from prpplague with .patch files for the display from an older kernel he built it on. Spent time porting those patches to the new kernel. We have a penguin on the screen!!

October 8, 2009 (12 hours):
Helped Adam prepare the final report and pcb files for grade submission.

WEEK 07 SUMMARY
Accomplishments: We got a 7.8" display kinda working on a hammer board framebuffer. Very exciting!! Also successfully finished our PCB's for homework / review
Weekly Work Total: 35.5 hours
Project Work Total: 107.5 hours

Week 08

October 13, 2009 (3 hours):
Started Design Review Presentation and began more work on Hammer Source code. This includes rebuilding a tool-chain for the hammer which has so far needed to be tested.

October 14, 2009 (2.5 hours):
Met as a team to finish design review presentation and go over some other project timeline related information.

October 15, 2009 (3 hours):
Went over presentation for design review and progressed farther on the Hammer Code. This includes re-familiarizing myself with Qt Embedded. It's been a few years since i've touched it and things have certainly changed in the newer version.

WEEK 08 SUMMARY
Accomplishments: Finished and performed Design Review
Weekly Work Total: 8.5 hours
Project Work Total: 116 hours

Week 09

October 19, 2009 (3 hours):
Began going over display driver on Hammer again. Didn't get much a noticeable difference in display. This one i'm kinda waiting to here back from prpplague this next week to see what he finds out.

October 20, 2009 (3 hours):
Met up with team in lab to discuss what needed to be done to be able to reach our deadlines. This includes fixing errors and part fit acquisition.

October 21, 2009 (8 hours):
Started fixing errors on PCB as well as getting David Collins to check off parts. We discovered we did not order a part (whoops) so we had to get it overnight shipped for part fit. Also called analog devices to try and help verify our design but they don't apparently have phone support on their DSP line. We also submitted PCBs to freedfm.com

October 22, 2009 (2 hours):
Went over freeDFM errors from yesterday and gave Adam instructions of what needed to be done before I left for work. Also met up with Susanne at end of day to see what the progress was and what needed to still be done. I have to package these files and send them to Chuck first thing tomorrow.

WEEK 09 SUMMARY
Accomplishments: Removed PCB errors and made changes per suggestions from design review. Looks good!
Weekly Work Total: 16 hours
Project Work Total: 132 hours

Week 10

October 26, 2009 (5 hours):
Worked more on the Hammer and ran into issues with compiling the bootloader using the latest ARM toolchain for the Hammer. It appears the latest version of gcc optimizes the code for ARM architecture too much. The bootloader init code uses nop delays to give the devices on the arm their necessary delays for startup. However the latest gcc sees these nops and removes them for "optimization". This results in preventing the apex bootloader from being able to properly boot the Hammer. Spoke to Dave Anders and he says they need to be moved to using SoC Timer delay to work correctly. However, for now, found a way in the latest buildroot package to change the default gcc version to use. Lowered the version to a functional revision and have successfully created a new bootloader.

October 29, 2009 (2 hours):
Met with Susanne to help her with the Software narrative. A lot of information was unclear and we cleared it up and mapped out the process for the software design.

WEEK 10 SUMMARY
Accomplishments: Created a functional bootloader binary file that works on ARM architecture.
Weekly Work Total: 9 hours
Project Work Total: 141 hours

Week 11

November 2, 2009 (3 hours):
Up to this point have been unable to get anything pertaining to a fresh updated root filesystem to work on the Hammer board. I have created a good kernel, and have created a bootloader. Today this issue was resolved when working with Dave Anders over IRC (Creator of the Hammer Board , he can be found in irc.freenode.net channel #s3cxxxx with the screenname prpplague). He has been very helpful in bringing me up to speed on embedded linux and I greatly appreciate it. With his help debugging the root filesystem now works well. Several config files in the buildroot package were incorrect and had to be updated to work with the Hammer. Some of this involved updating the device_table.txt file as well as defining ttySAC0 as the default console instead of ttyS0.

November 3, 2009 (3 hours):
Printed Circuit board came in today. Met with Levi to take a look at them and work on some soldering. Started and had a lot of success however discovered there were some issues with the fabrication of the board. The power supply went up in flames due to an overlapping trace. The board, however, looks intact and Levi plans to talk to Chuck tomorrow about fixing the overlapping trace.

November 4, 2009 (5 hours):
Started Programming SPI interface code on Hammer board. The SPI support in embedded linux is actually rather complicated and it was recommended to access the SPI registers directly. This was performed and created as a kernel module that simply executes init code for the AD1871. Began building buildroot toolchain with JFFS2 support but kernel kept panicking at init due to a mounting issue.

November 5, 2009 (5 hours):
Continued work on buildroot and successfully got JFFS2 support working on the Hammer. The current buildroot version no longer supports the Hammer board. To resolve this i have setup the appropriate board definitions in the buildroot file to create the proper device_tables and default configs. As soon as im confident it is correct I will post it up and post it on the Hammer documentation Wiki for those other developers who might get stuck in the same boat as me. Not only did I get the root filesystem functional I also have successfully compiled and uploaded Qt Embedded API for the framebuffer. Touchscreen support for this chip looks like I may have to write another linux driver from scratch. Oh fun!

November 7, 2009 (5 hours):
Created I2C C++ Libraries needed to talk to individual channel interfaces. It still needs tested but the communication structure is all setup

November 8, 2009 (3 hours):
Worked more on the I2C Interface and did some local tests. Kernel is acknowledging that I2C requests are being made. Just waiting on Adams part to get it finished.

WEEK 11 SUMMARY
Accomplishments: Successful rootfs has been created to house the project storage. Also got spi code started and successfully compiled for the architecture. I2C Code was started as well.
Weekly Work Total: 24 hours
Project Work Total: 165 hours

Week 12

November 8, 2009 (3 hours):
Worked more on the I2C Interface and did some local tests. Kernel is acknowledging that I2C requests are being made. Just waiting on Adams part to get it finished.

November 9, 2009 (3 hours):
Worked with Adam on his Individual Channel Interface code. We had some success getting the TWI interface to read and write data but it requires a significant delay per command. It seems the H-bridge on our breakout board was fried causing a lot of debugging headaches.

November 10, 2009 (5 hours):
Worked on the ATMEL Code some more. Added Fader control, LED, and pushbutton support. Debugged a while and noticed somewhere there exists a stack overflow causing the program to hang.

November 11, 2009 (3 hours):
The Atmel Code is consistently responding to test sequence commands from the Hammer board now. All we have to do now is add RPG support and run it on the actual PCB Boards.

November 12, 2009 (6 hours):
This morning I decided to test the Hammer chip on the main board. Noticed several issues when first tested. The Serial Port didn't work at all. Someone forgot to run power to the MAX232 (whoops!). We had to run a fly wire to the chip and everything was up. Then the LCD Display wasn't displaying anything for 2 reasons. 1) Mouser sent the wrong CCFL Inverter (140Vrms instead of 800Vrms as ordered). 2) The Contrast voltage divider resistors were incorrectly labeled from the drawer. After these issues were resolved we were back to a blurry LCD screen. I spent another hour using devmem and directly changing the LCD control registers and changing a bit in LCDCON5 from 0x03 to 0x02 removed the blur. After which I compiled a sample Qt application and tested with success.

WEEK 12 SUMMARY
Accomplishments: I2C Interface 90% functional, simply working on reliability now and improving the performance. Tested main chip on main board and found a few trace errors, but nothing extremely critical and was rather easy to fix. Also resolved a significant amount of issues with the LCD display and it is now legible. Determined that if the touchscreen aspect of the screen cannot be brought up to functional, we can use a USB mouse to accomplish our PSSCs. Also got a successful build of Qt sample application with a successful render.
Weekly Work Total: 20 hours
Project Work Total: 185 hours

Week 13

November 16, 2009 (5 hours):
Worked further with Adam on the Atmel code. The RPG code was added by Adam and we tested it. We also improved fader motion support. Also worked on getting display to look cleaner. It was still very hard to read. After a series of extensive testing I was able to find the control register causing the issue in the video controller. LCDCON5 = 0x02 not 0x03. Also got Qt flashed to system and successfully launched a Qt application. However, in Qt the color is still all wrong.

November 17, 2009 (3 hours):
Added hammer code to more closely monitor i2c results from system. Detected (on occasion) bad data bits being received over the i2c bus. This was due to an inadequate delay after performing an i2c_read.

November 18, 2009 (5 hours):
Worked on display extensively. Tried various changes to color on the buffer trying to discover cause of large amount of rainbow lines in Qt interface. Discovered Qt did not support 12-bit color and although the display is 8-bit STN (it is technically a 12-bit STN with the last 4 bits masked off). Alternative is to use ncurses.

November 19, 2009 (3 hours):
Began writing ncurses GUI code to get information from channel peripherals and update properly.

November 20, 2009 (6 hours):
Today i went deep into ncurses programming. I got a basic library built to render all 8 channels on the screen and began testing. After some debugging we got it working and updating based on the user moving faders or rotating the RPG. The only current issue with it is it has yet to register push buttons and the refresh on the display is very delayed.

WEEK 13 SUMMARY
Accomplishments: I2C is much more reliable now and the display GUI is beginning to form. We have successfully fixed the displays visibility as well as decided to fall back to ncurses ( not as pretty but works well) GUI library.
Weekly Work Total: 22 hours
Project Work Total: 207 hours

Week 14

November 22, 2009 (5 hours):
Spent several hours cleaning up ncurses code. Decided to move the fader window into a class object so I had seperated interface code from i2c code. This allows for easier threading. Also modified this widget to only update the sections of the screen that have changed data. This GREATLY improved refresh rate and removed flickering. Also implemented threading in project such that the interface was updated separately.

November 23, 2009 (11 hours):
Modified GUI code to register push button registers successfully. Also worked with Adam to modify fader movement in atmel code to update properly. Also it was discovered today that there was a major error in the preamplifiers due to a schematic error. Most of the day was spent cutting traces and running fly wires to the correct areas on these boards. We managed to test and get 5 of 8 preamps functioning correctly.

November 24, 2009 (3 hours):
Went into lab and did some more work on preamp boards as well as hammer code. Also began organizing what needs to be done in the next week in order to get this project finished in time.

WEEK 14 SUMMARY
Accomplishments: Display is much more responsive now and more cleanly organized in the code. Threading is also functional. We also managed to discover a major issue in the preamplifier boards and have corrected 5 of the 8 preamps.
Weekly Work Total: 19 hours
Project Work Total: 226 hours

Week 15

November 29, 2009 (3 hours):
Began work on implementing SPI interface on hammer board. Discovered a lot of kernel configurations had to be changed to accomplish this. Removed all errors and have a device registered. Now I have to get it to talk. Also added master window to GUI in order to display read outs from main faders and effects faders. This code had to also be written to handle potential for fader lock.

November 30, 2009 (11 hours):
Spent several hours implementing SPI in the user-space application on the Hammer board. Tested with a logic analyzer and verified data is being transmitted over the SPI bus. It was, however, discovered that there was data on the MISO when there shouldn't have been due to the led drivers being connected to it. All that needed to be done was to cut the trace and it was good to go. Implemented AD1871 and AD1833 register definitions and initialization code. Also tested communication with Adam's Master Fader code. It was functional with a few tweaks. Finally hooked the programmer up to the DSP and loaded a test program. The DSP chip is operational!!..Began looking into how to configure the Serial Pins on the device.

December 1, 2009 (6 hours):
Today the panel came in from the machine shop. I helped Levi work on it briefly while I kept programming the Hammer for i2c operation. There was a lot of clean up code needed. Also attempted to compile the GPM (mouse daemon) for linux with little success. I will have to prioritize and just use a keyboard for now.

December 2, 2009 (8 hours):
Spent hours working on getting audio to work on the A/D. The DSP was not receiving any data and the SPI bus was not correctly updating the A/D's. Spent several hours debugging this. Discovered some registers weren't configured properly but to no avail. Also tried to reduce noise on the A/D line by making the transmission line out of CAT7. This still did not succeed in fully eliminating the noise.

December 3, 2009 (6 hours):
This morning we were stumped as to the issues behind the A/D. While we were standing there one of them started smoking. I went over the schematic and discovered that Adam had run 3.3V on one side of the chip and 5V lines on the other. In order to fix this several traces will need cut and fly-wired. I had to overnight new A/Ds today as well. As a result of this set back I resumed work on trying to add the boot-loader code to the Hammer so that it would be capable of boot-loading the DSP in the future.

December 4, 2009 (3 hours):
Came in in the morning and notified Chuck that our A/D's needed removed. After this was done I took them and marked them for trace cuts. Then sent them back to him. I had a meeting in Indy in the afternoon so this was all for today.

December 5, 2009 (12 hours):
Today I took a look at the issue Levi mentioned to me regarding a blown h-bridge. Ran a test and discovered that there was a fault in the h-bridge design. Ross came in and took a look at it with us to try and give us some insight as to the cause of the problem. It was determined that level shifter circuitry was needed in order to properly operate these h-bridges. I got Adam started on this and he also ordered H-bridges overnight shipping to come in on tuesday of next week. Also was having issues with the Hammer locking up for some unknown reason. Tried to resolve by replacing the dip socket as well as putting a decoupling capacitor on the reset pin to no avail. Also today I worked on running fly-wires on the audio board to fix the discovered A/D issue from last week. Powered the chips up and they no longer smoke so there is some success there.

WEEK 15 SUMMARY
Accomplishments: Made significant head way in putting the pieces together. Discovered another mistake in the schematic of significant importance and resolved the audio issue. Also discovered issues with the H-bridges and created a solution for the problem. We also started implementing master fader communication in the Hammer user interface.
Weekly Work Total: 49 hours
Project Work Total: 275 hours

Week 16

December 6, 2009 (9 hours):
Spent several hours trying to get the data format on the DSP's serial ports to register correctly. Discovered that one of the pins was not modifying it's output per my commands. Then it was discovered that the SHARC was running EXTREMELY hot. We determined that it was bad and in need of replacement. Went and got a microphone from a friend and tested the preamps as well to make sure that fans weren't adding too much noise into the system. The audio coming out of the system was extremely clean and sounded great.

December 7, 2009 (8 hours):
Got into lab this morning and had Chuck replace the SHARC DSP that was hot enough to boil eggs on. This resolved a lot of the issues however the Hammer was still periodically rebooting / locking up. Dave Anders suggested we might be overloading the SPI line so we added buffers into the circuit to no avail. Finally I took the chip out and put it on the dev board which is when we discovered it still has potential to freeze even after reflashing. It was confirmed late this evening that the Hammer chip is bad and in need of replacement. I sent an e-mail to Dave Anders asking for a possible education discount considering the cost of this chip.

December 8, 2009 (8 hours):
Due to the discovery of the bad hammer we contacted Dave Anders over at Tincantools and he was happy to overnight me a new Hammer for free. Be it noted he is a lifesaver on this project. Spent most of the evening rewriting a lot of the GUI interface to clean up some of the code and improve functionality for features such as saving scene settings.

December 9, 2009 (14 hours):
Got up early and continued work on cleaning up the user interface code. The code now runs clean POSIX Threading as well as a message queueing API that I wrote myself. This message queue allows us to send commands to the different threads without having thread fighting. It also allows me to send messages to freeze GUI updates in the event menus are overlapping certain areas so that they don't get erased. The Hammer arrived in the afternoon from tincantools and I ran into lab to start flashing it. After the preliminary presentations lecture we went back to lab and finished updating the replacement Hammer. I tested it extensively while Adam finished implementing the H-bridge repairs on the main board. After this the boot-up sequence of the hammer was modified to auto start the new user interface as well as show a nice custom boot logo. Also modified buildroot to not include the Qt API to reduce size and includ the libmenu, libpanel, libncurses libraries for the GUI.

December 10, 2009 (14 hours):
Worked on user interface cleaning up code and getting the i2c bus to work properly. Also tested the scene settings to see if we could move faders back to previous sections. Blew up 2 ATMEls and 2 H-bridges on channel 1 & channel 2. Chuck happened to have an ATMega32L which was sufficient to operate our board. It is actually working very well however, the spare ATMEGA32A we had in stock is bad out of box. Successfully demonstrated 3 PSSCs. This includes scene settings, display, and manipulation of equalizer settings.

December 11, 2009 (7 hours):
First started working on audio trying to get it to work. Verified that the SPI bus was communicating properly. Still having no luck getting audio output but will have to take a look at it later. I2C Bus was broken yesterday in an attempt to resolve the occasional error glitches on the bus. Error Handling was added to the i2c protocol between the hammer and the atmels. We did get this functional and discovered that with the current Atmel code a significant delay is needed in order to read register values. Will look into fixing this later.

December 12, 2009 (13 hours):
Spent Several hours replacing h-bridges and bad Atmegas on the channel interface board. Also prototyped audio on the dev board for the SHARC to verify that my interrupt driven code works correctly and it is confirmed with successful talk-through. Also discovered why the i2c bus was so slow to respond on the ATMELs. There were issues with the sample twi code given to us by AVR and significant modification was required. Now the bus is extremely responsive. Also took off main board and folded the ribbon cable for the LCD display behind the board so as to keep it from getting damaged.

WEEK 16 SUMMARY
Accomplishments: This week was riddled with both failures and success stories. Chips were discovered to be bad and replaced. We had to have a Hammer overnighted to us from tincantools and our DSP had to also be replaced. We also were able to prove success on 3 of our 5 PSSCs. This included displaying channel interface information on a screen, adjusting settings using the RPGs, as well as moving faders (saving / restoring scene settings). On top of this headway was made on the audio portion of the project and responsiveness / reliability was improved on the i2c bus.
Weekly Work Total: 73 hours
Project Work Total: 348 hours

Week 17

December 13, 2009 (13 hours):
Got into lab in the afternoon and replaced an H-bridge on channel 6 that had blown the night before. Also took the right audio board out and replaced the AD1833A D/A Converter. We discovered a missing 15V supply for the output preamps and resolved this issue as well. Also too much noise was detected on D/A Channel digital lines. Spent several hours creating more noise crosstalk resistant cables and have data going to the D/As. Discovered the Analog Devices programmer adds a lot of noise to the system and is causing problem on processing the A/D Data.

WEEK 17 SUMMARY
Accomplishments: Got successful communication with D/As and still have some noise on A/Ds but we are getting noise on the Audio out lines. Getting closer. There is still some more work that needs to be done in noise reduction.
Weekly Work Total: 13 hours
Project Work Total: 361 hours