it's a routine that does the same thing as the PHP shiftin function
Type: Posts; User: Castor; Keyword(s):
it's a routine that does the same thing as the PHP shiftin function
If I use shiftin or a similar routine it works fine. Here is my shiftin clone. Why won't HARDWARE SPI work ?
Might it be because I connected the SPI's SDO (output) to the ADC CS line ? (see first...
http://img145.imageshack.us/img145/1979/adclf3.th.jpg http://img229.imageshack.us/img229/8586/ad7680cj8.th.jpg
I'm trying to interface the AD7680 16 bit ADC with a pic18F4685 running at 20MHZ,...
I used Paul's sollution and it works great !
This is for a temperature mesurement aplication. The expression I'm trying to figure out using integer math is R2=R1/[(Vcc/V2)-1]. R2 is a thermistor. It changes it's internal resistence with...
it's for an electric golf cart I'm building
uhm .. one :)
I'll post the code in the apropriate section when it's done. It's for a Li-Ion Battery Management System (BMS)/Balancer
This is the winner:
portb = (portb & %00011111 ) | ( ( i rev 3 ) << 5 )
portc = (portc & %10111111 ) | ( i.3 << 6 )
I've tried both in MPLAB SIM but
portc = (portc & %10111111 ) | ( i <<...
Please stay on topic.
Here's a summary: I have two pesky devices in my circuit. A multiplexer and a decoder.The multiplexer is connected as:
MUX
'------------
'RA5 INH
'RA1 A
'RA2 B
'RA3 C
Hey, thanks for the great answer.
It works like a charm. In fact I use a 16 bit external A/D converter so using PORTA pins as digital I/O doesn't pose an issue. What if the selection pins are...
It's more of a conceptual question then a programming issue. I use a pic to control the inputs of a 16 channel multiplexer, thus allowing me to select a certain channel and read voltages from a multi...
Eventually I moved the data lines on PORTC and voila, the LCD is displaying characters as it should. Thank you guys for the help.
Here is the working code:
' display a message on the lcd
...
Thanks skimask for the suggestion but unfortunately the output is still the same. Initially black boxes. On "release from reset", still black boxes. If I pull out the LCD Vdd - strange characters,...
I'm using the 28 pin demo board from Microchip (see schematic below) with a 18F2685pic, MPLAB IDE and Picbasic pro v2.47, and ICD2 for programming. The LCD pins are connected in the default manner....