Tel: Fax:

Size: px
Start display at page:

Download "Tel: Fax:"

Transcription

1 /****************************************************************************** Title: RFM22 transmitter demo program Current version: V1.2 Function: Package send Demo Processor PIC16F690 DIP-20 Clock: internal 8M. Operate frequency: 434MHz Data rate: 2.4kbps modulation: FSK deviation: 45K bandwidth: 94.8K frame mode: PH + FIFO payload 0x30, 0x31...0x3f, 0x78(chksum) Author : Simon.Yang Company: HopeRF microelectroni Contact: Date: The example is only for your reference. ******************************************************************************/ #include<pic.h> typedef unsigned char uchar; typedef unsigned int uint; const uchar tx_buf[17] = 0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,0x78; // ch8 is 140 #define RF22_PWRSTATE_READY 01 #define RF22_PWRSTATE_TX 0x09 1

2 #define RF22_PACKET_SENT_INTERRUPT 04 #define RF22_PWRSTATE_POWERDOWN 00 RF22 TX Program V1.2 #define nirq RA2 #define nsel RC6 #define SDO RC7 #define SDI RB4 #define LED_RED RB5 #define SCK RB6 #define TXEN RA4 #define RXEN RA5 uchar count_50hz; uchar ItStatus1, ItStatus2; typedef struct uchar reach_1s : 1; FlagType; FlagType Flag; uchar read_8bit_data(void); void to_tx_mode(void); void to_ready_mode(void); void send_8bit_data(uchar i); void send_read_address(uchar i); void spi_write(uchar address, uchar data); void RF22_init_parameter(void); void delay_50ms(void); void delay_5ms(void); void delay_1ms(void); void port_init(void); void power_on_delay(void); uchar spi_read(uchar address); void Write0( void ); void Write1( void ); void timer2_init(void); void Write8bitcommand(uchar command); void to_sleep_mode(void); CONFIG(0x3F04); //***************************************************************************** 2

3 void main() uchar i,j,chksum; OSCCON = 0X70; // 8M crystal WDTCON = 0X00; power_on_delay(); port_init(); timer2_init(); count_50hz = 0; Flag.reach_1s = 0; INTCON = 0xc0; // enable interrupt RF22_init_parameter(); while(1) //to_sleep_mode(); //enter sleep mode if(flag.reach_1s) Flag.reach_1s = 0; to_tx_mode(); // TRANSIMITTE DATA //***************************************************************************** void Write0( void ) SDI=0; SCK=1; void Write1( void ) Tel: Fax: sales@hoperf.com 3

4 SDI=1; SCK=1; void Write8bitcommand(uchar command) // keep sel to low uchar n=8; nsel = 1; nsel=0; while(n--) if(command&0x80) Write1(); else Write0(); command = command << 1; void delay_50ms(void) uchar j; for(j = 0; j<10; j++) delay_5ms(); void delay_5ms(void) int i; for(i = 0; i<650; i++) // 85*5 ; void delay_1ms(void) 4

5 uchar i; for(i = 0; i<130; i++) ; void timer2_init(void) T2CON = 0x7f; // timer2 on and 16 pre, postscale PR2 = 156; // 50hZ, 4m/4/16/16/50 TMR2IE = 1; void interrupt ISR_timer(void) uchar i; if(tmr2if) count_50hz++; if(count_50hz==50) // REACH 1S count_50hz=0; Flag.reach_1s = 1; TMR2IF=0; void port_init(void) ANSEL = 0; ANSELH = 0; WPUA = 0; // NO PULL UP IOCA = 0; // NO INTERRUPT ON CHANGE TRISA = 0x0f; // all ra0-- ra3 input, RA4,5 OUTPUT TRISB = 0x80; // rb7 input WPUB = 0x00; // no pull up TRISC = 0b ; // pc7,5,3,2,1,0 input RC4=0; LED_RED = 0; TXEN = RXEN = 0; 5

6 void power_on_delay(void) uint i; for(i = 0; i<1000; i++) delay_1ms(); uchar spi_read(uchar address) uchar result; send_read_address(address); result = read_8bit_data(); nsel = 1; return(result); void RF22_init_parameter(void) ItStatus1 = spi_read(0x03); // read status, clear interrupt ItStatus2 = spi_read(0x04); spi_write(0x06, 0x00); // no wakeup up, lbd, spi_write(0x07, RF22_PWRSTATE_READY); // disable lbd, wakeup timer, use internal 32768,xton = 1; in ready mode spi_write(0x09, 0x7f); // c = 12.5p spi_write(0x0a, 0x05); spi_write(0x0b, 0xf4); // gpio0 for received data output spi_write(0x0c, 0xef); // gpio 1 for clk output spi_write(0x0d, 0xfd); // gpio 2 micro-controller clk output spi_write(0x0e, 0x00); // gpio 0, 1,2 NO OTHER FUNCTION. spi_write(0x70, 0x20); // disable manchest //case RATE_24K: // 2.4k spi_write(0x6e, 0x13); spi_write(0x6f, 0xa9); //PH+FIFO spi_write(0x30, 0x8c); // enable packet handler, msb first, enable crc, // 0x31 only readable spi_write(0x32, 0xff); // 0x32address enable for headere byte 0, 1,2,3, receive header check 6

