Difference: SolutionsToTheExercises (16 vs. 17)

Revision 172017-12-12 - uli

Line: 1 to 1
 
META TOPICPARENT name="WebHome"

Solutions to the exercises

Line: 99 to 99
 
  • Solutions to exercise 13: the ds1307 Real Time Clock

    These solutions show how to set the real time clock using a complex command line argument interface with getopt_long. Many of the Linux commands are implemented this way. The program, when called without parameters, shows the current date and time, with parameters it allows to set seconds, minutes, hours, day...
https://iotworkshop.africa/pub/Embedded_Systems/SolutionsToTheExercises/rtc.tar.gz
Changed:
<
<
  • Solutions to exercise 9: the at24c32 EEPROM

    We have a little PCB with a ds1307 Real Time Clock and an at24c32 32kbit EEPROM on board. Both devices can be accessed through the I2C bus. These solutions show what needs to be done to read and write the EEPROM. Again the access routines are implemented in a shared library. In this code we do not use pigpio library calls for I2C access but use the device driver implemented for the Linux kernel directly.

>
>
  • Solutions to exercise 9: the at24c32 EEPROM

    We have a little PCB with a ds1307 Real Time Clock and an at24c32 32kbit EEPROM on board. Both devices can be accessed through the I2C bus. These solutions show what needs to be done to read and write the EEPROM. Again the access routines are implemented in a shared library. In this code we do not use pigpio library calls for I2C access but use the device driver implemented for the Linux kernel directly.
    However, a version of the library passing through pigpio is given also, as is a version of readEnigma making calls to pigpio instead of the at24c32 library.
https://iotworkshop.africa/pub/Embedded_Systems/SolutionsToTheExercises/at24c32EEProm.tar.gz
 
  • Solutions to exercise 20: The Heart Rate Monitor

    When trying the LED blink program I was first surprised that the blinking did not work and found out only that that this is because on infrared is employed on the board. Using infrared light has the advantage that visible light from the environment does not disturb the measurement.
    In order to find out find the system works well, I measured the voltage at the output or the photo diode with a multimeter when blinking the diode with a low (2 HZ) frequency.
    Once this worked fine I just had to connect the diode output to a free input of an ADC and the PCF8591 is good enough.
    The code is attached and here is a plot of the results:

    heartBeat.png


    This works nicely on a white man's finger but the black skin of a black man's finger obscures the photo diode that much that the blood color cannot be measured, at least not with the PCF8591 ADC. We should try with the ADS1115 which may solve the problem because of its largely increased resolution.

https://iotworkshop.africa/pub/Embedded_Systems/SolutionsToTheExercises/heartbeat.tar.gz

Line: 138 to 140
 
META FILEATTACHMENT attachment="heartBeat.png" attr="" comment="" date="1510672452" name="heartBeat.png" path="heartBeat.png" size="46220" user="uli" version="1"
META FILEATTACHMENT attachment="ledPython.tar.gz" attr="" comment="" date="1512052067" name="ledPython.tar.gz" path="ledPython.tar.gz" size="1399" user="uli" version="1"
META FILEATTACHMENT attachment="lcdPython.tar.gz" attr="" comment="" date="1512052067" name="lcdPython.tar.gz" path="lcdPython.tar.gz" size="9693" user="uli" version="1"
Added:
>
>
META FILEATTACHMENT attachment="at24c32EEProm.tar.gz" attr="" comment="" date="1513067587" name="at24c32EEProm.tar.gz" path="at24c32EEProm.tar.gz" size="130" user="uli" version="1"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback