Integrating the Projects

This week I started by trying to modify the FPGA code so that it would transfer in chunks of data rather than all in one go. Turns out a lot of the codes are not needed so Dr Shawn rewrote everything into less than 10 lines, this time using the Static SPI driver instead of Dynamic. The code now transmits the bitstream byte by byte. Next I experimented with the usbcdc com port project in order to output a string Read more

FPGA now working

The FPGA is now configurable using the pic32mz. The cause of the problem was identified as being the clock to the FPGA not being set, and also the ucf file declared an unconnected pin, J13 as the clock pin. The problem was solved by enabling REFCLKOx in the Harmony Configurator, System Services->Clock->Use Clock System Seervice?->Clock Configurator Settings->Enable Reference Clock x, and then routing the pic32mz pin to the actual clock pin on the FPGA, and changing the declaration of the location Read more

Testing the FPGA

Started the week by checking some of the keyboard code to find out what is wrong. I found that the device driver for the keyboard seem to be working ok, just the key sending part. The code seems to be for a keyboard with a 6 key rollover, which lets the keyboard send multiple keys at one go. I removed some part of the rollover code and as expected, it won’t send any keys, but the device driver works fine Read more

Restructuring keyboard code

This week I restructured the code for the usb keyboard, the aim is to modify as little as possible from the original demo code, so that there is a clear separation of my code from the one provided by microchip in its demo code and also reduces the amount of code that is caused by modifying the code. I created separate functions that work alongside the original code, but uses a global variable to provide a bridge between my code and the state Read more

Firmware testing

This week I proceeded to test the firmware created by the previous interns. The first thing I needed to do was replicate their result. One thing I realised from this is not to remove the board support package in the harmony configurator, as it turns out to be important in the tcp ip stack initialization. I first tried the pic32blink test, which for me does not actually blink but toggles the led that indicates that the driver is busy with a previous Read more

Switching to actual board

Started the week by continuing on with implementing a hid keyboard on the pic32. While doing this I encountered two major problems, one is that the keyboard refuses to output two of the same characters consecutively, the other  problem was when I tried going through the character array starting from the 0th position, it starts from an arbitrary position instead (sometimes 5th, 6th, but mostly 11th to 13th position). For the problem that it doesn’t print out two same letters Read more

MPLAB X IDE and Harmony Configurator

This is my second week in Aeste, I was tasked to familiarize my self with MPLAB X and also harmony configurator, especially on USB stack and tcpip stack. For the tcpip part, I needed to host a web page on the pic32 esk, and after that was to enable ssl. There is already a wolfssl tcpip demo in the harmony configurator which you can use. But you have to copy the project to another location and set the directory of the harmony configurator. Read more

First Week as Intern

Started off my first week as an intern here at AESTE. Before coming here I had less than 2 weeks to study my pre-internship materials, as I had applied here late. First week involved studying using Git and also trying to understand the pre-internship study materials that I was given. Among some of the interesting things I learned was that in C coding, typedef can be used to create a fake type, which seems really useful. Confusing bit were pointers and structs, Read more

Clarification on Wt Session Timeout

If you used Wt, you should be aware of the  session timeout set in wt_config.xml. I think this ‘feature’ requires more explanation on it rather than When a session remains inactive for this amount of time, it is cleaned up After experimenting much with the timeout, it does not work as expected. And to summarize on the behavior, it is unreliable. The session timeout never  triggers on time if the browser is closed. It is actually explained in detail by Koen in Read more

Leveraging on WResources

I continued to move all storage related actions to the back-end. The idea is to have a clear separation of front-end (consisting of widgets and callbacks) and back-end (handling of requests). When a complete model is built, the building blocks can be easily replicated and altered to cater for other services. Troubleshooting becomes a breeze too when things are built in an orderly fashion. Exploiting the refresh_token Since the discovery of the refresh_token, things are working out great. You can Read more