7 for byte 0, 1,2,3 spi_write(0x33, 0x42); // header 3, 2, 1,0 used for head length, fixed packet length, synchronize word length 3, 2, spi_write(0x34, 64); // 64 nibble = 32byte preamble spi_write(0x36, 0x2d); // synchronize word spi_write(0x37, 0xd4); spi_write(0x38, 0x00); spi_write(0x39, 0x00); spi_write(0x3a, 's'); // tx header spi_write(0x3b, 'o'); spi_write(0x3c, 'n'); spi_write(0x3d, 'g'); spi_write(0x3e, 17); // total tx 17 byte // 0x52, 53, 54, 55 set to default // 0x x6c?????????????????????????? spi_write(0x6d, 0x0f); // set power max power spi_write(0x79, 0x0); // no hopping spi_write(0x7a, 0x0); // no hopping spi_write(0x71, 0x22); // Gfsk, fd[8] =0, no invert for Tx/Rx data, fifo mode, txclk -->gpio spi_write(0x72, 0x38); // frequency deviation setting to 45k = 72*625 spi_write(0x73, 0x0); spi_write(0x74, 0x0); // no offset //band 434 spi_write(0x75, 0x53); // hbsel = 0, sbsel =1???, fb = 19 spi_write(0x76, 0x64); // 25600= 0x6400 for 434Mhz spi_write(0x77, 0x00); void spi_write(uchar address, uchar data) address = 0x80; Write8bitcommand(address); send_8bit_data(data); nsel = 1; void send_read_address(uchar i) i &= 0x7f; 7

8 Write8bitcommand(i); void send_8bit_data(uchar i) uchar n = 8; while(n--) if(i&0x80) Write1(); else Write0(); i = i << 1; uchar read_8bit_data(void) uchar Result, i; RF22 TX Program V1.2 Result=0; for(i=0;i<8;i++) //read fifo data byte Result=Result<<1; SCK=1; if(sdo) Result =1; return(result); void to_tx_mode(void) uchar i; to_ready_mode(); 8

9 //delay_50ms(); RXEN = 0; TXEN = 1; spi_write(0x08, 0x03); // disable AUTO TX MODE, enble multi packet clear fifo spi_write(0x08, 0x00); // disable AUTO TX MODE, enble multi packet, clear fifo // ph +fifo mode spi_write(0x34, 64); // 64 nibble = 32byte preamble spi_write(0x3e, 17); // total tx 17 byte for (i = 0; i<17; i++) spi_write(0x7f, tx_buf[i]); spi_write(0x05, RF22_PACKET_SENT_INTERRUPT); ItStatus1 = spi_read(0x03); //read the Interrupt Status1 register ItStatus2 = spi_read(0x04); spi_write(0x07, RF22_PWRSTATE_TX); // to tx mode while(nirq); to_ready_mode(); RXEN = 0; TXEN = 0; LED_RED= 1; delay_50ms(); LED_RED= 0; void to_ready_mode(void) ItStatus1 = spi_read(0x03); ItStatus2 = spi_read(0x04); spi_write(0x07, RF22_PWRSTATE_READY); void to_sleep_mode(void) TXEN = RXEN = 0; LED_RED = 0; spi_write(0x07, RF22_PWRSTATE_READY); ItStatus1 = spi_read(0x03); //read the Interrupt Status1 register ItStatus2 = spi_read(0x04); spi_write(0x07, RF22_PWRSTATE_POWERDOWN); while(1) 9

10 ; RF22 TX Program V1.2 Tel: Fax:

NOTICE: 1, the timing for Start, Stop, ACK, NACK, write and read is same as I2C

NOTICE: 1, the timing for Start, Stop, ACK, NACK, write and read is same as I2C DPS01 USER GUIDE DPS01 is a module which integrated digital atmospheric pressure altitude Temperature Compass weather forecast. No external components required It is a complete sensing system with on-chip

More information

ECE Homework #10

ECE Homework #10 Timer 0/1/2/3 ECE 376 - Homework #10 Timer 0/1/2/3, INT Interrupts. Due Wednesday, November 14th, 2018 1) Write a program which uses INT and Timer 0/1/2/3 interrupts to play the cord C#major for 1.000

More information

Timer0..Timer3. Interrupt Description Input Conditions Enable Flag

Timer0..Timer3. Interrupt Description Input Conditions Enable Flag Timer0..Timer3 Timers are pretty useful: likewise, Microchip provides four different timers for you to use. Like all interrupts, you have to Enable the interrupt, Set the conditions of the interrupt, and

More information

RF4431 wireless transceiver module

RF4431 wireless transceiver module RF4431 wireless transceiver module 1. Description RF4431 adopts Silicon Labs Si4431 RF chip, which is a highly integrated wireless ISM band transceiver chip. Extremely high receive sensitivity (-121 dbm)

More information

RF67 Communication Example

RF67 Communication Example RF67 Communication Example AN-2004 VER1.1 This chapter will guide the user to carry out RFM67 and RFM219 transmitting and receiving communication experiment through HopeDuino, at the same time display

More information

User Manual of NRF24L01 Breakout Board

User Manual of NRF24L01 Breakout Board User Manual of NRF24L01 Breakout Board LinkSprite Technologies, Inc December 2010 1 / 9 1. Introduction 1. 2.4GHz ISM frequency band 2. Max data rate 2Mbps, GFSK modulation, robust anti-interference, especially

More information

RF4432 wireless transceiver module

RF4432 wireless transceiver module RF4432 wireless transceiver module 1. Description RF4432 adopts Silicon Lab Si4432 RF chip, which is a highly integrated wireless ISM band transceiver chip. Extremely high receive sensitivity (-121 dbm)

More information

Hardware interface and protocol of data exchange with mobile beacon via USB, UART and SPI interfaces.

Hardware interface and protocol of data exchange with mobile beacon via USB, UART and SPI interfaces. Hardware interface and protocol of data exchange with mobile beacon via USB, UART and SPI interfaces. Version 2016.03.07 Valid for firmware v4.07 and newer To get location data from mobile beacon (hedgehog),

More information

Speed Control of a DC Motor using Digital Control

