Wheek 13: Interface and application programming.


This week assignment was to make an interface program and connect it with an input or output device. i made a satschakit board as the controller board and link it to a Labview interface. The workflow was use the satchakit to read the an analog signal and show it in a graphic interface that was programmed using Labview. This signal will be used in the future as a robust control with PWM signal for the final project. I learned about this assigment, and used this link: For more information the following link:
http://fabacademy.org/archives/2015/doc/projects/fabkit-0.4.html

The first step was to use the EAGLE software for the making of the board. The microprocessador Atmega 328P is necessary for this asigment. I followed the following link to obtain information about the Atmega 328p and its dataasheet.
http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-42735-8-bit-AVR-Microcontroller-ATmega328-328P_Datasheet.pdf

Fig 1. Schematic on Eagle Software.

Fig 2. Board on Eagle Software.

Fig 3. Made the board on the modela MDX 540 Roland.

Fig 4. Modela MDX 540 Roland in action./span>

Fig 5.The final board satschakit.

This time I made three boards due to some machining errors, wrong parameters and soldering mistakes. After all the problems were solved, the third board worked smoothly.

Fig 6. Pinout of the board. The next step was to burn the bootloader on the satschakit. This time I wanted to try new tools, so I used the USBasp for this, and the ide Arduino was version 1.6.4.

Fig 7. Arduino 1.6.4 used to burn the firware on Atmega 328P.

Fig 8. Used Usbasp to burn firmware on the Atmega 328P. The pin connections from UsBasp to satschakit:
Pin 13: SCK
Pin 12: MISO
Pin 11: MOSI
RST, Positive and negative.

Fig 9. The Pin connections to satschakit.

Now I made an extension board for an input device. The temperature sensor LM 35 was chosen as the sensor. This link shows the Data sheet of this sensor.
https://www.mouser.com/ds/2/321/604-00011-LM34-Temperature-Sensor-Datasheet-337154.pdf

Fig 10. The simple extension board.

Fig 11. The Schematic of temperature board.

Fig 12. The program on to Arduino IDE using the LM35 sensor.
The next step was to make the interface in Labview, I learned to use this program and used an example that I found on the web. The goal is to read the signal from the Arduino. I used FTDI to conect Arduino to labview via RS232. The data flows from the sensor to Arduino and to the graphic interface from Labview.

Fig 13. The FTDI allows the flow of information to Labview.
Link to Labview:
http://www.ni.com/es-cr/shop/labview.html


Link to use Labview for serial comunication:
http://www.ni.com/white-paper/7907/es/

On the Labview program, the first panel serve to visualize the control process. The arduino now works as a data acquisition Interface.

Fig 14. Control pannel on Labview.

Fig 15. the program on Labview.

Fig 16. On Labview this part open serial port.

Fig 17. I used a soldering iron to change the temperature that the sensor reads.


Fig 18. Control Panel functioning with the Satschakit and Labview.


**VIDEO**

This video Shows the Control pannel working with Arduino and Laview together.
Right mouse button to play video

Now I tried to make a microcontroller board myself adding an input device and connect it with another tool I wanted to give a try. This time I made a hall effect microcontroller board and connect it with a graphic Interface I made using Processing.

Fig 19. I used FTDI to conect the sensor hall efect with Processing. I used a serial example on processing. the program on the Attiny was the input example for the hall effect from Neil.
The link:
http://academy.cba.mit.edu/classes/input_devices/mag/hello.mag.45.cad

Fig 20. Program On processing based on serial read, this program is an example on processing.


Fig 21. This square change when the magnet is next to hall effect sensor as an activation indicator. The black colour shows no presence of any magnet. and the grey colour when it senses the presence of a magnet.

Fig 22. The Hall effect sensor with the magnet working.

**VIDEO**


Showing the efect from magnet on the hall efect sensor and the processing interface.
Right mouse button to play video

  • Download files here:
    Processing Program
    Labview program.
    Arduino program.