NetBurner Analog to Digital Converter MCF5282 ColdFire Microcontroller User’s manual.

Slides:



Advertisements
Similar presentations
Georgia Tech Digital Back-end µHRG interface Curtis Mayberry School of Electrical and Computer Engineering Georgia Institute of Technology January 13 th,
Advertisements

Digital Thermostat and Data Logger Brandon Wagner and David Southwick.
EET 2261 Unit 14 INCOMPLETE Analog-to-Digital Conversion (ADC) & Digital-to-Analog Conversion (DAC)  Read.  Homework #13 and Lab #13 due next week. 
Analog-to-Digital Conversion Terminology analog: continuously valued signal, such as temperature or speed, with infinite possible values in between digital:
ECE 265 – LECTURE 14 Analog Signal Acquisition The A/D converters 5/14/ ECE265.
Khaled A. Al-Utaibi  Digital Vs Analog Signals  Converting an Analog Signal to a Digital One  Reading Analog Sensors with the.
Steering Servo How to control the car heading via a steering servo Team: //noComment Leader : Christian Software Specialist : Matt Hardware Specialist.
PIC16F bit 8-channel Analog-to-Digital Converter.
UniMAP 1 Interfacing DIO ADC Keypad LCD. UniMAP 2 Using I/O ports in C program on Linux machine 1.Need permission to access the port. This is done by.
Introduction of Holtek HT-46 series MCU
ECE 371 – Unit 15 Data Acquisition Systems A/Ds in MC9S12DPS56B Microcontroller.
H. Huang Transparency No.11-1 The 68HC11 Microcontroller Chapter 11: 68HC11 Analog to Digital Converter The 68HC11 Microcontroller Han-Way Huang Minnesota.
Programmable Interrupt Timer Modules PIT0, PIT1, PIT2, PIT3.
IO Controller Module Arbitrates IO from the CCP Physically separable from CCP –Can be used as independent data logger or used in future projects. Implemented.
1 Project supervised by: Dr Michael Gandelsman Project performed by: Roman Paleria, Avi Yona 12/5/2003 Multi-channel Data Acquisition System Mid-Term Presentation.
NetBurner 5282 MCF5282 ColdFire MicroController Interrupt System.
NetBurner 5282 MCF5282 ColdFire MicroController Interrupt System.
ColdFire MCF5282 Universal Asynchronous Receiver/Transmitters (UARTs)
HT46 A/D Type MCU Series Data Memory (Byte) Program Memory HT46R22 (OTP) HT46C22 (Mask) 2Kx Kx16 4Kx HT46R23 (OTP) HT46C23 (Mask) HT46R24.
1 ECE 263 Embedded System Design Lessons 2, 3 68HC12 Hardware Overview, Subsystems, and memory System.
Engineering H192 - Computer Programming The Ohio State University Gateway Engineering Education Coalition Lect 26P. 1Winter Quarter Handy Board Lecture.
NetBurner MOD 5282 Network Development Kit MCF 5282 Integrated ColdFire 32 bit Microcontoller 2 DB-9 connectors for serial I/O supports: RS-232, RS-485,
The 8051 Microcontroller and Embedded Systems
Revised: Aug 1, ECE 263 Embedded System Design Lesson 1 68HC12 Overview.
1 ATD10B8CV2 on MC9SI2C By: Yuchun Huang. 2 ADC ADC Power Supply.
©2008 Pearson Education, Inc., Upper Saddle River, NJ. All rights reserved. This material is protected under all copyright laws as they currently exist.
Digital to Analogue Converter
Microcontroller based system design Asst. Prof. Dr. Alper ŞİŞMAN.
Specview 32 Release 2.5 Enhancements
Prepared by Eng. Musa Alyaman1 Chapter Seven Chapter Seven PIC16F87x.
ADVANCED DIGITAL STETHOSCOPE PHASE I SECOND REVIEW BY E.MURUGA LAKSHMI (ROLL NO:12) Project Guide: Dr. E.JANARTHANAN Department of ECE.
Ethernet Driver Changes for NET+OS V5.1. Design Changes Resides in bsp\devices\ethernet directory. Source code broken into more C files. Native driver.
1 LHO 13 The 8051CF020 and the University Daughter Card.
EEE527 Embedded Systems Lecture 10B:Chapter 11 Analogue to Digital Convertors (ADCs) (version 2: 25/11/13, see after slide 20 Ian McCrumRoom 5B18, Tel:
Dennis Ritchie 1972 AT & T Bell laboratories (American Telephone and Telegraph) USA 1www.gowreeswar.com.
Universal Asynchronous Receiver/Transmitter (UART)
Renesas Electronics Corporation © 2010 Renesas Electronics America Inc. All rights reserved. RX 12 Bit Analog-to-Digital Converter A Rev /1/10.
Chapter 2 Introducing the PIC Mid-Range Family and the 16F84A The aims of this chapter are to introduce: The PIC mid-range family, in overview The overall.
Suleyman Demirel University CSS340 Microprocessor Systems – Lecture 2 ATMEGA328P ARCHITECTURE ANALOG INPUTS.
Engineering H192 - Computer Programming Gateway Engineering Education Coalition Lect 26P. 1Winter Quarter Handy Board Lecture 26.
Example 11 Analog-to-Digital Converter Lecture L5.1.
Analog Capture- Port E. Digital to Analog and Analog to Digital Conversion D/A or DAC and A/D or ADC.
Microcontroller based system design Asst. Prof. Dr. Alper ŞİŞMAN.
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction Purpose  This course provides an introduction to the peripheral functions.
Variables in C Topics  Naming Variables  Declaring Variables  Using Variables  The Assignment Statement Reading  Sections
BASIC STRUCTURE OF PLC.
ECE 447: Lecture 2 Internal Input/Output Devices A/D Converter.
1 Neutron Monitor Workshop 2(B): Neutron Monitor Digital Electronics Mahidol University June 26, 2009 Paul Evenson University of Delaware Cosray at McMurdo.
STEERING TEAM: DRIFT KINGS ELEAZAR LUCIANO MATT HART SHANE MILLS STEVE GILLILAND.
ARM Embedded Programming Lecture 4 Accessing Memory Mapped Registers.
ECE 101 Exploring Electrical Engineering Chapter 7 Data Acquisition Herbert G. Mayer, PSU Status 11/30/2015 Derived with permission from PSU Prof. Phillip.
ADC 1 Analog to Digital Converter. ADC 2 ADC Features n General Features -Supports 8 or 10-bit resolution Modes, -Track period fully programmable up to.
CEng3361/18 CENG 336 INT. TO EMBEDDED SYSTEMS DEVELOPMENT Spring 2007 Recitation 01.
CEng3361 CENG 336 INT. TO EMBEDDED SYSTEMS DEVELOPMENT Spring 2011 Recitation 06.
1 Chapter 1: Introduction Appendix A: Binary and Hexadecimal Tutorial Assembly Language for Intel-Based Computers, 3rd edition Kip R. Irvine.
Chapter 12: Analog-to-Digital Converter
Fundamentals of Computer Engineering
Val Manes Department of Math & Computer Science
Microcontroller basics
SIS3316 external clock D. R. Bett D. R. Bett FONT Meeting 9 May 2014.
INTRODUCTION TO MICROPROCESSORS
The Arduino Microcontroller: Atmel AVR Atmega 328
Introduction to Microprocessors and Microcontrollers
Future Designs, Inc. Your Development Partner
8051 Single Board Computer (SBC) Version 1.0
Power System TEAM SHOCK Team Leader: Matt Uhrine
ECE 3567 Microcontrollers Dr. Gregg J Chapman
Moving Arrays -- 2 Completion of ideas needed for a general and complete program Final concepts needed for Final DMA.
ANALOG TO DIGITAL CONVERTER (ATD).
Programming Language C Language.
Presentation transcript:

NetBurner Analog to Digital Converter MCF5282 ColdFire Microcontroller User’s manual

NetBurner Board

NetBurner Connector J3 – ADC input/output

ADC Pins C:\Nburn\docs\platform\Mod5282.html {NetBurner Carrier Board Schematic (pdf)}

NetBurner Memory map C:\Nburn\docs\platform\Mod5282.html {Mod5282 Memory Map}

Port QA

Port QB

QPR: See Table27-7

See Table 27-7

See Table 27-9

Status Registers See Section for details

See Section for details

See Section for details

NetBurner Memory map C:\Nburn\docs\platform\Mod5282.html {Mod5282 Memory Map}

C++ sim Object of type MCF5282 C++ Header File is: C:\Nburn\MOD5282\system\sim5282.h /********************************************************************** * * MCF5282 ColdFire Assembly Header File * * **********************************************************************/ #define MBASE 0x /* Module Base Address*/ extern volatile mcf5282 sim; /* main struct */ typedef struct {... qadcstruct qadc; /* 1x >1x1903FF */... } mcf5282 ; typedef struct { /* queued analog-to-digital converter module */... } qadcstruct ;

ADC Struct typedef struct { /* queued analog-to-digital converter module */ vuword qadcmcr; /* > qadc module configuration register */ vubyte pack00[4]; /* > */ vubyte portqa; /* > (qa) port data register */ vubyte portqb; /* > (qb) port data register */ vubyte ddrqa; /* > port qa data direction register */ vubyte ddrqb; /* > port qb data direction register */ vuword qacr0; /* 19000a->19000b qadc control register 0 */ vuword qacr1; /* 19000c->19000d qadc control register 1 */ vuword qacr2; /* 19000e->19000f qadc control register 2 */ vuword qasr0; /* > qadc status register 0 */ vuword qasr1; /* > qadc status register 1 */ vubyte pack01[491]; /* >1901ff */ vuword ccw[64]; /* > conversion command word table */ vuword rjurr[64]; /* > right-justified unsigned result register */ vuword ljsrr[64]; /* > left-justified signed result register */ vuword ljurr[64]; /* > left-justified unsigned result register */ } qadcstruct ;

Mod5282 A/D Example – C:\Nburn\docs\platform\Mod5282.html Set up A/D to Continuously sample all 8 channels and store the results /*************************************************** * * Copyright 2003, 2004, 2005 NetBurner, Inc. * ALL RIGHTS RESERVED * * Permission is hereby granted to purchasers of * NetBurner Hardware to use or modify this * computer program for any use as long as the * resultant program is only executed on NetBurner * provided hardware. * * No other rights to use this program or its * derivatives in part or in whole are granted. * ********************************************************/ #include "predef.h" #include extern "C" { void UserMain(void * pd); } /* Set up A/D to continuously sample all 8 channels and store the results */ /* See the Motorola 5282 User Manual - Chapter 27 for additional information. */ void InitializeQADC() { sim.qadc.qadcmcr=0x8000; sim.qadc.portqa=0; sim.qadc.portqb=0; sim.qadc.ddrqa=0; sim.qadc.ddrqb=0; sim.qadc.qacr0=0x7F; /* Divide by Mhz -> 500Khz AD clock */ sim.qadc.qacr1=0x1100; /* Continious software scans in queue 1 */ sim.qadc.qacr2=11; /*disabled queue 2 with Queue 1 ending at position 11 */ sim.qadc.qasr0=0; sim.qadc.qadcmcr=0x0000; asm(" nop"); sim.qadc.ccw[0]=0xC0; /*Convert channel 0. See the Motorola 5282 User Manual - Table */ sim.qadc.ccw[1]=0xC1; sim.qadc.ccw[2]=0xC2; sim.qadc.ccw[3]=0xC3; sim.qadc.ccw[4]=0xF4; sim.qadc.ccw[5]=0xF5; sim.qadc.ccw[6]=0xF7; sim.qadc.ccw[7]=0xF8; sim.qadc.ccw[8]=0xFC; sim.qadc.ccw[9]=0xFD; /* Should return a measured 0 */ sim.qadc.ccw[10]=0xFE; /* Should return a measured 1023 or max */ sim.qadc.ccw[11]=0xFF; /* Should return half scale or 512 */ sim.qadc.qacr1=0x1100; /* Continious software scans in queue 1 */ } /* Return the converted samples See Motorola 5282 User Manual Section */ WORD GetQADC(int ch) { return sim.qadc.rjurr[ch]; } void UserMain(void * pd) { InitializeStack(); if (EthernetIP==0)GetDHCPAddress(); OSChangePrio(MAIN_PRIO); EnableAutoUpdate(); /* Start up the A/D system */ InitializeQADC(); iprintf("Application started\n"); while (1) { OSTimeDly(20); iprintf("A/D values. Floating point voltage assumes a 5.0V reference\r\n"); for (int i=0; i<8; i++) { WORD v=GetQADC(i); float f=v; f=f*5.0/1024.0; printf("AD[%d] = 0x%03X or %4d or %4.2fV \r\n",i,v,v,f); } /******************************************************************** End of the NetBurner Mod5282 A/D Example Program *********************************************************************/