Speed Control of a DC Motor using Digital Control Speed Control of a DC Motor using Digital Control The scope of this project is threefold. The first part of the project is to control an LCD display and use it as part of a digital tachometer. Secondly,

More information

Timer1 Capture Mode:

Timer1 Capture Mode: Timer1 Capture Mode: Interrupt Description Input Conditions Enable Flag Timer 1 Trigger after N events N = 1.. 2 19 100ns to 0.52 sec RC0 TMR1CS = 1 TMR1IF Timer 1 Capture Mode 1 Timer 1 Capture Mode 2

More information

/*Algorithm: This code display a centrifuge with five variable speed RPM by increaseing */

/*Algorithm: This code display a centrifuge with five variable speed RPM by increaseing */ /*Algorithm: This code display a centrifuge with five variable speed RPM by increaseing */ /*the speed the cell which are less dense can float and the cell that are denser can sink*/ /*the user has five

More information

CMT2119A & CMT2219A Communication Example

CMT2119A & CMT2219A Communication Example CMT2119A & CMT2219A Communication Example This chapter will guide the user to carry out the communication experiment on a pair of single transmitting and single receiving chips CMT2119A and CMT2219A. CMT2119A

More information

RF01 programming guide

RF01 programming guide RF01 programming guide 1. Brief description RF01 is a low cost FSK receive IC witch integrated all RF functions in a single chip. It only need a MCU, a crystal, a decouple capacitor and antenna to build

More information

Interrupts on PIC18F252 Part 2

Interrupts on PIC18F252 Part 2 Interrupts on PIC18F252 Part 2 Following pages list Special Function Registers (SFRs) involved in interrupt configuration and operation on PIC18F252 microcontroller. (Copied from Microchip s PIC18Fxx2

More information

More Fun with Timer Interrupts

More Fun with Timer Interrupts More Fun with Timer Interrupts Chords Objective: Play a musical chord each time you press a button: Button RC0 RC1 RC2 Timer Timer0 Timer1 Timer3 RB0 A3 C4 E4 RB1 B3 D4 F4 RB2 C4 E4 G4 Calculations: Assume

More information

Timer2 Interrupts. NDSU Timer2 Interrupts September 20, Background:

Timer2 Interrupts. NDSU Timer2 Interrupts September 20, Background: Background: Timer2 Interrupts The execution time for routines sometimes needs to be set. This chapter loops at several ways to set the sampling rate. Example: Write a routine which increments an 8-bit

More information

RF69 Communication Example

RF69 Communication Example RF69 Communication Example AN-2001 VER1.1 This chapter will guide the user to carry out a pair of RF69 transmitting and receiving communication experiment through HopeDuino. RF69 is a main push wireless

More information

RFIC TX/RX Configuration

RFIC TX/RX Configuration RFIC TX/RX Configuration RFIC TX/RX Configuration 01/19/17 1 of 10 www.murata.com RXC101 Configuration When the RXC101 is configured in microcontroller mode, data can be received in three ways; directly

More information

Protocol of data exchange with modem via USB interface Version

Protocol of data exchange with modem via USB interface Version Protocol of data exchange with modem via USB interface Version 2017.12.19 - Modem connects to USB-host as USB device of CDC class (virtual COM port in Windows, ttyusb or ttyacm in Linux) - Because real

More information

EE6008-Microcontroller Based System Design Department Of EEE/ DCE

EE6008-Microcontroller Based System Design Department Of EEE/ DCE UNIT- II INTERRUPTS AND TIMERS PART A 1. What are the interrupts available in PIC? (Jan 14) Interrupt Source Enabled by Completion Status External interrupt from INT INTE = 1 INTF = 1 TMR0 interrupt T0IE

More information

PL1167. Low Power High Performance Single Chip 2.4GHz Transceiver. Product Description: Key Features: Applications: Pin Configuration:

PL1167. Low Power High Performance Single Chip 2.4GHz Transceiver. Product Description: Key Features: Applications: Pin Configuration: Low Power High Performance Single Chip 2.4GHz Transceiver Product Description: is a piece of true low power high performance single chip 2.4GHz transceiver, which is designed for operation in the world

More information

Building a wireless sensor network with use of RFM 12 modules - data exchange between nodes

Building a wireless sensor network with use of RFM 12 modules - data exchange between nodes 438 Measurement Automation Monitoring, Sep. 2015, vol. 61, no. 09 Damian MAZUR 1, Piotr MACIĄG 2, Paweł KIELAN 3 1 RZESZOW UNIVERSITY OF TECHNOLOGY, DEPARTMENT OF ELECTRICAL AND COMPUTER FUNDAMENTALS,

More information

MM Update for A3222Q56

MM Update for A3222Q56 MM Update for A3222Q56 New Features: SPI-A3222 Interface; I2C to SHA256 Special Channel; I2C Data Interface; Support Firmware Reload Protocol; DNA Read Interface; 1. alink 1.1 FSM IDLE FIFO Chip_num WORK

More information

Chapter 11: Interrupt On Change

Chapter 11: Interrupt On Change Chapter 11: Interrupt On Change The last two chapters included examples that used the external interrupt on Port C, pin 1 to determine when a button had been pressed. This approach works very well on most

More information

EET203 MICROCONTROLLER SYSTEMS DESIGN Serial Port Interfacing

EET203 MICROCONTROLLER SYSTEMS DESIGN Serial Port Interfacing EET203 MICROCONTROLLER SYSTEMS DESIGN Serial Port Interfacing Objectives Explain serial communication protocol Describe data transfer rate and bps rate Describe the main registers used by serial communication

More information

Interrupts on PIC18F252 Part 2. Interrupts Programming in C Language

Interrupts on PIC18F252 Part 2. Interrupts Programming in C Language Interrupts on PIC18F252 Part 2 Interrupts Programming in C Language Programming interrupts in C language using XC8 compiler is significantly simplified compared to C18 compiler. This note explains the

More information

nrf 24E1 Figure 1: Wireless 2.4GHz mouse/keyboard application

nrf 24E1 Figure 1: Wireless 2.4GHz mouse/keyboard application USB MCU nrf 2401 APPLICATION NOTE Frequency Agility Protocol for nrf24xx nan24-07 1. General This application note describes the low-level. This is a protocol that gives protection against disturbing traffic

More information

EM RF Transceiver. - Framer and Digital Interface Control

EM RF Transceiver. - Framer and Digital Interface Control Application Notes EM198810 RF Transceiver - Framer and igital Interface Control Introduction This Application Note describes the detailed packet handling details pertaining to the Elan EM198810. For the

More information

C:\CYGNAL\Examples\C8051F02x\C\Edu_Board_Source_Code\Magcard.c

C:\CYGNAL\Examples\C8051F02x\C\Edu_Board_Source_Code\Magcard.c Magcard.c Author: Baylor Electromechanical Systems Operates on an external 18.432 MHz oscillator. Target: Cygnal Educational Development Board / C8051F020 Tool chain: KEIL C51 6.03 / KEIL EVAL C51 This

More information

LoRa Communication Example

LoRa Communication Example LoRa Communication Example AN-2003 VER1.1 This chapter will guide the user to carry out a pair of LoRa transmitting and receiving communication experiment through HopeDuino. LoRa is a unique spread spectrum

More information

#include <stdio.h> // // Global CONSTANTS

#include <stdio.h> // // Global CONSTANTS Distance.c Author: Baylor Electromechanical Systems Operates on an external 18.432 MHz oscillator. Target: Cygnal Educational Development Board / C8051F020 Tool chain: KEIL C51 6.03 / KEIL EVAL C51 Utilizes

More information

EE 354 September 16, 2016 C Sample Programs

EE 354 September 16, 2016 C Sample Programs EE 354 September 16, 2016 C Sample Programs //DataArray /* This program creates an array of data in code memory * that is 32 bytes long. Fill this array with the ascii codes for * the capital letters plus

More information

ESP8266 Application Note Firmware Download Protocol

ESP8266 Application Note Firmware Download Protocol ESP8266 Application Note Firmware Download Protocol Version 1.0 Copyright 2016 About This Guide This document introduces ESP8266 firmware download protocol with a structure as follows. Chapter Title Subject

More information

Device: MOD This document Version: 1.0. Matches module version: v3 [29 June 2016] Date: 23 October 2017

Device: MOD This document Version: 1.0. Matches module version: v3 [29 June 2016] Date: 23 October 2017 Device: MOD-1025 This document Version: 1.0 Matches module version: v3 [29 June 2016] Date: 23 October 2017 Description: UART (async serial) to I2C adapter module MOD-1025 v3 datasheet Page 2 Contents

More information

Demo Kit User Manual

Demo Kit User Manual RFM12BP Demo Kit User Manual HOPE MICROELECTRONICS CO.,LTD Add: 4/F, Block B3, East Industrial Area, Huaqiaocheng, Shenzhen, Guangdong, China Tel: 86-755-82973805 Fax: 86-755-82973550 Email: sales@hoperf.com

More information

* File: 8x8_matrix_vinyl.c. * Author: Phil Glazzard. * Created on 16 August 2016, 17:59. /* This design drives five 8x8 common cathode LED matrices

* File: 8x8_matrix_vinyl.c. * Author: Phil Glazzard. * Created on 16 August 2016, 17:59. /* This design drives five 8x8 common cathode LED matrices /* * File: 8x8_matrix_vinyl.c * Author: Phil Glazzard * * Created on 16 August 2016, 17:59 */ /* This design drives five 8x8 common cathode LED matrices * via MAX7219 constant current drivers using SPI

More information

Serial Peripheral Interface (SPI)

Serial Peripheral Interface (SPI) Serial Peripheral Interface (SPI) MSP432 SPI eusci = enhanced Universal Serial Communications Interface 2 tj MSP432 SPI ARM (AMBA Compliant) 7/8 bit transmission Master/Slave LSB/MSB first Separate RX/TX

More information

Chapter 9. Input/Output (I/O) Ports and Interfacing. Updated: 3/13/12

Chapter 9. Input/Output (I/O) Ports and Interfacing. Updated: 3/13/12 Chapter 9 Input/Output (I/O) Ports and Interfacing Updated: 3/13/12 Basic Concepts in I/O Interfacing and PIC18 I/O Ports (1 of 2) I/O devices (or peripherals) such as LEDs and keyboards are essential

More information

Dept. of Computer Engineering Final Exam, First Semester: 2016/2017

Dept. of Computer Engineering Final Exam, First Semester: 2016/2017 Philadelphia University Faculty of Engineering Course Title: Embedded Systems (630414) Instructor: Eng. Anis Nazer Dept. of Computer Engineering Final Exam, First Semester: 2016/2017 Student Name: Student

More information

C and Embedded Systems. So Why Learn Assembly Language? C Compilation. PICC Lite C Compiler. PICC Lite C Optimization Results (Lab #13)

C and Embedded Systems. So Why Learn Assembly Language? C Compilation. PICC Lite C Compiler. PICC Lite C Optimization Results (Lab #13) C and Embedded Systems A µp-based system used in a device (i.e, a car engine) performing control and monitoring functions is referred to as an embedded system. The embedded system is invisible to the user

More information

Hong Kong Institute of Vocational Education Digital Electronics & Microcontroller. 8. Microcontroller

Hong Kong Institute of Vocational Education Digital Electronics & Microcontroller. 8. Microcontroller 8. Microcontroller Textbook Programming Robot Controllers, Myke Predko, McGraw Hill. Reference PIC Robotics: A Beginner's Guide to Robotics Projects Using the PIC Micro, John Iovine, McGraw Hill. Embedded

More information

// Karl's MS G4 Transmitter Code // Nordic packet: NO_FFTS, FFT_SIZE, 32 Floating Pt. Magnitude Sums

// Karl's MS G4 Transmitter Code // Nordic packet: NO_FFTS, FFT_SIZE, 32 Floating Pt. Magnitude Sums // Karl's MS G4 Transmitter Code // Nordic packet: NO_FFTS, FFT_SIZE, 32 Floating Pt. Magnitude Sums #include "DSP28x_Project.h" #include "Nordic_TX.h" #include #include #define FFT_SIZE

More information

University of Jordan Faculty of Engineering and Technology Department of Computer Engineering Embedded Systems Laboratory

University of Jordan Faculty of Engineering and Technology Department of Computer Engineering Embedded Systems Laboratory University of Jordan Faculty of Engineering and Technology Department of Computer Engineering Embedded Systems Laboratory 0907334 6 Experiment 6:Timers Objectives To become familiar with hardware timing

More information

Freescale Semiconductor, I

Freescale Semiconductor, I nc. Application Note Rev. 0, 4/2004 Software Drivers for Tango3 RF Transmitter and Romeo2 RF Receiver ICs By John Logan 8/16-Bit Division East Kilbride, Scotland Introduction This application note describes

More information

Developer Notes INSTEON Thermostat v012. Developer Notes. INSTEON Thermostat. Revision History

Developer Notes INSTEON Thermostat v012. Developer Notes. INSTEON Thermostat. Revision History Developer INSTEON Thermostat v012 Developer INSTEON Thermostat Version 012 June 19, 2012 Revision History Rev Date Comments 001 10/28/11 Initial Release 002 11/4/11 Updated formatting in some sections

More information

DCB1M - Transceiver for Powerline Communication

DCB1M - Transceiver for Powerline Communication Preliminary Description DCB1M - Transceiver for Powerline Communication The information in this data sheet is preliminary and may be changed without notice. 1. General The DCB1M is an innovative technology

More information

TPMC810. Isolated 2x CAN Bus. Version 1.1. User Manual. Issue June 2009

TPMC810. Isolated 2x CAN Bus. Version 1.1. User Manual. Issue June 2009 The Embedded I/O Company TPMC810 Isolated 2x CAN Bus Version 1.1 User Manual Issue 1.1.6 June 2009 TEWS TECHNOLOGIES GmbH Am Bahnhof 7 25469 Halstenbek / Germany Phone: +49-(0)4101-4058-0 Fax: +49-(0)4101-4058-19

More information

Embit Binary Interface - WMBus Specific Documentation. embit s.r.l.

Embit Binary Interface - WMBus Specific Documentation. embit s.r.l. Embit Binary Interface - WMBus Specific Documentation embit s.r.l. Document information Versions & Revisions Revision Date Author Comments 1.0 22/01/2010 A. Sala Initial version 1.1 22/01/2010 C. Biagi

More information

Serial Communication

Serial Communication Serial Communication What is serial communication? Basic Serial port operation. Classification of serial communication. (UART,SPI,I2C) Serial port module in PIC16F887 IR Remote Controller Prepared By-

More information

CMT2300A FIFO and Packet Format Usage Guideline

CMT2300A FIFO and Packet Format Usage Guideline AN143 CMT23A FIFO and Packet Format Usage Guideline Summary This article describes the CMT23A FIFO, packet format and the working principle of the interrupt system. When the article introduces the contents

More information

8051 Peripherals. On-Chip Memory Timers Serial Port Interrupts. Computer Engineering Timers

8051 Peripherals. On-Chip Memory Timers Serial Port Interrupts. Computer Engineering Timers 8051 Peripherals On-Chip Memory Timers Serial Port Interrupts Computer Engineering 2 2-1 8051 Timers 8051 Timers The 8051 has 2 internal 16-bit timers named Timer 0 and Timer 1 Each timer is a 16-bit counter

More information

C:\Documents and Settings\Administrateur\Mes documents\projets Keil\DisplayTech\main.c

C:\Documents and Settings\Administrateur\Mes documents\projets Keil\DisplayTech\main.c #include "c8051f000.h" #define TH0VAL 0xFB //Valeur du poids fort du Timer 0 #define TL0VAL 0x71 //Valeur du poids faible du Timer 0 #define csetd0 0x01 #define csetd1 0x02 #define csetd2 0x04 #define

More information

Microcontroller Overview

Microcontroller Overview Microcontroller Overview Microprocessors/Microcontrollers/DSP Microcontroller components Bus Memory CPU Peripherals Programming Microcontrollers vs. µproc. and DSP Microprocessors High-speed information

More information

movwf prevcod ; a new button is pressed - rcnt=3 movwf (mtx_buffer+1) movlw 3 movwf rcnt

movwf prevcod ; a new button is pressed - rcnt=3 movwf (mtx_buffer+1) movlw 3 movwf rcnt movlw 0x20 #endif call scan movlw 0xfd tris PORTB ; select colb (RB1) #ifdef MODE_CH8 movlw 0x04 #endif #ifdef MODE_CH4 movlw 0x30 #endif call scan movf cod, W bz loop2 ; if no buton is pressed, skip subwf

More information

Example of Asyncronous Serial Comms on a PIC16F877

Example of Asyncronous Serial Comms on a PIC16F877 /***************************************************************************************/ /* Example of Asyncronous Serial Comms on a PIC16F877 */ /* Target: PIC16F877 */ /* Baud: 9600 */ /* Bits: 8 */

