Difference between revisions of "ME 333 Readings, Videos, and Sample Code"
From Mech
Jump to navigationJump to searchNickMarchuk (talk | contribs) |
NickMarchuk (talk | contribs) |
||
Line 76: | Line 76: | ||
===Chapter 7: Digital Input and Output=== |
===Chapter 7: Digital Input and Output=== |
||
** [[Media:DIO_plib.c|DIO_plib.c]] |
|||
** [[Media:DIO_sfrs.c|DIO_sfrs.c]] |
|||
---- |
---- |
||
===Chapter 8: Counters / Timers=== |
===Chapter 8: Counters / Timers=== |
||
** [[Media:TMR_5Hz.c|TMR_5Hz.c]] |
|||
** [[Media:TMR_external_count.c|TMR_external_count.c]] |
|||
** [[Media:TMR_pulse_duration.c|TMR_pulse_duration.c]] |
|||
---- |
---- |
||
===Chapter 9: Output Compare=== |
===Chapter 9: Output Compare=== |
||
** [[Media:OC_analog_out.c|OC_analog_out.c]] |
|||
** [[Media:OC_PWM_plib.c|OC_PWM_plib.c]] |
|||
** [[Media:OC_PWM_sfrs.c|OC_PWM_sfrs.c]] |
|||
** [[Media:OC_signal.m|OC_signal.m]] |
|||
---- |
---- |
||
===Chapter 10: Analog Input=== |
===Chapter 10: Analog Input=== |
||
** [[Media:ADC_Read2.c|ADC_Read2.c]] |
|||
---- |
---- |
||
Line 105: | Line 115: | ||
===Chapter 12: SPI Communication=== |
===Chapter 12: SPI Communication=== |
||
** [[Media:SPI_loopback.c|SPI_loopback.c]] |
|||
** [[Media:SPI_pic_to_pic.c|SPI_pic_to_pic.c]] |
|||
** [[Media:SPI_DAC_MCP4922.c|SPI_DAC_MCP4922.c]] |
|||
** [[Media:SPI_ADC_MCP3008.c|SPI_ADC_MCP3008.c]] |
|||
** [[Media:SPI_SRAM_23K256.c|SPI_SRAM_23K256.c]] |
|||
** [[Media:SPI_microSDcard.c|SPI_microSDcard.c]] |
|||
** [[Media:SPI_accelerometer_ADXL362.c|SPI_accelerometer_ADXL362.c]] |
|||
---- |
---- |
||
===Chapter 13: I2C Communication=== |
===Chapter 13: I2C Communication=== |
||
** [[Media:I2C_loopback.c|I2C_loopback.c]] |
|||
** [[Media:I2C_pic_to_pic.c|I2C_pic_to_pic.c]] |
|||
** [[Media:I2C_DAC_MAX518.c|I2C_DAC_MAX518.c]] |
|||
** [[Media:I2C_ADC_NAU7802.c|I2C_ADC_NAU7802.c]] |
|||
** [[Media:I2C_SRAM_PCF8570P.c|I2C_SRAM_PCF8570P.c]] |
|||
** [[Media:I2C_accelerometer_LSM303DLHC.c|I2C_accelerometer_LSM303DLHC.c]] |
|||
---- |
---- |
||
===Chapter 14: USB=== |
===Chapter 14: USB=== |
||
** [[Media:USB_HID.zip|USB_HID.zip]] |
|||
** [[Media:USB_CDC.zip|USB_CDC.zip]] |
|||
** [[Media:USB_thumbDrive.zip|USB_thumbDrive.zip]] |
|||
---- |
---- |
||
===Chapter 15: Input Capture=== |
===Chapter 15: Input Capture=== |
||
** [[Media:IC_loopbackPWM.c|IC_loopbackPWM.c]] |
|||
** [[Media:IC_readRemoteControl.c|IC_readRemoteControl.c]] |
|||
---- |
---- |
||
===Chapter 16: Comparator=== |
===Chapter 16: Comparator=== |
||
** [[Media:COMP_internal.c|COMP_internal.c]] |
|||
** [[Media:COMP_output16values.c|COMP_output16values.c]] |
|||
** [[Media:COMP_INT2values.c|COMP_INT2values.c]] |
|||
---- |
---- |
||
===Chapter 17: Watchdog Timer=== |
===Chapter 17: Watchdog Timer=== |
||
** [[Media:WDT_enableReset.c|WDT_enableReset.c]] |
|||
** [[Media:WDT_checkPreviousReset.c|WDT_checkPreviousReset.c]] |
|||
---- |
---- |
||
===Chapter 18: Storing Data in Flash Memory=== |
===Chapter 18: Storing Data in Flash Memory=== |
||
** [[Media:FLASH_write.c|FLASH_write.c]] |
|||
---- |
---- |
||
===Chapter 19: Power Saving=== |
===Chapter 19: Power Saving=== |
||
** [[Media:PWR_sleep.c|PWR_sleep.c]] |
|||
---- |
---- |
||
===Chapter 20: Real-time Clock and Calendar=== |
===Chapter 20: Real-time Clock and Calendar=== |
||
** [[Media:RTCC_set.c|RTCC_set.c]] |
|||
---- |
---- |
||
===Chapter 21: Controller Area Network (CAN)=== |
===Chapter 21: Controller Area Network (CAN)=== |
||
** [[Media:CAN_pic_to_pic.c|CAN_pic_to_pic.c]] |
|||
---- |
---- |
||
===Chapter 22: Direct Memory Access=== |
===Chapter 22: Direct Memory Access=== |
||
** [[Media:DMA_adc.c|DMA_adc.c]] |
|||
** [[Media:DMA_spi.c|DMA_spi.c]] |
|||
---- |
---- |
Revision as of 13:06, 16 December 2013
Readings, videos, exercises, and sample code for ME 333 Introduction to Mechatronics.
Appendix: A Crash Course in C
Reading: A Crash Course in C
Videos:
- Writing your first program in C, HelloWorld.c (5:09). Chapter A.1. Exercises: 1.
- Differences between C and MATLAB (7:30). Chapter A.2. Exercises: 2, 3.
- Binary and hexadecimal (Base 2 and 16) (4:47). Chapter A.3.1. Exercises: 4, 6.
- Data types (5:30). Chapter A.3.1. Exercises: 8, 10.
- Using the data types (3:49). Chapter A.3.1. Exercises: 11.
- Representations of data types (5:15). Chapter A.3.1. Exercises: 12, 13.
- Pointer basics (5:54). Chapter A.3.2. Exercises: 14, 15.
- Sample program: printout.c (5:55). Chapter A.4. Exercises: 16 (not covered in video, reading only) 17, 18.
- Sample program: datasizes.c (2:57). Chapter A.4. Exercises: 9.
- Sample program: overflow.c (2:43). Chapter A.4. Exercises: 19.
- Sample program: typecast.c (5:43). Chapter A.4. Exercises: 20.
- invest.c, part 1/5: intro to a typical C program (4:18). Chapter A.4. Exercises: 23.
- invest.c, part 2/5: overview (3:58). Chapter A.4. Exercises: 24, 25.
- invest.c, part 3/5: sections 1-4: program comments, preprocessor commands, new data type definitions, and global variables (4:48). Chapter A.4. Exercises: 26.
- invest.c, part 4/5: sections 5-6: helper function prototypes and the main function (4:40). Chapter A.4.
- invest.c, part 5/5: section 7: helper functions (7:42). Chapter A.4. Exercises: 28-30, 32, 33 (some material covered in reading only).
Sample Code:
- Section A.1: HelloWorld.c
- Section A.4: printout.c, datasizes.c, overflow.c, typecast.c, invest.c
- Section A.4.16: helper.h, helper.c, main.c
- Problems, Section A.5: bubble.c, lights.c, hexdump.c
Chapter 1: Quickstart
- Section 1.3:
Chapter 2: Looking Under the Hood: Hardware
Chapter 3: Looking Under the Hood: Software
Chapter 4: Using Libraries
- Section 4.5:
Chapter 5: Time and Space
- Section 5.1:
Chapter 6: Interrupts
- Section 6.1: