-
Datei
freqgen48.bas
------- Config Portb.1 = Output Config Pinc.3 = Input Config Pinc.4 = Input Config Pinc.5 = Input Portc.3 = 1 Portc.4 = 1 Portc.5 = 1 '-------- Timer0 als PWM einrichten -------- Config Timer0 = Pwm , Prescale = 1 , Compare A Pwm = Clear Down , _ Compare B Pwm = Clear Down Enable Timer0 Start Timer0
in „Einstellbarer Frequenzgenerator für 0.12 Hz - 8 MHz mit Atmega 8 und Bascom“ · Projekte & Code ·
-
Datei
main_usart_lcd_mega16.c
without marks)in CodeVisionAVR C Compiler JTAGEN = 1 (without marks)in CodeVisionAVR C Compiler and PORTC does works OCDEN = 1 (without marks)in CodeVisionAVR C Compiler =========== The AVR chip is placed on an Atmel STK500 development board. The jumper settings for the STK500 board are: OSCSEL: 1-2 XTAL1
in „Probleme mit Typendefinition bei uart_puts“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
codeschloss_aktuell.cpp
("Hello World!"); DDRD = 0xFF; // PORTD = Ausgang DDRB = 0x00; // PORTB = Eingang DDRC = 0x00; // PORTC = Eingang PORTB = 0xFF; // PORTB = PULL-UP PORTC = 0xFF; // PORTC = PULL-UP do { pw_true=false; if (pw==false) { set_pw(); } enter_pw(); int k=1; int i=0; for (i;i<7;i++) { if (pw_org[i]==pw_pressed
in „Fehler im Programm oder im µC!“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
IO-Modul04.c
FALSE; unsigned char temp = 0; int main(void) { DDRB = 0xff; // PORTB als Ausgang DDRC = 0x00; // PORTC als Eingang DDRD = 0x00; // PORTD als Eingang PORTC = 0xff; // Pull-up Widerstände von PORTC einschalten PORTD = 0xff; // Pull-up Widerstände von PORTD einschalten // BOOKMARK 1 ///////////////////
in „Stromausfall, Parameter speichern, eeprom.h“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
mega16_usb.c
void Delay(unsigned int a) { while (--a != 0) { if (BUT1 == 0) { PORTA=PINC; DDRC = DDRC | 0x10; PORTC.4 = !PORTC.4; //toggle TDO } else DDRC=0; //restore DDRC if (BUT2 == 0) { PORTA=PINB; DDRB = DDRB | 0x40; PORTB.6 = !PORTB.6; //toggle MISO } else DDRB = DDRB & 0xbf; //restore DDRB } } //*/ void main
in „Hilfe bei AVR Studio + WinAVR“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
DDS.c
DDS_DDR = 0xFF; //all output DDRA = 0x0; //all input PORTA = 0xFF; //pull up DDRC = 0xFF; //all output PORTC = 0x00; //no pull up SetFrequency(dwFreq); RotaryBlink(); RotaryBlink(); while(1) { if((PINA & 0x2) == 0x0) { RotaryBlink(); dwFreq += 10000; SetFrequency(dwFreq); DebounceKey(PINA, 0x2); }; if((PINA
in „Daten zum AD9833 in C übertragen“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
lcd.h
LCD Datenbus DB4-DB7, das unterste Bit DB4 kann auf den Portbits 0..4 liegen // LCD DB4-DB7 <--> PORTC Bit PC0-PC3 #define LCD_DB PD0 // LCD Steuersignale RS und EN // LCD RS <--> PORTC Bit PC4 (RS: 0=Data, 1=Command) #define LCD_RS PD4 // LCD EN <--> PORTC Bit PC5 (EN: 1-Impuls für Daten) #define LCD_EN
in „OLED Display EA W162 init klappt nicht“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Raumthermostat.asm
ldi temp1, 0x02 out DDRB, temp1 ;### Port C (für XCLR) ldi temp1, 0b00001000 out DDRC, temp1 cbi PORTC, 3 ;### TWI ldi temp2, 0<<TWPS1 | 0<<TWPS0 out TWSR, temp2 ldi temp2, 13 out TWBR, temp2 ldi temp4, 0x10 ;Start adresse Koeffizienten rjmp TWI_Messwerte ;### Koeffizienten auslesen TWI_Daten: rcall
in „Luftdruck-Modul HP03S mit Atmega8“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
freqgen88_org.bas
------- Config Portb.1 = Output Config Pinc.3 = Input Config Pinc.4 = Input Config Pinc.5 = Input Portc.3 = 1 Portc.4 = 1 Portc.5 = 1 '-------- Timer0 als PWM einrichten -------- Config Timer0 = Pwm , Prescale = 1 , Compare A Pwm = Clear Down , _ Compare B Pwm = Clear Down Enable Timer0 Start Timer0
in „Einstellbarer Frequenzgenerator für 0.12 Hz - 8 MHz mit Atmega 8 und Bascom“ · Projekte & Code ·
-
Datei
lcd-routines.h
LCD Datenbus DB4-DB7, das unterste Bit DB4 kann auf den Portbits 0..4 liegen // LCD DB4-DB7 <--> PORTC Bit PC0-PC3 #define LCD_DB PE4 // LCD Steuersignale RS und EN // LCD RS <--> PORTC Bit PC4 (RS: 0=Data, 1=Command) #define LCD_RS PG0 // LCD EN <--> PORTC Bit PC5 (EN: 1-Impuls für Daten) #define LCD_EN
in „LCD kann nur Kontrast einstellen“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
lcd-routines.h
LCD Datenbus DB4-DB7, das unterste Bit DB4 kann auf den Portbits 0..4 liegen // LCD DB4-DB7 <--> PORTC Bit PE4-PE7 #define LCD_DB PE4 // LCD Steuersignale RS und EN // LCD RS <--> PORTC Bit PG0 (RS: 0=Data, 1=Command) #define LCD_RS PG0 // LCD EN <--> PORTC Bit PG2 (EN: 1-Impuls für Daten) #define LCD_EN
in „LCD kann nur Kontrast einstellen“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Steuerung_regelbar.bas
m8def.dat" $crystal = 8000000 $hwstack = 100 $swstack = 100 $framesize = 100 Config Lcdpin = Pin , Db4 = Portc.5 , Db5 = Portd.0 , Db6 = Portd.1 , _ Db7 = Portd.2 , E = Portc.4 , Rs = Portc.2 Config Lcd = 16 * 2 , Chipset = Ks077 Initlcd Cursor Off Cls Config Pind.5 = Input 'Schalter 1 Portd.5 = 1 Config Pind
in „7ter Atmega 8 geht nur teilweise kaputt“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Hp03.c
uart_puts("param Nr "); intuart(i); uart_putc(':'); intuart(param[i]); uart_puts(" "); } i2c_stop(); PORTC |=_BV(1); //Pin XCLR auf high uart_puts(" XCLR high "); //-------------Auslesen der Sensorwerte (Rohdaten)-------------------------------------------------------------------------------------------
in „Hp03 Berechnung läuft schief“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
GccAtmega8515_MAX7219_quad.c
Transmit(i,0x0F,i,0x0F,i,0x0F,i,0x0F); } int main (void) { DDRC = 0xFF; // PORT C als Ausgang schalten PORTC = 0xFF; // alle LEDs aus (invertiert wegen STK500) SPI_MasterInit(); // SPI initialisieren max7219_4_Init(); // MAX initialisieren while(1) { // max7219_4_Init(); // max7219_Clear(); PORTC = 0xFF; // LED0 blinkt mit 1Hz _delay_ms(500); PORTC = 0xFE; _delay_ms(500); // SPI_Transmit(DigitAnzeige1, Inhalt, DigitAnzeige2, Inhalt, DigitAnzeige3, Inhalt, Digit Anzeige4, Inhalt) SPI4_Transmit(0x01,0x08,0x01,0x01,0x01,0x08,0x01,0x01); // Digit
in „ATMEGA8515_SPI ->4-fach MAX7219 instabil, Fragen dazu“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
lcd.h
LCD Datenbus DB4-DB7, das unterste Bit DB4 kann auf den Portbits 0..4 liegen // LCD DB4-DB7 <--> PORTC Bit PC0-PC3 #define LCD_DB PB0 // LCD Steuersignale RS und EN // LCD RS <--> PORTC Bit PC4 (RS: 0=Data, 1=Command) #define LCD_RS PB4 // LCD EN <--> PORTC Bit PC5 (EN: 1-Impuls für Daten) #define LCD_EN
in „LCD tc1604a mit ATMEGA16“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
lcd-routines.h
LCD Datenbus DB4-DB7, das unterste Bit DB4 kann auf den Portbits 0..4 liegen // LCD DB4-DB7 <--> PORTC Bit PC0-PC3 #define LCD_DB PD4 // LCD Steuersignale RS und EN // LCD RS <--> PORTC Bit PC4 (RS: 0=Data, 1=Command) #define LCD_RS PC0 // LCD EN <--> PORTC Bit PC5 (EN: 1-Impuls für Daten) #define LCD_EN
in „Problem mit ATmega164A und LCD FDCC1601E“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
alf.c
currentPointerForISR[7]) { tmpC &= ~(1<<4); } if (loopCounter == currentPointerForISR[8]) { tmpA &= ~(1<<6); } PORTC = tmpC; PORTA = tmpA; } // Standard Input/Output functions #include <stdio.h> // Declare your global variables here void main(void) { PORTA=0x00; DDRA=0xFF; PORTB=0x00; DDRB=0x00; PORTC=0x00; DDRC=
in „12bit, 9-Kanal Soft-PWM für LEDs auf Mega16“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Sensormodul2-3.asm
Busnummer = 6? breq ow6stp ;ja -> bearbeiten rjmp ow7stp ;sonst Busnummer 7 bearbeiten ; ow0stp: sbi portc, 0 ;Portausgang auf High setzen sbi ddrc, 0 ;Port auf Ausgang umschalten ret ; ow1stp: sbi portc, 1 ;Portausgang auf High setzen sbi ddrc, 1 ;Port auf Ausgang umschalten ret ; ow2stp: sbi portc, 2
in „AVR-ASM Knobelei : Bitmanipulation am LCD im 4-Bit Mode“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
IO.c
for pin OC0 // PORTB7 for 1: RCK as Output - Reserved for pin OC2 PORTB = 0x00; DDRB = 0xFF; // // PORTC variable initializations // // PORTC0 for 8: GYRODATA as Input with pullups - Reserved for pin PC0 PORTC = 0xFF; // // PORTD variable initializations // // PORTD2 for 1: VSYNC as Input - Reserved for
in „Assemblerdatei unter Eclipse einbinden“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ZACOM.asm
sbi DDRC,1 ;Ausgang Digit 10er sbi DDRC,2 ;Ausgang Digit 100er sbi DDRC,3 ;Ausgang Digit 1000er out PORTC,temp ;alle Digits aus (Lowaktiv) ; ;Init Timer 0 für Multiplex ; ldi temp,0b00000101 ;Vorteiler 1024 out TCCR0,temp ldi temp,0b00000001 ;Timer 0 überlauf out TIMSK,temp ; ;Init Watchdog ; ;rcall WD_init
in „7 Segment mit flimmern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ZACOM.asm
sbi DDRC,1 ;Ausgang Digit 10er sbi DDRC,2 ;Ausgang Digit 100er sbi DDRC,3 ;Ausgang Digit 1000er out PORTC,temp ;alle Digits aus (Lowaktiv) ; ;Init Timer 0 für Multiplex ; ldi temp,0b00000101 ;Vorteiler 1024 out TCCR0,temp ldi temp,0b00000001 ;Timer 0 überlauf out TIMSK,temp ; ;Init Watchdog ; ;rcall WD_init
in „7 Segment mit flimmern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Wattmeter.c
0x00; // PortD, all Input, Externer Interrupt 1 & 0 @ PD3 & PD2 DDRC = 0xFF; // PortC, all Output PORTC |= (1<<PC0) | (1<<PC1); // Turn Laser on // Global Interrups enable sei(); // Timer1 Initialization Timer1_init(); // Timer0 Initialization Timer0_init(); // External Interrupt Initialization INIT_EXT_Interrupt
in „3 versch. Impulse Zählen mit Atmega8“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
schedule_try5.c
volatile("label:"); restore_registers_without_sreg(); asm volatile("no_jump_flag:"); } void function1(){ PORTC = 0b00010000; restore_registers_with_sreg(); //asm volatile("RJMP label");// relativsprung zu "label"; asm volatile("reti");//goto function } void function2(){ PORTC = 0b00100000; restore_registers_with_sreg
in „AVR AtMega8 Preemtive Scheduler“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ATi841_Master_Prg1.c
// Warte 2ms slavetest(); _delay_ms(2); DDRC=0b01100000; // setze Port C auf Ausgang, PC5 und PC6 PORTC|=0b01001111; // setze Ports C5-6 (LEDs aus) while(1) { // ========>> TASTENEINGABEN T1 if (!(PINC & (1<<PINC2)) ) // Taster T1 { // Wenn T1 gedrückt... s_write(42); // Schreib 1 Funktion aufrufen lcd_command
in „Taster Entprellung am Attiny 841 und Auswertung“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
DC_Motor_Regler.c
define PWM_AUSGANG 0 // PW-Signal an PC.0 eines ATmega48-328 #define MOTOR_MINUS 2 // Eingaenge an PortC #define MOTOR_PLUS 3 #define POTI_EINGANG 4 #define PWM_TEILER 130 // Wiederholfreuqenz fuer PWM #define PWM_AUFLOESUNG 300 // ergibt ca. 200 Hz PWM-Frequenz #define PWM_80 (PWM_AUFLOESUNG*8/10) //
in „Drehzahlregler für DC-Motor, ATmega48-328“ · Projekte & Code ·
-
Datei
teil.c
// webpage.h //Port Schalten und Status %PORTC1 bedeutet PORTC PIN1 "<p align=\"left\">\r\n" "<input type=\"checkbox\" name=\"OUT\" value=\"B\" %PORTC1>\r\n" " MOC(PC1)\r\n" "</p>\r\n" //..... // ENDE Ausschnitt webpage.h // http.c //----------
in „Arduino Webserver mit Diagramm“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
MFSv2.ASM
Keyboard 5 6 7 8 Row2 equ 2 ;Keyboard + - 0 Z Row3 equ 3 ;Keyboard U 0 0 S ; für LCD-Pins #define LcdE PORTC,7 ; enable Lcd #define LcdRw PORTC,6 ; read Lcd #define LcdRs PORTC,5 ; Daten Lcd (nicht control) #define LcdPort PORTD ; Datenbus des LCD (obere 4 Bit) #define schranke_s PORTC,0 #define schranke_l
in „PIC16F874 Sekundentakt“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
tn1634def.inc
equ PUEC3 = 3 ; .equ PUEC4 = 4 ; .equ PUEC5 = 5 ; ; PORTC - Port C Data Register .equ PORTC0 = 0 ; .equ PC0 = 0 ; For compatibility .equ PORTC1 = 1 ; .equ PC1 = 1 ; For compatibility .equ PORTC2 = 2 ; .equ PC2 = 2 ; For compatibility .equ PORTC3 = 3 ; .equ PC3 = 3 ; For compatibility .equ PORTC4 = 4 ; .equ PC4 = 4 ; For compatibility .equ PORTC5 = 5 ; .equ PC5 = 5 ; For compatibility ; DDRC - Data Direction Register, Port C .equ DDC0 = 0 ; .equ DDC1 = 1 ; .equ DDC2 = 2 ; .equ DDC3 = 3 ; .
in „ATTINY1634 und Assembler“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
august2011_tn1634def.inc
equ PUEC3 = 3 ; .equ PUEC4 = 4 ; .equ PUEC5 = 5 ; ; PORTC - Port C Data Register .equ PORTC0 = 0 ; .equ PC0 = 0 ; For compatibility .equ PORTC1 = 1 ; .equ PC1 = 1 ; For compatibility .equ PORTC2 = 2 ; .equ PC2 = 2 ; For compatibility .equ PORTC3 = 3 ; .equ PC3 = 3 ; For compatibility .equ PORTC4 = 4 ; .equ PC4 = 4 ; For compatibility .equ PORTC5 = 5 ; .equ PC5 = 5 ; For compatibility ; DDRC - Data Direction Register, Port C .equ DDC0 = 0 ; .equ DDC1 = 1 ; .equ DDC2 = 2 ; .equ DDC3 = 3 ; .
in „ATTINY1634 und Assembler“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
DEFEKT_tn1634def.inc
equ PUEC3 = 3 ; .equ PUEC4 = 4 ; .equ PUEC5 = 5 ; ; PORTC - Port C Data Register .equ PORTC0 = 0 ; .equ PC0 = 0 ; For compatibility .equ PORTC1 = 1 ; .equ PC1 = 1 ; For compatibility .equ PORTC2 = 2 ; .equ PC2 = 2 ; For compatibility .equ PORTC3 = 3 ; .equ PC3 = 3 ; For compatibility .equ PORTC4 = 4 ; .equ PC4 = 4 ; For compatibility .equ PORTC5 = 5 ; .equ PC5 = 5 ; For compatibility ; DDRC - Data Direction Register, Port C .equ DDC0 = 0 ; .equ DDC1 = 1 ; .equ DDC2 = 2 ; .equ DDC3 = 3 ; .
in „ATTINY1634 und Assembler“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Lite09.asm
out portd,uni00 ;select null_device clr uni00 ;stabilize adress null_device/clear scratch_reg out portc,data ;send device data ser data ;stabilize device data/set data_register out portd,adr ;send device adress nop ;stabilize device adress ldi adr,0b11010000 ;load adress null_device out portd,adr ;select null_device ser uni00 ;stabilize adress null_device/set scratch_reg out portc,uni00 ;set data_bus=hi clr uni00 ;stabilize data_bus/clear scratch_reg ret ;--clr_ledfd-------------------------------------;function:clear led function+dual clr_ledfd: ldi adr,0b01110000 ;load adress
in „Problem bei Tasterabfrage“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
main.c
/ ICE_Respon_OK(); ICE_Respon_OK(); break; } } void ICE_EnterProgmode(){ ICE_Read_Sync_CRC_EOP(); PORTC |= 0b00100000; // mal ne LED-Kontrolle anschalten PC5 ICE_Respon_OK(); ICE_Respon_OK(); } void ICE_LeaveProgmode(){ ICE_Read_Sync_CRC_EOP(); PORTC |= 0b00010000; // mal ne LED-Kontrolle anschalten PC5 ICE_Respon_OK(); ICE_Respon_OK(); } void ICE_ChipErase(){ ICE_Read_Sync_CRC_EOP(); PORTC |= 0b00001000; // mal ne LED-Kontrolle anschalten PC5 ICE_Respon_OK(); ICE_Respon_OK(); } void ICE_Set_DeviceDescriptor(){ char i; for (i=0; i<123; i++){ deviceDescriptor[i]=getchar(); } ICE_Respon_OK
in „AVR JTAG Programmierung“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
atm324p.c
; DDRC = 0x0; DDRD = TYP_SW_1 | TYP_SW_2_3; PORTA = 0; PORTB = 0xFF; //Switch-Port pull up enable PORTC = 0; PORTD = TYP_SW_1 | TYP_SW_2_3; } /* * IO init for transmitter board */ void IOInitTX( void) { DDRD |= PTT_OR_LED; PORTC = 0xFF; PORTD |= PTT_OR_LED; PCICR = (1<<PCIE2) | (1<<PCIE3); PCMSK2 = 0xFF
in „ATMEGA324P über die ISP Schnittstelle“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
vLCD8x24.inc
macht. ;---------------------------------------------------------------------------- .equ lcdport=portc ;Port, an dem die 4 Datenleitungen des LCD ;angeschlossen sind. .equ lcddatmsk=$f0 ;Maske auf LCD-Datenpins. ;$0f - LCD ist an Bit 0...3 des Ports angeschlossen. ;$f0 - LCD ist an Bit 4...7 des Ports
in „atmega 8 als schnitstelle“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ST7920.c
define PORT_D3 PORTD #define PIN_D3 PIND #define DDR_D3 DDRD #define BIT_D3 PD4 #endif #define PORT_D4 PORTC #define PIN_D4 PINC #define DDR_D4 DDRC #define BIT_D4 PC0 #define PORT_D5 PORTC #define PIN_D5 PINC #define DDR_D5 DDRC #define BIT_D5 PC1 #define PORT_D6 PORTC #define PIN_D6 PINC #define DDR_D6 DDRC #define BIT_D6 PC2 #define PORT_D7 PORTC #define PIN_D7 PINC #define DDR_D7 DDRC #define BIT_D7 PC3 #define PORT_E PORTB #define DDR_E DDRB #define BIT_E PB2 #define PORT_RW PORTB #define DDR_RW DDRB #define BIT_RW PB3 #define PORT_RS PORTB
in „HD44780 (Pollin DV20208) Zeichenbreite stimmt nicht“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ic2.c
2 Wire bus interrupt service routine interrupt [TWI] void twi_isr(void) { // Place your code here PORTC=~PORTC; } // Declare your global variables here void main(void) { // Declare your local variables here // Input/Output Ports initialization // Port A initialization // Func0=In Func1=In Func2=In Func3
in „atmel mega64 ic2 codevision“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
NEW_MAP.txt
(newlyPressd) { turnBacklightOn(); return; } if (timer>0) timer --; else { PWM1_Stop; PWM2_Stop; PORTC = 255; pwmRunning = 0; enterPowerSave(); } if (timer<(~lightStrenght)){ PWM1_Change_Duty(~((unsigned char)timer)); PWM2_Change_Duty(~((unsigned char)timer)); } } void setupLightMode(unsigned char lm
in „Chatpad PIC16F883“ · Mikrocontroller und Digitale Elektronik ·
-
PDF
Doku_130816.pdf
TWI-Slave empfangene Daten werden weitergereicht - PORTMODE : Pin Mode setzen (freie Pins an PortB, PortC und PortD) - PORTREAD : Pin Status auslesen (DDR-, PORT- und PIN-Register) - PORTWRITE : Pin Status setzen (freie Pins an PortB, PortC und PortD) - PORTTOG : Pin Status togglen (freie Pins an PortB, PortC und PortD) 1. TWI-Übertragung an einen TWI-Slave, der am TWI-Bus des µC angeschlossen ist Die Adressen der TWI-Slaves werden links ausgerichtet erwartet, die Adressen zum TWI-Write sind immer geradzahlig
-
Datei
DS18B20-C.asm
Zählregister für einsec r3,r2 Messergebnis */ .equ portd = 0x12 .equ ddrd = 0x11 .equ pind = 0x10 .equ portc = 0x15 .equ ddrc = 0x14 .equ pinc = 0x13 .equ portb = 0x18 .equ ddrb = 0x17 .equ pinb = 0x16 .equ sph = 0x3e .equ spl = 0x3d .equ tccr0 = 0x33 .equ timsk = 0x39 .equ sreg = 0x3f .equ twbr = 0x00 .equ
in „1-Wire Temperatursensor DS18S20 mit Atmega8 Ansteuern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Wattmeter.c
0x00; // PortD, all Input, Externer Interrupt 1 & 0 @ PD3 & PD2 DDRC = 0xFF; // PortC, all Output PORTC |= (1<<PC0) | (1<<PC1); // Turn Laser on // Global Interrups enable sei(); // Timer1 Initialization Timer1_init(); // Timer0 Initialization Timer0_init(); // External Interrupt Initialization INIT_EXT_Interrupt
in „3 versch. Impulse Zählen mit Atmega8“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Freqgen-M48-88-Ver.2.0_03-05-2012-50MHz.bas
------- Config Portb.1 = Output Config Pinc.3 = Input Config Pinc.4 = Input Config Pinc.5 = Input Portc.3 = 1 Portc.4 = 1 Portc.5 = 1 '-------- Timer0 als PWM einrichten -------- Config Timer0 = Pwm , Prescale = 1 , Compare A Pwm = Clear Down , _ Compare B Pwm = Clear Down Enable Timer0 Start Timer0
in „Einstellbarer Frequenzgenerator für 0.12 Hz - 8 MHz mit Atmega 8 und Bascom“ · Projekte & Code ·
-
Datei
Uhr_program.c
Display_time(); // Ser_send_str("\r"); //CR --> Wagenrücklauf (Curser auf Anfang verschieben) /* PORTC = s; PORTC = 0xFF; _delay_ms(1000); PORTC = 0x00; _delay_ms(1000); */ } } //////////////////////////////////////////////////////////////////////////////// // Erzeugt einen Enable-Puls static void lcd_enable
in „Funk-uhr über AVR Programmieren mit DCF01“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
EKG.c
bit_is_clear (PINB, 4)) & (bit_is_set (SteuerbitsEmpf, 2))) //Wenn Summer eingeschaltet und Impuls kommt {PORTC |= (1<<PC0);} //Summer ein else {PORTC &= ~(1<<PC0);} //Summer aus } //Interrupts ISR(USART_RXC_vect) //Daten über USART empfangen (als Interrupt um nicht währenddessen unterbrochen zu werden) { SteuerbitsEmpf
in „ATmega8 Timer0- / EEPROM-Fehler“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
regler_sensor_lcd.c
=1; } } } return 0; } ISR(TIMER0_COMP_vect) { PORTA=~PORTA; //PWM Output } ISR(TIMER2_OVF_vect) { PORTC=~PORTC; //PORTC toggeln timer_count++; } char chartointeger(int value) { if(value==0) return '0'; else if(value==1) return '1'; else if(value==2) return '2'; else if(value==3) return '3'; else if(value
in „LCD Display funktioniert bei Zusammenstellung nicht“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
timer_opt.asm
; movwf PIE1 ; nur CCP1IE freigeben movlw 0 movwf PIE2 bcf STATUS,RP0 clrf PORTA clrf PORTB clrf PORTC ; **** UART Init **** bsf STATUS,RP0 movlw 00000000b movwf TXSTA bcf STATUS,RP0 movlw 0 movwf RCSTA ; UART dissabled ; **** AD-Module **** movlw 00000000b movwf ADCON0 ; shutoff bsf STATUS,RP0 movlw
-
Datei
LCD1.c
-; else time->year=99; } break; } } void schalten(void) // schaltet die 2 Keise { if(kreis1==1) { PORTC |= (1<<PC5); // einschalt-Relais PORTC |= (1<<PC4); // Umschaltrelais } if(kreis2==1) { PORTC |= (1<<PC5); // einschalt-Relais PORTC &= ~(1<<PC4); // Umschaltrelais } if((kreis1==0) && (kreis2==0)) { PORTC &= ~(1<<PC5); } } void dimmen(void) // Eingaberoutine für Dimm-Wert in Gl. Variable bl_status { uint8_t ok_pressed=0; uint8_t old_key=3; // Aus meune noch OK enthalten daher init 3 uint8_t old_sec=
in „Probleme win WinAVR 20081205“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
boot.c
) __attribute__ ((naked)) \ __attribute__ ((section (".bootloader"))); int main() { DDRC |= 0xff; PORTC = ~0x01; do { asm volatile("nop"); } while(1); } void loader() { DDRC |= 0xff; PORTC = ~0x02; do { asm volatile("nop"); } while(1); } /* --------- do.bat --------- echo compile... avr-gcc -g -Os -mmcu
in „bootloader section in c“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Monitortest.asm
.def tempi =r20 .def dellop =r21 .org 0 rjmp Initialisierung .org OVF0addr out TCNT0, Reload out portc, null rjmp Timer Initialisierung: clr null ldi temp, 1 mov eins, temp ser temp mov voll, temp ldi temp, LOW(RAMEND) ;Stackpointer initialisieren und in X Register laden out SPL, temp ldi temp, HIGH
-
Datei
T6963.c
#define LCD_CTRL_PORT PORTD // Port C #define LCD_DATA_PORT PORTC // Port C #define LCD_DATA_RD() {DDRC=0x00;PORTC=0xFF;} #define LCD_DATA_WR() {DDRC=0xFF;PORTC=0xFF;} #define RST_PIN 1 // Ansteuerung Reset #define RST_high() LCD_CTRL_PORT |= _BV(RST_PIN) #define
in „Grafik LCD 128x128, Toshiba TLX-1391 bei Pollin“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
timer_control_panel.bas
comd.0:9600,8,n,1" For Output As #1 Open "comd.1:9600,8,n,1" For Input As #2 Config Pinc.5 = Input Portc.5 = 1 Config Pinc.4 = Input Portc.4 = 1 Config Pinc.3 = Input Portc.3 = 1 Config Portb.1 = Output Portb.1 = 1 Config Pind.4 = Input 'TIMER Config Timer2 = Timer , Prescale = 1024 On Timer2 Timerroutine
in „[BASCOM] Mal geht mein Taster, mal nicht“ · Mikrocontroller und Digitale Elektronik ·