More information

LORD MANUAL. Wireless Sensor Networks LXRS Data Communications Protocol

LORD MANUAL. Wireless Sensor Networks LXRS Data Communications Protocol LORD MANUAL Wireless Sensor Networks LXRS Data Communications Protocol 1 2013 LORD Corporation MicroStrain Sensing Systems 459 Hurricane Lane Suite 102 Williston, VT 05495 United States of America Phone:

More information

SA818 Programming Manual

SA818 Programming Manual SA818 Programming Manual Standard Uart interface is used to configure the parameter of SA818 Walkie Talkie. The format of UART is 9600, 8, N, 1, which means: Baud = 9600, data bit = 8bit, Parity = None,

More information

Serial Peripheral Interface (SPI) Last updated 8/7/18

Serial Peripheral Interface (SPI) Last updated 8/7/18 Serial Peripheral Interface (SPI) Last updated 8/7/18 MSP432 SPI eusci = enhanced Universal Serial Communications Interface 2 tj MSP432 SPI ARM (AMBA Compliant) 7/8 bit transmission Master/Slave LSB/MSB

More information

Chapter 6 Serial EEPROM by John Leung

Chapter 6 Serial EEPROM by John Leung Chapter 6 Serial EEPROM 6.1 ATMEL I 2 C Serial EEPROM The AT24C256 (U6) is useful for our application in storing critical data like temperature and humidity data, its time stamp, graphics, icons, or even

More information

Interrupts. Embedded Systems Interfacing. 08 September 2011

Interrupts. Embedded Systems Interfacing. 08 September 2011 08 September 2011 An iterrupt is an internal or external event that forces a hardware call to a specified function called an interrupt service routine Interrupt enable must be set (initialization) The

More information

RF Trans-controller ZULU. RF Transceiver combined with. Upto 2km Range Operates from V Dimensions: 25 x 11mm. Features. Transceiver Features

RF Trans-controller ZULU. RF Transceiver combined with. Upto 2km Range Operates from V Dimensions: 25 x 11mm. Features. Transceiver Features RF Transceiver combined with Onboard 8051 µcontroller Upto 2km Range Operates from 3.6-0.9V Dimensions: 25 x 11mm ZULU RF Trans-controller Features Ultra Low Power: 0.9 to 3.6 V Operation Typical sleep

More information

SURE. electronics. Demo Board for LCD Character Module User's Guide Sure Electronics Inc. DE-LD007_Ver1.0

SURE. electronics. Demo Board for LCD Character Module User's Guide Sure Electronics Inc. DE-LD007_Ver1.0 SURE electronics Demo Board for LCD Character Module User's Guide DE-LD007_Ver1.0 DEMO BOARD FOR LCD CHARACTER MODULE USER'S GUIDE Table of contents Chapter1. Overview... 1 1.1 Introduction...1 1. Quick

