Suchergebnisse für "portc"
3,3Volt-I2C-Bus '-----------------------------------------------------------------------------* Config Sda = Portc .3 Config Scl = Portc .4 Config I2cdelay = 17 ''-----------------------------------------------------------------------------* ' I2C: Hier werden die Kalibrierwerte des BMP085 eingetragen '----------
in
„Luftdrucksensor mit I2C“
·
Mikrocontroller und Digitale Elektronik
·
15.10.2014 10:46
SystemVersion) { wdt_reset(); wdt_disable(); cli(); // no irqs. //For HouseBasic DDRB=0; PORTB=0; DDRC=0; PORTC =0; DDRA=(0|(1<<4)); //Set Bluetooth Module on (MD Device Support) PORTA=(0|(1<<4)); uint32_t BaudRates[]={300,600,1200,4800,9600,14400,19200,28800,38400,56000,57600,115200,128000,256000}; unsigned
in
„ATtiny Bootloader C füllt FF's in Flash“
·
Mikrocontroller und Digitale Elektronik
·
12.10.2014 13:05
Thread
Nimm dieser Makros [c] #define MotorspeedON PORTC |= (1<<PINC1) #define MotorspeedOFF PORTC &= ~(1<<PINC1) #define MotorLinksON PORTC |= (1<<PINC2) #define MotorLinksOFF PORTC &= ~(1<<PINC2) #define MotorRechtsON PORTC |= (1<<PINC3) #define MotorRechtsOFF PORTC &= ~(1<<PINC3) #define IniRearSlow PIND & ( 1 << PIND5 ) [/c] aus schedule.h raus und in main.c rein. erstens haben die dort nichts verloren (im schedule.h geht es um den Scheduler
Mikrocontroller und Digitale Elektronik
· Hartmut Burger
· 15.10.2014 18:13
· 22 Antworten
Thread
int main(void) { DDRC = 0x30; // PC0-3 als Eingang, PC4-5 (I2C) als Ausgang PORTC = 0x3F; // Pullups f. Eingänge und I2C AN DDRB = 0xFF; // PB 0-7 als Ausgang PORTB = 0x00; // Alle LEDs aus i2c_init(); rtc_init(); PORTB |= (1<<PB1)
Mikrocontroller und Digitale Elektronik
· mar-io
· 11.10.2014 12:56
· 6 Antworten
Thread
möchte. Mein Code: $regfile = "m8def.dat" $crystal = 8000000 Config Servos = 1 , Servo1 = Portc .5 , Reload = 9 Config Portc .5 = Output Config Portc .4 = Input Config Portc .3 = Input Config Portc .2 = Input Config Portc .1 = Input Config Portc .0 = Input Config Portb.5 = Input Config Portb.4 = Input Config Portd.0 = Input Enable Interrupts 'Pullups Pinc.4 = 0 Portc .4 = 0 Portc .3 = 0 Portc .2 = 0 Portc .1 = 0 Portc .0 = 0 Portb.5 = 0 Portb.4 = 0 Portd.0 = 0 Dim Pos As Word Do If Pinc.3 = 1 Then Pos = 65 If Pinc.2 = 1 Then Pos = 80 If Pinc
Mikrocontroller und Digitale Elektronik
· Franz
· 09.10.2014 17:03
· 8 Antworten
Thread
// Interrupts global freischalten for(digit=0;;digit=(digit+1)%5) { PORTC =0; PORTB=1<<digit; PORTC =segment[(zahl/pow(10,digit))%10]; _delay_ms(10); } } Allzu aufwändig ist das also nicht.
Mikrocontroller und Digitale Elektronik
· Werner Erni
· 09.10.2014 15:00
· 32 Antworten
Thread
fertig, Mann! Mit einer anderen Taste zuammenlegen und über Spannungsteiler mit ADC einlesen? An PORTC ist leider das Display angeschlossen! Einfache Lösung: Reset wegfusen >> Taste an PC6 >> Programm läuft nicht wie gewünscht >> kein HV-Programmer >> Arschkarte Auch eine Lösung: Taste über
Mikrocontroller und Digitale Elektronik
· Thomas E.
· 07.10.2014 18:14
· 1 Antworten
Zustand belassen: DDRD |= (1 << DDD5); DDRC |= (1 << DDC2); // Pull Up von Pin 0 und Pin 1 setzen: PORTC = ( 1 << PC0 ) | ( 1 << PC1 ); } /** Main **/ int main (void) { cli(); /** Initzialisiere Ports **/ port_init(); /** Configure debouncing routines **/ KEY_DDR &= ~ALL_KEYS; // configure key port for
in
„Funktion funktionieren nicht aber warum?“
·
Mikrocontroller und Digitale Elektronik
·
07.10.2014 12:14
Thread
nur noch mal sicherheitshalber ^^ --> #define SED1335_DATA_PORT PORTC #define SED1335_DATA_DIR DDRC #define SED1335_DATA_PIN PINC #define SED1335_CONTROL_PORT PORTD #define SED1335_CONTROL_DIR DDRD #define SED1335_CONTROL_PIN PIND #define SED1335
im Beitrag #3903384: > nur noch mal sicherheitshalber ^^ --> > > #define SED1335_DATA_PORT PORTC > #define SED1335_DATA_DIR DDRC > #define SED1335_DATA_PIN PINC > > #define SED1335_CONTROL_PORT PORTD > #define SED1335_CONTROL_DIR DDRD > #define SED1335_CONTROL_PIN PIND >
Markt
· Klaus P.
· 04.04.2015 14:55
· 20 Antworten
Status Register 0x2F UDR USART Data Register I/O Map 0x40..0x43 - 8255 0x40 PORTA 0x41 PORTB 0x42 PORTC 0x43 8255_CNTRL I/O Map 0x60 - ADC 0804 0x60 ADC0804_READ I/O Map 0x80 - 7_Segment Anzeige 0x80 SEG7 */ // Prototypen void cv_vint(void); void stop_cpu(); const char copyright[]="Z80 Monitor (C) 2014
in
„Retro Fieber: Z80 oder 68000 ?“
·
Mikrocontroller und Digitale Elektronik
·
04.10.2014 21:39
STATUS, RP0 ; make Port B4..7 input movlw B'11110000' iorwf TRISB, f bcf STATUS, RP0 BusyLoop bcf PORTC , LcdRs bsf PORTC , LcdRw ; Lesen bsf PORTC , LcdE nop movf PORTD, w movwf LcdStatus bcf PORTC , LcdE nop bsf PORTC , LcdE ; Enable nop bcf PORTC , LcdE btfsc LcdStatus, 7 ; teste bit 7 goto BusyLoop bcf
in
„Frequenzzähler 1Hz-100khZ“
·
Mikrocontroller und Digitale Elektronik
·
04.10.2014 09:52
Thread
nRF_status = wl_module_get_data(payload); //reads the incomming Data to Array payload PORTC = payload[0]; } } [/c] Da ich weder einen sicher funktionierenden Empfänger noch Sender habe, tue ich mir mit der Fehlersuche sehr schwer. Wo kann ich noch ansetzen? Danke & Gruß Michael
Mikrocontroller und Digitale Elektronik
· Michael N.
· 03.10.2014 13:03
· 2 Antworten
char n = 50; while(n--) _delay_ms(1); } void lcd_impuls(void) // Schreibimpuls mit Mindestlaenge { PORTC |= LCD_STROBE; _delay_us(2); PORTC &= ~LCD_STROBE; } void lcd_nibble(char c) // 4-bit-Wert ausgeben { char temp; temp = PORTB & 0xc3; // Datenleitungen an PortB.2 -> PortB.5 temp |= ((c>>2) & 0x3c)
in
„Stoppuhr – Geschwindigkeit – Pulsweite mit Atmega88“
·
Projekte & Code
·
02.10.2014 16:14
PC1 reciver on off switch PORTC .PIN1CTRL = PORT_OPC_TOTEM_gc; PORTC .DIRCLR = 4; //input of reciver signal PORTC .OUTCLR = 4; PORTC .PIN2CTRL = PORT_OPC_TOTEM_gc | PORT_ISC_FALLING_gc; //configure the timer to overflow 3906/s (TIMERPERIOD
in
„Fernbedien RC5 Empfänger“
·
Projekte & Code
·
01.10.2014 23:08
Thread
define ae "\xE1" // ä // output #define OUT1_DDR DDRC #define OUT1_PORT PORTC #define OUT1_PIN PINC #define OUT2_DDR DDRB #define OUT2_PORT PORTB #define OUT2_PIN PINB #define green 0x20 // 0010 0000 #define yellow 0x10
define ae "\xE1" // ä // output #define OUT1_DDR DDRC #define OUT1_PORT PORTC #define OUT1_PIN PINC #define OUT2_DDR DDRB #define OUT2_PORT PORTB #define OUT2_PIN PINB #define green 0x20 // 0010 0000 #define yellow 0x10
Mikrocontroller und Digitale Elektronik
· Lokus Pokus
· 12.10.2014 09:19
· 60 Antworten
Thread
PORTB = VRAM[2]; PORTC |= (1<<PC5); _delay_ms(2); PORTC &= ~(1<<PC5); PORTB = 0x00; PORTB = VRAM[3]; PORTC |= (1<<PC4); _delay_ms(2); PORTC &= ~(1<<PC4); PORTB = 0x00;
case 1: PORTC |= (1<<PC6); break; case 2: PORTC |= (1<<PC5); break; case 3: PORTC |= (1<<PC4); break; case 4: PORTC |= (1<<PC3); break; case 5: PORTC |= (1<<PC2); break
Mikrocontroller und Digitale Elektronik
· Dieter B.
· 01.10.2014 19:58
· 26 Antworten
*********SOFTWARE Interrupts****************/ ISR (TIMER1_COMPA_vect) //Zündung erste Halbwelle { PORTC &= ~(1<<PC0); //T1 AN W1 Low Aktiv } ISR (TIMER1_COMPB_vect) //Löschen aller gezündeten Pins { PORTC |= (1<<PC0); //T1 aus W1 Low Aktiv } ISR (TIMER3_COMPA_vect) //Zündung löschen zweite Halbwelle { PORTC &=~ (1<<PC0); //T1 an W1 Low Aktiv } ISR (TIMER3_COMPB_vect) //Zündung löschen zweite Halbwelle { PORTC |= (1<<PC0); //T1 aus W1 Low Aktiv } /* ISR (TIMER5_COMPA_vect) { if(foo=1) { PORTA &=~(1<<PINA0
in
„Software architektur, wo plaziere ich meine funktion“
·
Mikrocontroller und Digitale Elektronik
·
01.10.2014 12:31
*************/ void PortInit(void) { DDRD=0x00; //Eingang LDE;NDG DDRC=0xFF; //Ausgang W1-Zündung PORTC =0xFF; //Anfangszustand; lowactic DDRF=0x00; //Eingang AD-Konverter DDRB=0xFF; //Ausgang //LEDs //PORTB=0x00; // DDRA |= (1<<PINA0);//Ausgang DDRA=0xFF; PORTA=0xFF; } /****************************TIMER1
in
„Software architektur, wo plaziere ich meine funktion“
·
Mikrocontroller und Digitale Elektronik
·
01.10.2014 12:31
Zustand belassen: DDRD |= (1 << DDD5); DDRC |= (1 << DDC2); // Pull Up von Pin 0 und Pin 1 setzen: PORTC = ( 1 << PC0 ) | ( 1 << PC1 ); } /** Main **/ int main (void) { /** Initzialisiere Ports **/ port_init(); /** Configure debouncing routines **/ KEY_DDR &= ~ALL_KEYS; // configure key port for input
in
„Funktionsaufruf Funktioniert nicht richtig..warum?“
·
Mikrocontroller und Digitale Elektronik
·
30.09.2014 14:31
----------------------------------------------* ' Normaler Ausgang, positive Impulse Fb_out Alias Portc .4 Config Fb_out = Output ' leuchtet während der Ausgabe eines Telegramms Fb_led Alias Portc .0 Config Fb_led = Output ' leuchtet während der Wiedergabe Sq_led Alias Portc .1 Config Sq_led = Output '-
in
„[Bascom/AVR] Pollin-MP3-Modul steuern“
·
Projekte & Code
·
29.09.2014 15:09
BSCAN Controller PWM K OC1-OC5 PORTB C C S A D P EJTAG INT U D I 32 y ® ® d IC1-IC5 MIPS32 M4K k PORTC CPU Core o C IS DS s 32 32 32 32 B 32 32 r SPI1-SPI2 Remappable h Pins Bus Matrix i e P 32 32 I2C1-I2C2 32 32 Data RAM Peripheral Bridge PMP 10-bit ADC r UART1-UART2 32-bit Wide ho Program Flash Memory
in
„PIC32MX flash access time“
·
Mikrocontroller und Digitale Elektronik
·
27.09.2014 20:21
Thread
[c] // PORTS #define PORT_com74hc595 PORTC #define PORT_SER PC0 //74HC595 PIN 14 #define PORT_SCK PC1 //74HC595 PIN 12 #define PORT_RCK PC2 //74HC595 PIN 11 #define DDR_com74hc595 DDRC #define DDR_SER DDC0
Mikrocontroller und Digitale Elektronik
· Markus
· 25.09.2014 23:04
· 3 Antworten
sein und die 4 // Datenleitungen m�ssen auf aufeinanderfolgenden Pins liegen // LCD DB4-DB7 <--> PORTC Bit PD0-PD3 #define LCD_PORT PORTC #define LCD_DDR DDRC #define LCD_DB PC0 // LCD RS <--> PORTD Bit PC4 (RS: 0=Data, 1=Command) #define LCD_RS PC4 // LCD EN <--> PORTD Bit PC5 (EN: 1-Impuls f�r Daten
in
„Menüsteuerung von Taster auf Drehencoder umbauen“
·
Mikrocontroller und Digitale Elektronik
·
25.09.2014 16:53
//Erstmal sicher alles IOs definieren, wegen stromsparen DDRB = 1; DDRC = 1; DDRD = 1; PORTB = 0; PORTC = 0; PORTD = 0; PRR = (1<<PRTWI)|(1<<PRTIM0)|(1<<PRTIM1)|(1<<PRSPI)|(1<<PRUSART0); //ADC and TIM2 on! (ADC, weil ich ihn in meinem Projekt brauche, ändert ja nicht viel am Stromverbrauch) } void Sleep32k_Init
in
„Mikrocontroller zeitgesteuert "aufwecken"“
·
Mikrocontroller und Digitale Elektronik
·
22.09.2014 16:28
#define WH_OFF TCCR2A &= ~(1<<COM2B1); //PHASE3 (W) #define WL_DDR DDRC |= (1<<3); #define WL_ON PORTC |= (1<<3); #define WL_OFF PORTC &= ~(1<<3); #define PHASE_ALL_OFF UH_OFF;UL_OFF;VH_OFF;VL_OFF;WH_OFF;WL_OFF; // Alle Phasen abschalten, Motor im Leerlauf #define SENSE_U ADMUX = 0; // Multiplexer für
in
„Eingang am AVR schalten“
·
Mikrocontroller und Digitale Elektronik
·
22.09.2014 14:45
BSCAN Controller PWM K OC1-OC5 PORTB C C S A D P EJTAG INT U D I 32 y ® ® d IC1-IC5 MIPS32 M4K k PORTC CPU Core o C IS DS s 32 32 32 32 B 32 32 r SPI1-SPI2 Remappable h Pins Bus Matrix i e P 32 32 I2C1-I2C2 32 32 Data RAM Peripheral Bridge PMP 10-bit ADC r UART1-UART2 32-bit Wide ho Program Flash Memory
in
„pic32 flash und i/o speed“
·
Mikrocontroller und Digitale Elektronik
·
22.09.2014 11:07
wird Ergebnis der nächsten Wandlung nicht übernommen. */ (void) ADCW; } uint16_t getLight(void) { PORTC &= ~(1<<LED); //LED ausschalten _delay_ms(5); DDRC &= ~(1<<LED); // LED-Port als Eingang _delay_ms(5); ADCSRA |= (1<<ADSC); while (ADCSRA & (1 << ADSC)) { } DDRC |= (1 << LED); // LED-Port als Ausgang
in
„LED zur Helligkeitsmessung - ADC Spannungsmessung“
·
Mikrocontroller und Digitale Elektronik
·
21.09.2014 18:21
loesche Ausgangspins, damit Eingaenge hi-Z sind ; Port C treibt LCD (32kHz Osz. an PC6,7) ser temp ; PORTC auf Ausgabe out DDRC,temp ; Port A Piepser, ADC ldi temp,0b11111110 ; PA1,2,3,4,5,6,7 out PA0 in out DDRA,temp ; Analogkomparator fuer Batterietest (hier nicht weiter benutzt) ; ggf. Potential fuer
in
„ADC in C unter WinAVR ärgert“
·
Mikrocontroller und Digitale Elektronik
·
21.09.2014 09:52
Thread
Hey, Super jetzt funktioniert´s schon mal. Habe 5 Taster an PORTC gesteckt und kann jetzt fröhlich rum drücken. Habe es so wie 2 Posts weiter oben, einfach in die main kopiert und wenn eine Tastendruck erkannt wurde wird die moodlight_remote_local mit der entsprechenden
Mikrocontroller und Digitale Elektronik
· Philipp Tholey
· 20.09.2014 18:33
· 5 Antworten
Thread
wie im Beitrag die die Hardware an die Software angepasst. [c]// Ports #define LCD_CMD_PORT PORTC // Command Output Register #define LCD_CMD_DIR DDRC // Data Direction Register for Command Port #define LCD_DATA_IN PIND // Data Input Register #define LCD_DATA_OUT PORTD
Hi >Benutze ein Atmega 1284p. Da PortC für den Datenbus verwendetet wird stellt sich die Frage, ob das JTEG-Interface von PortC abgeschaltet ist. MfG Spess
Mikrocontroller und Digitale Elektronik
· kleiner_meiner
· 21.09.2014 19:35
· 16 Antworten
Thread
); // Timer/Counter1 Output Compare Match A Interrupt Enable } ISR (TIMER1_COMPA_vect) { PORTC ^= ( 1 << PC5 ) } [/c]
PORTC auf Ausgang gestellt?
Mikrocontroller und Digitale Elektronik
· Uwe
· 15.09.2014 14:16
· 28 Antworten
_t PROGMEM port_to_output_PGM[] = { NOT_A_PORT, (uint16_t) &PORTA, (uint16_t) &PORTB, (uint16_t) &PORTC , (uint16_t) &PORTD, NOT_A_PORT, NOT_A_PORT, }; const uint16_t PROGMEM port_to_input_PGM[] = { NOT_A_PORT, (uint16_t) &PINA, (uint16_t) &PINB, (uint16_t) &PINC, (uint16_t) &PIND, NOT_A_PORT, NOT_A_PORT
in
„Arduino IDE mit Atmega32 - AD Wandler sind nicht benutzbar“
·
Mikrocontroller und Digitale Elektronik
·
15.09.2014 04:24
_t PROGMEM port_to_output_PGM[] = { NOT_A_PORT, (uint16_t) &PORTA, (uint16_t) &PORTB, (uint16_t) &PORTC , (uint16_t) &PORTD, NOT_A_PORT, NOT_A_PORT, }; const uint16_t PROGMEM port_to_input_PGM[] = { NOT_A_PORT, (uint16_t) &PINA, (uint16_t) &PINB, (uint16_t) &PINC, (uint16_t) &PIND, NOT_A_PORT, NOT_A_PORT
in
„Arduino IDE mit Atmega32 - AD Wandler sind nicht benutzbar“
·
Mikrocontroller und Digitale Elektronik
·
15.09.2014 03:37
_t PROGMEM port_to_output_PGM[] = { NOT_A_PORT, (uint16_t) &PORTA, (uint16_t) &PORTB, (uint16_t) &PORTC , (uint16_t) &PORTD, NOT_A_PORT, NOT_A_PORT, }; const uint16_t PROGMEM port_to_input_PGM[] = { NOT_A_PORT, (uint16_t) &PINA, (uint16_t) &PINB, (uint16_t) &PINC, (uint16_t) &PIND, NOT_A_PORT, NOT_A_PORT
in
„Arduino IDE mit Atmega32 - AD Wandler sind nicht benutzbar“
·
Mikrocontroller und Digitale Elektronik
·
14.09.2014 22:50
Thread
sagen. Er arbeitet mit einem 20-MHz-Quarz. Die 8 Adressleitungen liegen an PortD. Das Low-Nibble von PortC liegt am Daten-Bus. C.5 ist mit CE2 verbunden, /CE1, OD und R/W liegen an Port B, an welchem auch die ISP-Schnittstelle hängt, deren Signale nicht anderweitig verwendet werden. Der AVR liest die
Mikrocontroller und Digitale Elektronik
· Volker Bosch
· 29.05.2020 22:18
· 4 Antworten
Thread
steckung für den lcd gerade gesteckt habe? oder ich habe den taster falsch gesteckt? einmal an den portc und in die erdung
oh, nein also muss ich jetzt noch ldi r16,0xff out portc , r16 schreiben?
Mikrocontroller und Digitale Elektronik
· Joe
· 14.09.2014 13:40
· 49 Antworten
MISO_PC6 22 7 G 7 DAT0 C 2 H OC0D_TXD1_SCK_CLKO_EVO_PC7 23 8 8 DAT1 GND N 1 6 JP4 G Q 1 OC0A_PD0 26 PORTC 2 p 58 XTAL2_PR0 OC0B_XCK0_PD1 27 2 USD5722SMD C 2 59 XTAL1_PR1 OC0C_RXD0_PD2 28 3 N OC0D_TXD0_PD3 29 4 G OC1A_/SS_PD4 30 5 OC1B_XCK1_MOSI_PD5 31 6 22R 5V 1 RXD1_MISO_PD6 32 7 22R 2 TXD1_SCK_CLKO_EVO_PD7
in
„XMega DFU programmierung am Mac“
·
Mikrocontroller und Digitale Elektronik
·
13.09.2014 16:09
Thread
(((P) >= 10 && (P) <= 13) || ((P) >= 50 && (P) <= 53)) ? &PORTB : \ (((P) >= 30 && (P) <= 37) ? &PORTC : \ ((((P) >= 18 && (P) <= 21) || (P) == 38) ? &PORTD : \ ((((P) >= 0 && (P) <= 3) || (P) == 5) ? &PORTE : \ (((P) >= 54 && (P) <= 61) ? &PORTF : \ ((((P) >= 39 && (P) <= 41) || (P) == 4) ? &PORTG
Mikrocontroller und Digitale Elektronik
· Christian J.
· 13.09.2014 21:21
· 14 Antworten
Thread
wäre eine Lösung folgende: [c] #define SET(x,y) (x)|=(1<<(y)) //Bit set #define B0_PORT PORTC #define B0_PIN 4 #define B1_PORT PORTA #define B1_PIN 7 ... //b0 if ( (Dezimal%2==1) ) //ungerade rest immer 1 SET(B0_PORT,B0_PIN); //b1 if ( (Dezimal==2) || (Dezimal==3) || (Dezimal
Mikrocontroller und Digitale Elektronik
· technikus
· 13.09.2014 13:36
· 6 Antworten
void) { uint16_t data,data1 = 0; uint8_t i; system_clocks_init(); // System Clocks initialization PORTC _DIRSET = 1<<PIN7_bp; PORTC _REMAP = 1<<3; //PORTC _OUTSET = 1<<PIN7_bp; //Start Timer TCC0_CCA = 30 ; //Frequency Mode (CTC) TCC0_CTRLB = TC_WGMODE_FRQ_gc | (1<<TC0_CCDEN_bp); TCC0_CTRLA = TC_CLKSEL_DIV1
in
„Problem mit XEMGA ADC“
·
Mikrocontroller und Digitale Elektronik
·
12.09.2014 15:24
Thread
PORTB & (BIT_3)){ if( count <= 6 ) count++; }else{ if( count>8 ) count--; } if(PORTC & (BIT_4)){ if( count <= 6 ) count++; }else{ if( count>8 ) count--; } if(PORTC & (BIT_5)){ if( count <= 6 ) count++; }else{ if( count>8 ) count--;} if(PORTC
Peter schrieb im Beitrag #3799379: > if((PORTB&0x0C)|(PORTC &0xF2)==0xFE) { > restartGame(); if((PORTB&0x06)==0x06) & ((PORTC &0x3E)==0x3E) {
Mikrocontroller und Digitale Elektronik
· Peter
· 11.09.2014 16:13
· 47 Antworten
Thread
CS01); sei(); while(1) { switch (time_sec_zehn) { case 1: PORTC |= (1<<PC4);break; case 2: PORTC |= (1<<PC6);break; case 3: PORTC |= (1<<PC4)|(1<<PC6);break; case 4: PORTC |= (1<<PC7);break; case 5: PORTC |= (1<<PC7)|(1<<
switch (time_sec_ein) { case 1: PORTC |= (1<<PC3);break; case 2: PORTC |= (1<<PC1);break; case 3: PORTC |= (1<<PC3)|(1<<PC1);break; case 4: PORTC |= (1<<PC0);break; case 5: PORTC |= (1<<PC0)|(1<<
Mikrocontroller und Digitale Elektronik
· Ma Mö
· 11.09.2014 08:33
· 3 Antworten
include <util/delay.h> #define MrLCDsCrib PORTD #define DataDir_MrLCsCrib DDRD #define MrLCDsControl PORTC #define DataDir_MrLCDsControl DDRC #define LightSwitch 5 #define ReadWrite 7 #define BiPolarMood 2 void Check_if_MRLCD_is_Busy(void); void Peek_A_Boo(void); void Send_A_Command(unsigned char command
in
„LCD-Ansteuerung(TG12864B-13B und ATmega1284p)“
·
Mikrocontroller und Digitale Elektronik
·
10.09.2014 21:53
/ CLK->HIGH DDRC = 0b01111111; // LCD // C0-LCDdata C1-LCDclk C2-RS C3~C6-Enable1~Enable4 C7-N.C. PORTC = 0x00; DDRD = 0x08; // D3-Strobe PORTD = 0x08; // Strobe->HIGH lcdinit(1); lcdinit(2); lcdinit(3); lcdinit(4); _delay_ms(50); lcdsend(COMMAND, 0x01, 1); // clearen lcdsend(COMMAND, 0x01, 2); lcdsend
in
„74hct165 läuft nicht“
·
Mikrocontroller und Digitale Elektronik
·
10.09.2014 18:31
haben wir folgende Informationen von Andreas bekommen: (Ich DK7JB werde keine LEDs verbauen) LED1 am PORTC ,4 LED EIN: RS232-Interrupt; Zeichen wurde aus RS232 erfolgreich gelesen und im RS232- Zeichenbuffer (Ringbuffer mit etwa 250 Char) LED AUS: RS232-Zeichenbuffer (Ringbuffer) ist leer, letztes Zeichen
in
„Kennlinienschreiber mit AVR-µC“
·
Analoge Elektronik und Schaltungstechnik
·
10.09.2014 14:10
Thread
/ 7. und 8. PIN vom Port D als Ausgang DDRC &= ~(1<<0); // 1. PIN vom Port C als Eingang PORTC |= (1<<0); // internen Pull-up einschalten a = PINC & ~(1<<0); if(a != 0) // wenn Taster gedrückt { PORTD|=(1<<7); // LED8 geht an } else // wenn Taster nicht
/ 7. und 8. PIN vom Port D als Ausgang DDRC &= ~(1<<0); // 1. PIN vom Port C als Eingang PORTC |= (1<<0); // internen Pull-up einschalten a = PINC & ~(1<<0); while(1) { if(a != 0) // wenn Taster gedrückt { PORTD|=(1<<7); // LED8 geht an PORTD&=
Mikrocontroller und Digitale Elektronik
· Da H.
· 09.09.2014 01:24
· 20 Antworten
myAVR MK3 Board // mit ATMega-2560 @ 16MHz // LCD-Ausgabe // Grafik-LCD an PortA Bit0 bis Bit7 und PortC Bit0 bis Bit7 // Quick-Jumper PortA+C muss gesetzt sein //----------------------------------------------------------------------------- // das File muss im Ordner // "myAVR/WinAVR/AVR/Include/UB_MK3
in
„SHT11 an ATmega2560 Es funktioniert nicht“
·
Mikrocontroller und Digitale Elektronik
·
08.09.2014 10:48
://www.mikrocontroller.net/topic/14792 * */ #ifndef _DS1820_H_ #define _DS1820_H_ #define DS_PORT PORTC #define DS_PIN PINC #define DS_DDR DDRC #define DS_BIT _BV(3) uint8_t w1_enumerate(uint8_t diff, uint8_t id[8]); float w1_measure(uint8_t id[8]); #endif
in
„Vereinfache/Kompakte Libary für D18B20“
·
Mikrocontroller und Digitale Elektronik
·
03.09.2014 15:19
Thread
+ADC; ADC_zaehler++; PORTC ^=(1<<PC2); // debugpin toggeln } ISR (TIMER0_COMPB_vect) einmal pro //100us { PORTA^=(1<<PA4); // debugpin toggeln ADCSRA = ADCSRA | (1<<ADSC); //ADC start conversion } ISR
Overflow interupt aus } int main(void) { initialisierung(); PORTA^=(1<<PA4); PORTC ^=(1<<PC2); // debugpin toggeln while(1) { Takte_1000(); // do complex things ADC_summe_changed=false; // es wäre blöd wenn der interrupt während dieser Berechnung zuschlägt
Mikrocontroller und Digitale Elektronik
· FLorian Unbekannto
· 03.09.2014 18:47
· 46 Antworten
Thread
cnt = 0; TRISC = 0; // all output while(1) // alle ports klappern { PORTC = cnt++; } return (EXIT_SUCCESS); } </code> mfg Peter
Mikrocontroller und Digitale Elektronik
· Andreas Fri
· 31.08.2014 21:32
· 1 Antworten