More information

Assembly Language Instructions

Assembly Language Instructions Assembly Language Instructions Content: Assembly language instructions of PIC16F887. Programming by assembly language. Prepared By- Mohammed Abdul kader Assistant Professor, EEE, IIUC Assembly Language

More information

which means that writing to a port implies that the port pins are first read, then this value is modified and then written to the port data latch.

which means that writing to a port implies that the port pins are first read, then this value is modified and then written to the port data latch. Introduction to microprocessors Feisal Mohammed 3rd January 2001 Additional features 1 Input/Output Ports One of the features that differentiates a microcontroller from a microprocessor is the presence

More information

Features 2.4 GHz Carrier Frequency RS232 UART interface with variable baud rate Input supply voltage: 5V to 12V 255 possible Channels frequencies (0 to 255) Programmable Device Address (255 per channel)

More information

Development Hardware. Target Board and In-circuit Debugger

Development Hardware. Target Board and In-circuit Debugger Development Hardware Target Board and In-circuit Debugger Development Hardware :: Slide 1 of 32 Microchip PICDEM 2 Plus Target Board Development Hardware :: Slide 2 of 32 PICDEM 2 Plus Demo Board Development

More information

Embedded System Design

Embedded System Design ĐẠI HỌC QUỐC GIA TP.HỒ CHÍ MINH TRƯỜNG ĐẠI HỌC BÁCH KHOA KHOA ĐIỆN-ĐIỆN TỬ BỘ MÔN KỸ THUẬT ĐIỆN TỬ Embedded System Design : Microcontroller 1. Introduction to PIC microcontroller 2. PIC16F84 3. PIC16F877

More information

Source Codes for DRA818U/DRA818V

Source Codes for DRA818U/DRA818V Source Codes for DRA818U/DRA818V V1.01 This document contains source codes for high power wireless voice transceiver module DRA818U/DRA818V and is used only for reference. In order to understand the codes

More information

Keywords: CRC, CRC-7, cyclic redundancy check, industrial output, PLC, programmable logic controller, C code, CRC generation, microprocessor, switch

Keywords: CRC, CRC-7, cyclic redundancy check, industrial output, PLC, programmable logic controller, C code, CRC generation, microprocessor, switch Keywords: CRC, CRC-7, cyclic redundancy check, industrial output, PLC, programmable logic controller, C code, CRC generation, microprocessor, switch APPLICATION NOTE 6002 CRC PROGRAMMING FOR THE MAX14900E

More information

Programming Guide I2C Bus

Programming Guide I2C Bus Programming Guide I2C Bus S-Series, T-Series models cdg, 2016. 6. T: +082-32-719-8055 E-mail: cdg@eltsensor.co.kr www.eltsensor.co.kr Contents 1. Applied Models 2. Compare of each model 3. I2C Frame Sequence

More information

Hardware Interfacing. EE25M Introduction to microprocessors. Part V. 15 Interfacing methods. original author: Feisal Mohammed

Hardware Interfacing. EE25M Introduction to microprocessors. Part V. 15 Interfacing methods. original author: Feisal Mohammed EE25M Introduction to microprocessors original author: Feisal Mohammed updated: 18th February 2002 CLR Part V Hardware Interfacing There are several features of computers/microcontrollers which have not

More information

Lecture (03) PIC16F84 (2)

Lecture (03) PIC16F84 (2) Lecture (03) PIC16F84 (2) By: Dr. Ahmed ElShafee ١ PIC16F84 has a RISC architecture, or Harvard architecture in another word ٢ PIC16F84 belongs to a class of 8 bit microcontrollers of RISC architecture.

More information

LCD. Configuration and Programming

LCD. Configuration and Programming LCD Configuration and Programming Interfacing and Programming with Input/Output Device: LCD LCD (liquid crystal display) is specifically manufactured to be used with microcontrollers, which means that

More information

Logosol Joystick Node LS-731

Logosol Joystick Node LS-731 Features 2 and 3 axis models Travel ±20 deg Non contact hall effect joystick Mechanical MTBF 15,000,000 cycles 3 pushbuttons Up to 2 stick pushbuttons 8 LEDs Member of Logosol s distributed motion control

More information

RS232.C An Interrupt driven Asyncronous Serial Port

RS232.C An Interrupt driven Asyncronous Serial Port /***************************************************************************/ /* RS232.C An Interrupt driven Asyncronous Serial Port */ /* Date : 06/03/2002 */ /* Purpose : Asyncronous Transmitter & Receiver

More information

ECE Microcontrollers. Serial Peripheral Interface (SPI) & NRF24 Radio

ECE Microcontrollers. Serial Peripheral Interface (SPI) & NRF24 Radio ECE 381 - Microcontrollers Serial Peripheral Interface (SPI) & NRF24 Radio Lab 9 Summary We will develop a wireless temperature sensor Once a second, sample LM34CZ voltage Convert to floating point with

More information

PIC-I/O Multifunction I/O Controller

PIC-I/O Multifunction I/O Controller J R KERR AUTOMATION ENGINEERING PIC-I/O Multifunction I/O Controller The PIC-I/O multifunction I/O controller is compatible with the PIC-SERVO and PIC-STEP motor control modules and provides the following

More information

PIC16C7X 11.0 SYNCHRONOUS SERIAL PORT (SSP) MODULE SSP Module Overview. Applicable Devices

PIC16C7X 11.0 SYNCHRONOUS SERIAL PORT (SSP) MODULE SSP Module Overview. Applicable Devices Applicable Devices PIC16C7X 11.0 SYNCHRONOUS SERIAL PORT (SSP) MODULE 11.1 SSP Module Overview The Synchronous Serial Port (SSP) module is a serial interface useful for communicating with other peripheral

More information

BME 4900 Page 1 of 2. Meeting 2: Personal Progress Report 12/2/09 Team 12 with Drew Seils. Semester One Week Two

BME 4900 Page 1 of 2. Meeting 2: Personal Progress Report 12/2/09 Team 12 with Drew Seils. Semester One Week Two BME 4900 Page 1 of 2 Semester One Week Two These past two saw a lot of progress with the Revo stationary bike project. During Thanksgiving break Shane spent most of his time doing research for the power

More information

Specification E2 Interface

Specification E2 Interface Specification E2 Interface Version 4.1 Name Date Created: Robert Mayr. 15.04.2011 Checked: Haider A. 15.04.2011 Approved: Reason for change: Text corrections TABLE OF CONTENTS 1 INTRODUCTION... 3 1.1 Overview..................................................................................................................

More information

TPMC Channel Serial Interface RS232/RS422. Version 1.0. User Manual. Issue August 2014

TPMC Channel Serial Interface RS232/RS422. Version 1.0. User Manual. Issue August 2014 The Embedded I/O Company TPMC460 16 Channel Serial Interface RS232/RS422 Version 1.0 User Manual Issue 1.0.6 August 2014 TEWS TECHNOLOGIES GmbH Am Bahnhof 7 25469 Halstenbek, Germany www.tews.com Phone:

More information

Two Wire Interface (TWI) also commonly called I2C

Two Wire Interface (TWI) also commonly called I2C (TWI) also commonly called I2C MSP432 I2C 2 tj MSP432 I2C ARM (AMBA Compliant) 8 bit transmission word 7/10 bit addressing Multi-master/slave modes 4 slave addresses 4 eusci-b modules 3 tj Overview 8 bit

More information

AN127 FLASH PROGRAMMING VIA THE C2 INTERFACE. Relevant Devices. Introduction. C2 Interface

AN127 FLASH PROGRAMMING VIA THE C2 INTERFACE. Relevant Devices. Introduction. C2 Interface FLASH PROGRAMMING VIA THE C2 INTERFACE Relevant Devices This application note applies to the following devices: C8051F300, C8051F301, C8051F302, and C8051F303. Introduction This application note describes

More information

unsigned char ReadADC() { /************* start A/D, read from an A/D channel *****************/ unsigned char ADC_VALUE;

unsigned char ReadADC() { /************* start A/D, read from an A/D channel *****************/ unsigned char ADC_VALUE; /*********************************************************************************************/ /* BME 361 Biomeasurement Lab - PIC18F4525BT Demo */ /* Laboratories 1-8: A/D, D/A, LCD display, ECG simulation,

More information

UM2173. Getting started with the S2-LP Sigfox firmware. User manual. Introduction

UM2173. Getting started with the S2-LP Sigfox firmware. User manual. Introduction User manual Getting started with the S2-LP Sigfox firmware Introduction The S2-LP Sigfox firmware framework provided by ST allows you to develop embedded applications on the STEVAL-FKI868V2 (and STEVAL-FKI868V1)

More information

// and verify that there is a sine wave with frequency <FREQUENCY> and

// and verify that there is a sine wave with frequency <FREQUENCY> and F330DC_IDA0_SineWave.c Copyright 2006 Silicon Laboratories, Inc. http:www.silabs.com Program Description: This program outputs a sine wave using IDA0. IDA0's output is scheduled to update at a rate determined

More information

Overview RFSv4.3 is a RF module providing easy and flexible wireless data transmission between devices. It is based on AVR Atmega8 with serial output which can be interfaced directly to PC. Features 2.4

More information

Chapter 10 Sections 1,2,9,10 Dr. Iyad Jafar

Chapter 10 Sections 1,2,9,10 Dr. Iyad Jafar Starting with Serial Chapter 10 Sections 1,2,9,10 Dr. Iyad Jafar Outline Introduction Synchronous Serial Communication Asynchronous Serial Communication Physical Limitations Overview of PIC 16 Series The

More information

F28335 I2C MODULE v1.1

F28335 I2C MODULE v1.1 1 F28335 I2C MODULE v1.1 Abstract This document describes how to configure for I2C module of F28335. 2 Table of Contents 1. Overview... 3 2. Configuration details... 3 3. Reference... 7 3 1. Overview Step

More information

DATA SHEET MN63Y1210A. Part No. Package Code No. SSOP016-P-0225E

DATA SHEET MN63Y1210A. Part No. Package Code No. SSOP016-P-0225E DATA SHEET Part No. Package Code No. MN63Y1210A SSOP016-P-0225E Publication date: February 2014 Ver. BEM About this manual Organization These specifications provide important information for users of the

More information

Application Note One Wire Digital Output. 1 Introduction. 2 Electrical Parameters for One Wire Interface. 3 Start and Data Transmission

Application Note One Wire Digital Output. 1 Introduction. 2 Electrical Parameters for One Wire Interface. 3 Start and Data Transmission Application Note One Wire Digital Output 1 Introduction The pressure transmitter automatically outputs pressure data, and when appropriate temperature data, in a fixed interval. The host simply waits for

More information

MIDI.C December 8, 2002 Page 1

MIDI.C December 8, 2002 Page 1 MIDI.C December 8, 2002 Page 1 /* Midi.c These are the functions that provide the interface to the midi port */ #include #include #include "smb.h" #include "midi.h" #pragma interrupt_handler

More information

IP-48DAC channel 16-bit Digital/Analog Converter With memory Industry Pack Module PROGRAMMING MANUAL Version 1.

IP-48DAC channel 16-bit Digital/Analog Converter With memory Industry Pack Module PROGRAMMING MANUAL Version 1. IP-48DAC-16 48-channel 16-bit Digital/Analog Converter With memory Industry Pack Module PROGRAMMING MANUAL 828-10-000-4000 Version 1.0 January 2007 ALPHI TECHNOLOGY CORPORATION 1898 E. Southern Ave Tempe,

More information

Using the USB and Serial Interfaces

Using the USB and Serial Interfaces Using the USB and Serial Interfaces PulsON 300 and 400 Series TIME DOMAIN Cummings Research Park 4955 Corporate Drive Suite 101 Huntsville, AL 35805 USA http://www.timedomain.com Tel: +1 256.922.9229 +1

More information

Conto D2 COMMUNICATION PROTOCOL CONTENTS 1.0 INTRODUCTION

Conto D2 COMMUNICATION PROTOCOL CONTENTS 1.0 INTRODUCTION PR 121 rev. 0 11/11/2011 Pagina 1 di 9 ELECTRICITY ENERGY METER FIRMWARE 1.6 Conto D2 COMMUNICATION PROTOCOL CONTENTS 1.0 INTRODUCTION 2.0 DATA MESSAGE DESCRIPTION 2.1 Data field description 2.2 Data format

More information

HI 3593 ARINC V Dual Receiver, Single Transmitter with SPI Application Note AN 161 June 13, 2012

HI 3593 ARINC V Dual Receiver, Single Transmitter with SPI Application Note AN 161 June 13, 2012 23351 Madero, Mission Viejo, CA 92691. USA. Tel: + 1 949 859 8800 Fax: + 1 949 859 9643 Email: sales@holtic.com Web: www.holtic.com HI 3593 ARINC 429 3.3V Dual Receiver, Single Transmitter with SPI Application

More information

AND8386/D. Bootloading BelaSigna 250 Using the I 2 C Interface APPLICATION NOTE

AND8386/D. Bootloading BelaSigna 250 Using the I 2 C Interface APPLICATION NOTE Bootloading BelaSigna 250 Using the I 2 C Interface APPLICATION NOTE INTRODUCTION This application note describes how to bootload BelaSigna 250 through its I 2 C interface when it does not have an EEPROM

More information

CAN / RS485. Product Description. Technical Reference Note. Interface Adapter. Special Features

CAN / RS485. Product Description. Technical Reference Note. Interface Adapter. Special Features CAN / Interface Adapter For SHP Series Total Power: < 1 Watts Input Voltage: 5V Internal Outputs: CAN,, USB, I 2 C Special Features Input Protocols: 1) using Modbus 2) CAN using modified Modbus Output

More information

UM2149. Getting started with the S2-LP development kits. User manual. Introduction

UM2149. Getting started with the S2-LP development kits. User manual. Introduction User manual Getting started with the S2-LP development kits Introduction This document describes the development kits for the S2-LP device and related hardware and software components. The S2-LP is an

More information

Introduction to Ethernet and lab3.3

Introduction to Ethernet and lab3.3 Introduction to Ethernet and lab3.3 maglun@sm.luth.se Nov 200 Computation structures Agenda Introduction History Components (MAC, PHY) Packet format CRC Bit order Hubs, Switches and Routers Questions Computation

More information